Ghost memory errors on update

I recently updated to Ubuntu 20.04 on a 1GB droplet running Ghost. Now, whenever I run ghost update or similar, I get a memory error:

You are recommended to have at least 150 MB of memory available for smooth operation. It looks like you have ~45.265625 MB available.

The memory available varies between 30 MB and almost 150 MB, but it always throws this error.

As suggested in the Ghost forum, I ran free -h (which repeated the warning, and then ghost restart (which did not).

Any ideas? Thanks.

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Hey there! Old post but thought I’d post to help others :)

I had this issue too running the most basic droplet type. I followed this Digital Ocean guide to add a “swap file” on my instance. This basically allocates some SSD space to use as “pretend memory”, and then I was able to upgrade ghost as normal.

Alternatively you could simply resize your droplet to one with more RAM/memory.

Hope that helps someone!

Adding a 2GB swap file with a swappiness of 10 solved my memory errors. More info here.

However, is this a bad practice? How will it affect my server usage?