Skip to content
Snippets Groups Projects
Verified Commit 6eee8fcc authored by anarcat's avatar anarcat
Browse files

tweak psql procedure so it actually works

The $() was being interpolated by the caller, and the
pg_upgradecluster command was incomplete.
parent f50713e7
No related branches found
No related tags found
No related merge requests found
......@@ -120,7 +120,7 @@ PostgreSQL is special and needs to be upgraded manually.
1. make a full backup of the old cluster:
ssh bungei.torproject.org "sudo -u torbackup postgres-make-one-base-backup $(grep ^meronense.torproject.org $(which postgres-make-base-backups ))"
ssh -tt bungei.torproject.org 'sudo -u torbackup postgres-make-one-base-backup $(grep ^meronense.torproject.org $(which postgres-make-base-backups ))'
The above assumes the host to backup is `meronense` and the backup
server is `bungei`. See [howto/postgresql](howto/postgresql) for details of that
......@@ -137,7 +137,7 @@ PostgreSQL is special and needs to be upgraded manually.
printf "about to drop cluster main on postgresql-11, press enter to continue" &&
read _ &&
pg_dropcluster --stop 11 main &&
pg_upgradecluster -m upgrade -k &&
pg_upgradecluster -m upgrade -k 9.6 main &&
for cluster in `ls /etc/postgresql/9.6/`; do
mv /etc/postgresql/9.6/$cluster/conf.d/* /etc/postgresql/11/$cluster/conf.d/
done
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment