LemmyNet / lemmy-ansible

A docker deploy for ansible
GNU Affero General Public License v3.0
248 stars 92 forks source link

Failed running postgres_15_to_16_upgrade.sh #245

Closed aeharding closed 4 months ago

aeharding commented 4 months ago
aeharding@vps-1ed43a8e:/srv/lemmy/vger.social$ sudo sh postgres_15_to_16_upgrade.sh
Do not stop in the middle of this upgrade, wait until you see the message: Upgrade complete.
Stopping lemmy and all services...
WARN[0000] /srv/lemmy/vger.social/docker-compose.yml: `version` is obsolete
[+] Stopping 6/6
 ✔ Container vgersocial_proxy_1     Stopped                                                                                                                                   0.4s
 ✔ Container vgersocial_postfix_1   Stopped                                                                                                                                   0.4s
 ✔ Container vgersocial_lemmy-ui_1  Stopped                                                                                                                                   0.2s
 ✔ Container vgersocial_lemmy_1     Stopped                                                                                                                                   0.6s
 ✔ Container vgersocial_postgres_1  Stopped                                                                                                                                   2.2s
 ✔ Container vgersocial_pictrs_1    Stopped                                                                                                                                   0.8s
Make sure postgres is started...
WARN[0000] /srv/lemmy/vger.social/docker-compose.yml: `version` is obsolete
[+] Running 2/2
 ✔ Container vgersocial_postgres_1  Recreated                                                                                                                                 0.1s
 ✔ Container vgersocial-postgres-1  Started                                                                                                                                   0.3s
Waiting...
Exporting the Database to 15_16.dump.sql ...
WARN[0000] /srv/lemmy/vger.social/docker-compose.yml: `version` is obsolete
Done.
Stopping postgres...
WARN[0000] /srv/lemmy/vger.social/docker-compose.yml: `version` is obsolete
[+] Stopping 1/1
 ✔ Container vgersocial-postgres-1  Stopped                                                                                                                                   0.4s
Waiting...
Removing the old postgres folder
Updating docker compose to use postgres version 16.
sed: -e expression #1, char 42: unknown option to `s'

Editing the postgres version manually and then running the commands after that succeeded.

Machine info:

Linux vps-1ed43a8e 6.1.0-20-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.85-1 (2024-04-11) x86_64
dessalines commented 4 months ago

Oof, I did not add that docker.io part so didn't test it. Good catch, I'm fixing it in the PR above.

dessalines commented 4 months ago

The file is on the other repo so I'll close this one.