Hi
I just upgraded from v3.42.2 to v4.0.1 and now ghost won’t start
System: CentOS 7
Node: v14.16.0
$ ghost -v
Ghost-CLI version: 1.16.2
Ghost version: 4.0.1
When I run ghost start
everything seems fine, running ghost ls
shows my blog as running on correct port. All looks fine. Last message for ghost log
is INFO Ghost booted in 2.476s
.
As soon as I access my blog in the browser, I see a 500 error message. Checking ghost log
shows
[2021-03-16 21:19:40] INFO Ghost booted in 2.476s
[2021-03-16 21:19:41] WARN Ghost is shutting down
[2021-03-16 21:19:41] WARN Ghost has shut down
[2021-03-16 21:19:41] WARN Your site is now offline
[2021-03-16 21:19:41] WARN Ghost was running for a few seconds
[2021-03-16 21:19:41] WARN Ghost is shutting down
[2021-03-16 21:19:41] WARN Ghost has shut down
[2021-03-16 21:19:41] WARN Your site is now offline
[2021-03-16 21:19:41] WARN Ghost was running for a few seconds
nginx error log shows
2021/03/16 21:21:01 [error] 22604#0: *1354743 connect() failed (111: Connection refused) while connecting to upstream, client: 111.222.333.444, server: example.com, request: "GET /favicon.ico HTTP/1.1", upstream: "http://127.0.0.1:2368/favicon.ico", host: "example.com", referrer: "https://example.com/"
The weirdest part is when I run ghost run
everything is fine and I can access and navigate the site just fine.
Why ghost run
works but ghost start
fails?
Edit
I’ve noticed that somehow I have two versions of node. I use n control versions.
$ sudo node -v
v6.17.1
$ node -v
v14.16.0
Running sudo ln -sfn /usr/local/bin/node /bin/node
made them the same, but didn’t fix my problem.