Fixing discourse after disk full

My AWS ec2 instance ran out of disk space (it has 16GB). I ran rm -rf /var/lib/docker/overlay2 and journalctl --vacuum-time=10d to free up space, and now df says I have 7GB of free space. after rebooting the instance I get Connection refused when trying to connect to the page.

I tried sudo ./launcher rebuild app but it fails saying there less than 5GB of disk space.

Any suggestions?

1 Like

try

./launcher cleanup

2 Likes

25GB is usually the recommended minimum. Even if you can get it back up running with your current allocation this is going to happen again with such a small volume.

1 Like

Just to note, Hetzner’s lowest tier offers only 20GB, but that’s been working for me. It can be worth tidying up the backups directory before trying an upgrade: having, of course, taken a new backup and copied it elsewhere for safety. (It’s a small forum: a backup is 120MB.)

In another case, I use Digital Ocean’s lowest tier, offering 25G, and in that case the forum’s backup comes in at 640MB.)

The one time I had trouble, it was the journal thing, but I cut that right down:

# journalctl --disk-usage
Archived and active journals take up 104.0M in the file system.

Ok, I have increased the size of the disk so discourse-doctor sees 40G (29% used) so space is no longer the issue. I need help getting discourse up and running.

sudo ./launcher start app fails with
Unable to find image 'local_discourse/app:latest' locally

The failing output of sudo launcher rebuild app is here

How do I fix this?

ok I got sudo launcher rebuild app to work by changing “templates/postgres.template.yml” to “templates/postgres.10.template.yml” in app.yml

Should I leave that change, or change it back and try rebuilding?

I think you need to visit the postgres update thread and ask for help…

1. UPGRADE OF POSTGRES FAILED

 * Please visit https://meta.discourse.org/t/postgresql-12-update/151236 for support
3 Likes