Building bootstrap error

I had that assumption too, just have no clue how to work with postgres via discourse.

Its just weird because My issue was resolved from the prior thread, then when I added discourse-reactions and attempted to rebuild I just started getting this. Now nothing works even without plugins added lmao

Based on the error code, I was thinking it was like this issue Upgrade gone sideways [deprecated Guest Gate plugin], which made me concentrate on getting the plugins up-to-date. However, there may also have been an issue where they’d manually forced the old PSQL, and they fixed that before cleaning up the old plugins (which then fixed things properly) Upgrade gone sideways [deprecated Guest Gate plugin] - #3 by dylanb

But I’m afraid resolving that is beyond my skill level. :slight_smile: Does that topic give any extra clues for you?

I was looking at that earlier too, sadly I could not see anything to help me… and I really hope my forum data is not going to be wiped… I have not had a backup created in a very very long time, so losing data would be unbelievably heartbroken.

Could you start your existing container to bring up the pre-rebuild version and take a backup before continuing?

./launcher start app

Sadly I don’t think the container exists anymore as a fix I was attempting was to do a complete uninstall of docker and re-install. which left me with no existing container. So attempting to run that command now just leaves me with:

I also found this article: Database system was not properly shut down error when rebuilding - support - Discourse Meta

Starting to get real depressed now as everything im finding is pointing towards saying data loss…

I really hope someone can help me find a way of fixing this without losing data as the only backup I can see I have is from a year ago.

Probably nothing to do with anything but a 4.15.0-91 kernel, isn’t it a bit old, 30months or so ?

Yeah its pretty old lol since I created the server basically. But that should not have anything to do with it since its been starting fine.

1 Like

the alternative being maybe data corruption/loss, I guess I rather find out there have been some weird dependency issue between an old kernel and docker 20.10 that in turn kept psql to start… but I agree that’s a looong shot :roll_eyes: and that would beg the question “why now?”

I really doubt this, I feel like it has to be I must have stopped and uninstalled/reinstalled docker during the shutdown process of the database, im not entirely sure though.

2 Likes

What is the contents of /var/discourse/shared/standalone?

1 Like

find that using ls /var/discourse/shared/standalone

1 Like

I moved that to a different volume the contents are shown below:

root@discourse:/var/discourse# ls /mnt/volume-2/standalone/ -al
total 64
drwxr-xr-x 16 root            root     4096 Feb  5  2021 .
drwxr-xr-x  3 root            root     4096 Aug 30  2020 ..
drwxr-xr-x  3            1000 www-data 4096 Aug 30  2020 backups
drwxr-xr-x 10 root            root     4096 Nov 20 08:35 letsencrypt
drwxr-xr-x  4 root            root     4096 Aug 30  2020 log
drwxr-xr-x  2 systemd-resolve input    4096 Aug 30  2020 postgres_backup
drwx------ 19 systemd-resolve input    4096 Nov 20 12:01 postgres_data
drwx------ 20 uuidd           uuidd    4096 Feb  5  2021 postgres_data_old
drwxrwxr-x  5 systemd-resolve input    4096 Nov 20 12:01 postgres_run
drwxr-xr-x  2 messagebus      syslog   4096 Nov 20 08:38 redis_data
drwxr-xr-x  2 root            root     4096 Dec  1  2020 ssl
drwxr-xr-x  3 root            root     4096 Aug 30  2020 standalone
drwxr-xr-x  4 root            root     4096 Aug 30  2020 state
drwxr-xr-x  4            1000 www-data 4096 Nov 20 08:36 tmp
drwxr-xr-x  2 root            root     4096 Aug 30  2020 uploads
drwxr-xr-x  4 root            root     4096 Aug 30  2020 uploads.orig

So even without the container, it appears you have some state of the database potentially intact. Whatever you experiment with, keep a copy of this safe.

The way things are set up you can normally access the DB from within container as it sits on a docker volume.

If you can get a container built again you may be able to access this again, or else you would need to install postgres on the server (but that will be redundant once you get things working again).

Yeah the hardest part is just getting the rebuild to even work. Without that Im basically screwed as it seems.

But ill def copy the contents of this folder to my local machien just in case

It looks like a failed postgres update to me. @Headless what is the last time you updated your site from command line?

Updated as in pulling and rebuilding? I do it every few months or so.

what is the most recent backup?

ls /var/discourse/shared/standalone/backups ?

Its a year old backup, previously mentioned earlier.

I ended up turning off backups at one point so thats my fault.

It’ll be a very adventurous rodeo to try and recover this site. I haven’t done these recoveries in a while so my memory is a bit rusty. let me see if I can find any existing topics with the instructions on recovery.