Update from 5.22.10 failing

Issue Summary
Trying to update from 5.22.10 but the update takes an inordinate amount of time and then eventually fails. Previous updates have taken a lot less time to execute.

Steps to Reproduce

I’m using ‘ghost update --no-check-mem’ because updates stopped working due to the memory check at some point. This has worked for a while but now this failure is different.


Setup information

Ghost Version Currently at 5.22.10
Node.js Version v14.20.1
How did you install Ghost? Using Digital Ocean’s install droplet initially
Provide details of your host & operating system Digital Ocean - Linux 4.15.0-194 kernel
Database type MySQL 8

Relevant log / error output
I executed the update with verbose turned on. Here are the last handful of output lines that led to the failure.

[21:56:29] → verbose 1610.269779801 Copying “/home/ghost-mgr/.cache/yarn/v6/npm-@stdlib-random-0.0.12-e819c3abd602ed5559ba800dba751e49c633ff85-integrity/node_modules/@stdlib/random/streams/negative-binomial/package.json” to “/var/www/ghost/versions/5.23.0/node_modules/@stdlib/random/streams/negative-binomial/package.json”.
[21:56:29] → verbose 1610.272255778 Copying “/home/ghost-mgr/.cache/yarn/v6/npm-@stdlib-random-0.0.12-e819c3abd602ed5559ba800dba751e49c633ff85-integrity/node_modules/@stdlib/random/streams/mt19937/README.md” to “/var/www/ghost/versions/5.23.0/node_modules/@stdlib/random/streams/mt19937/README.md”.
[21:56:29] → verbose 1610.273977393 Copying “/home/ghost-mgr/.cache/yarn/v6/npm-@stdlib-random-0.0.12-e819c3abd602ed5559ba800dba751e49c633ff85-integrity/node_modules/@stdlib/random/streams/mt19937/package.json” to “/var/www/ghost/versions/5.23.0/node_modules/@stdlib/random/streams/mt19937/package.json”.
[21:56:29] → verbose 1610.27539612 Copying “/home/ghost-mgr/.cache/yarn/v6/npm-@stdlib-random-0.0.12-e819c3abd602ed5559ba800dba751e49c633ff85-integrity/node_modules/@stdlib/random/streams/normal/README.md” to “/var/www/ghost/versions/5.23.0/node_modules/@stdlib/random/streams/normal/README.md”.
[22:09:35] Installing dependencies [failed]
[22:09:35] → stdout maxBuffer exceeded
[22:09:35] Downloading and updating Ghost to v5.23.0 [failed]
[22:09:35] → stdout maxBuffer exceeded
A ProcessError occurred.

Message: stdout maxBuffer exceeded

Debug Information:
OS: Ubuntu, v18.04.6 LTS
Node Version: v14.20.1
Ghost Version: 5.22.10
Ghost-CLI Version: 1.23.1
Environment: production
Command: ‘ghost update --no-check-mem -V’

Have you tried adding swap space to your DigitalOcean droplet?

I’m not familiar with the particular error that you’re seeing, but I’ve had issues in the past trying to run Ghost updates, which were resolved by adding swap space to my droplets.

I add 2 GB of swap space but you might easily get away with only adding 1 GB (as they do in the tutorial I’m linking to below).

For context, I run each of my Ghost instances on a separate droplet, the smallest one, which is 1 GB memory / 1 AMD vCPU / 25 GB disk. And I haven’t experienced any issues or errors since learning that I needed to add swap space.

I hope this helps you and if it doesn’t, I hope that somebody else will come along shortly and provide the help you need.

All the best!

Wow - great suggestion. I had no idea that swap wasn’t added. This solved the memory issue on doing the update but I’m still getting the same failure.

[01:37:56] Installing dependencies [failed]
[01:37:56] → stdout maxBuffer exceeded
[01:37:56] Downloading and updating Ghost to v5.23.0 [failed]
[01:37:56] → stdout maxBuffer exceeded
A ProcessError occurred.

Message: stdout maxBuffer exceeded

Debug Information:
OS: Ubuntu, v18.04.6 LTS
Node Version: v14.20.1
Ghost Version: 5.22.10
Ghost-CLI Version: 1.23.1
Environment: production
Command: ‘ghost update -V’

Looks like the yarn error log file has this error although I don’t understand what this actually means and/or how to fix it.

Trace:
Error: ENOENT: no such file or directory, copyfile ‘/home/ghost-mgr/.cache/yarn/v6/npm-@stdlib-assert-0.0.12-1648c9016e5041291f55a6464abcc4069c5103ce-integr
ity/node_modules/@stdlib/assert/has-arraybuffer-support/docs/types/test.ts’ → ‘/var/www/ghost/versions/5.23.0/node_modules/@stdlib/assert/has-arraybuffer-sup
port/docs/types/test.ts’

Have you tried running Ghost Doctor from the CLI tool?

Yeah - no errors from ‘ghost doctor’ at all. Even shut down the instance so everything got scanned and all good.

As I started to spin up a new droplet to just do a clean install, the upgrade suddenly worked. No idea what made it all click but I’m now on 5.23.0.