Error while installation

Hey, I’m installing ghost on my ubuntu 20.04 machine and I’m getting this error:


Please paste console output as text rather than screenshots, so it is easily readable. Use this button from the toolbar.

Screenshot from 2022-09-03 15-23-48

Did you use the guide? It’s always useful to explain the steps you’ve taken. What specification is the server, version of database, CLI etc.?

1 Like

Sorry. Yeah I’ve seen all the documentation and all seems to be ok.

Mysql version: 8.0.30-0ubuntu0.20.04.2 for Linux on x86_64 ((Ubuntu))
Node version: v16.17.0
Npm version: 8.15.0
Ghost-CLI version: 1.23.0
Server: Ubuntu 20.04.5 LTS. 44.96GB

The logs are the following:

Debug Information:
    OS: Ubuntu, v20.04.5 LTS
    Node Version: v16.17.0
    Ghost-CLI Version: 1.23.0
    Environment: production
    Command: 'ghost install'
Message: Command failed: yarn install --no-emoji --no-progress
warning ghost@5.13.0: The engine "cli" appears to be invalid.
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.29.1"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.29.1"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.29.4"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@0.5.34"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.29.1"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@^0.5.33"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.27.0"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@^0.5.31"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.29.3"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.27.0"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@^0.5.31"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.27.0"
warning Resolution field "@tryghost/logging@2.3.0" is incompatible with requested version "@tryghost/logging@2.2.3"
warning Resolution field "@tryghost/logging@2.3.0" is incompatible with requested version "@tryghost/logging@2.2.4"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.29.1"
error An unexpected error occurred: "/home/ghostrun/.cache/yarn/v6/npm-is-extendable-0.1.1-62b110e289a471418e3ec36a617d472e301dfc89-integrity/node_modules/is-extendable/.yarn-metadata.json: Unexpected end of JSON input".

yarn install v1.22.19
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
info If you think this is a bug, please open a bug report with the information provided in "/var/www/dglobal/versions/5.13.0/yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

Exit code: 1

--------------- stdout ---------------
yarn install v1.22.19
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
info If you think this is a bug, please open a bug report with the information provided in "/var/www/dglobal/versions/5.13.0/yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.


--------------- stderr ---------------
warning ghost@5.13.0: The engine "cli" appears to be invalid.
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.29.1"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.29.1"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.29.4"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@0.5.34"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.29.1"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@^0.5.33"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.27.0"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@^0.5.31"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.29.3"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.27.0"
warning Resolution field "moment-timezone@0.5.23" is incompatible with requested version "moment-timezone@^0.5.31"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@2.27.0"
warning Resolution field "@tryghost/logging@2.3.0" is incompatible with requested version "@tryghost/logging@2.2.3"
warning Resolution field "@tryghost/logging@2.3.0" is incompatible with requested version "@tryghost/logging@2.2.4"
warning Resolution field "moment@2.24.0" is incompatible with requested version "moment@^2.29.1"
error An unexpected error occurred: "/home/ghostrun/.cache/yarn/v6/npm-is-extendable-0.1.1-62b110e289a471418e3ec36a617d472e301dfc89-integrity/node_modules/is-extendable/.yarn-metadata.json: Unexpected end of JSON input".


Try yarn cache clean and them ghost update.

I’m still having this error.

1 Like

I have same problem in Cpanel

Anyone find a solution to this? I’m having the same problem. Here is my console output:

node@Ghost-Dev:~/indoor$ yarn cache clean
yarn cache v1.22.19
success Cleared cache.
Done in 5.18s.
node@Ghost-Dev:~/indoor$ ghost update
Working directory is not a recognisable Ghost installation.
Run ghost update again within a folder where Ghost was installed with Ghost-CLI.
node@Ghost-Dev:~/indoor$ ls -la
total 9
drwxr-xr-x 2 node node 2 Mar 6 00:43 .
drwxr-xr-x 8 node node 11 Mar 5 23:15 …
node@Ghost-Dev:~/indoor$ ghost install

Love open source? We’re hiring JavaScript Engineers to work on Ghost full-time.

:heavy_check_mark: Checking system Node.js version - found v18.14.2
:heavy_check_mark: Checking current folder permissions
:heavy_check_mark: Checking memory availability
:heavy_check_mark: Checking free space
:heavy_check_mark: Checking for latest Ghost version
:heavy_check_mark: Setting up install directory
:heavy_multiplication_x: Downloading and installing Ghost v5.37.0
A ProcessError occurred.

Message: Command failed: yarn install --no-emoji --no-progress
warning ghost@5.37.0: The engine “cli” appears to be invalid.
warning Resolution field “@elastic/elasticsearch@8.5.0” is incompatible with requested version “@elastic/elasticsearch@8.6.0”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@^2.29.1”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@2.29.1”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@^2.27.0”
warning Resolution field “moment-timezone@0.5.23” is incompatible with requested version “moment-timezone@^0.5.31”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@2.29.4”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@2.29.4”
warning Resolution field “moment-timezone@0.5.23” is incompatible with requested version “moment-timezone@0.5.34”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@2.29.1”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@2.29.3”
warning Resolution field “moment-timezone@0.5.23” is incompatible with requested version “moment-timezone@^0.5.33”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@2.27.0”
warning Resolution field “@tryghost/logging@2.4.1” is incompatible with requested version “@tryghost/logging@2.4.0”
warning Resolution field “@tryghost/logging@2.4.1” is incompatible with requested version “@tryghost/logging@2.4.0”
warning Resolution field “moment@2.24.0” is incompatible with requested version “moment@^2.29.1”
warning “@tryghost/kg-lexical-html-renderer > @lexical/rich-text@0.7.9” has unmet peer dependency “@lexical/selection@0.7.9”.
warning “@tryghost/kg-lexical-html-renderer > @lexical/rich-text@0.7.9” has unmet peer dependency “@lexical/utils@0.7.9”.
warning " > bookshelf@1.2.0" has incorrect peer dependency “knex@>=0.15.0 <0.22.0”.
warning Workspaces can only be enabled in private projects.

yarn install v1.22.19
[1/5] Validating package.json…
[2/5] Resolving packages…
[3/5] Fetching packages…
[4/5] Linking dependencies…

Debug Information:
OS: Debian GNU/Linux, v11
Node Version: v18.14.2
Ghost-CLI Version: 1.24.0
Environment: production
Command: ‘ghost install’

Additional log info available in: /home/node/.ghost/logs/ghost-cli-debug-2023-03-06T00_48_17_186Z.log

Try running ghost doctor to check your system for known issues.

You can always refer to Ghost-CLI - A fully loaded tool for installation and configuration for troubleshooting.