Hello,

I tried to update my instance but I forgot to read the release notes and used ansible to update. Of course it failed. After the update I decided to check what is new and I realized my mistake. I tried to run the postgress update script but it fails with the message

Error response from daemon: Container {container hash} is restarting, wait until the container is running

The logs say that the db hasn’t been updated.

I don’t know what else to upload here to help troubleshooting. Thanks in advance!

Dessalines
mod
link
fedilink
12Y

You’ll have to post your docker logs.

sudo docker-compose logs lemmy


donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
donkysocial-lemmy-1  | thread 'main' panicked at 'Error connecting to postgres://lemmy:pass@postgres:5432/lemmy', crates/db_schema/src/utils.rs:157:56
donkysocial-lemmy-1  | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Dessalines
mod
link
fedilink
12Y

It can’t connect to the DB because you didn’t do the upgrade properly. Follow these instructions: https://github.com/LemmyNet/lemmy/blob/main/RELEASES.md#upgrade-instructions

I have followed them. Whenever I run the sudo sh postgres_12_to_15_upgrade.sh I get

Do not stop in the middle of this upgrade, wait until you see the message: Upgrade complete.
Stopping lemmy and all services...
Stopping donkysocial_postgres_1 ... done
Stopping donkysocial-lemmy-ui-1 ... done
Stopping donkysocial-lemmy-1    ... done
Stopping donkysocial-pictrs-1   ... done
Stopping donkysocial-postfix-1  ... done
Make sure postgres is started...
Starting donkysocial_postgres_1 ... done
Exporting the Database to 12_15.dump.sql ...
Error response from daemon: Container a1e2ddeced29b9060049e920b49bcea87189b0122a68f015ada202a6181bd2a0 is restarting, wait until the container is running
Dessalines
mod
link
fedilink
12Y

That error tells me nothing. Please ask in the matrix channel, I’m very busy with coding.

Alright, sorry for bothering you.

Support / questions about Lemmy.

  • 0 users online
  • 12 users / day
  • 24 users / week
  • 26 users / month
  • 19 users / 6 months
  • 11 subscribers
  • 140 Posts
  • 444 Comments
  • Modlog