svn commit: r505245 - in head/databases: postgresql10-client postgresql10-contrib postgresql10-pgtcl postgresql10-server postgresql11-client postgresql11-server postgresql94-server postgresql95-cli...

Matthias Fechner idefix at fechner.net
Thu Aug 8 18:14:28 UTC 2019


Am 08.08.2019 um 12:50 schrieb Matthias Fechner:
> I did now a successfull update (with the old Gitlab version) to
> PostgreSQL 11 (on a test environment) with:
> service gitlab stop
> service postgresql stop
> pkg create postgresql96-server postgresql96-contrib
> mkdir /tmp/pg-upgrade
> tar xf postgresql96-server-9.6.14_1.txz -C /tmp/pg-upgrade
> tar xf postgresql96-contrib-9.6.14_1.txz -C /tmp/pg-upgrade
>
> pkg delete -f postgresql96-server postgresql96-contrib postgresql96-client
> pkg install postgresql11-server postgresql11-contrib postgresql11-client
> pkg upg
>
> /usr/local/etc/rc.d/postgresql initdb
> su -l postgres -c "pg_upgrade -b /tmp/pg-upgrade/usr/local/bin/ -d
> /var/db/postgres/data96/ -B /usr/local/bin/ -D /var/db/postgres/data11/"
>
> service postgresql start
> service gitlab start
>
> #Verify everything works
> su -l postgres -c "cd /var/db/postgres && /usr/local/bin/vacuumdb --all
> --analyze-in-stages"
> su -l postgres -c "cd /var/db/postgres && rm -rf '/var/db/postgres/data96'"
> rm /var/db/postgres/analyze_new_cluster.sh
> rm /var/db/postgres/delete_old_cluster.sh
>
> rm -R /tmp/pg-upgrade
>
>
> You maybe have to adapt the version from 96 to 95 if you use the current
> standard version from ports.
>
> Maybe this helps some to do further tests with the PostgreSQL version 11.

I upgraded now all my production databases with these steps from version
9.6 -> 11.

Gruß
Matthias

-- 

"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the universe trying to
produce bigger and better idiots. So far, the universe is winning." --
Rich Cook



More information about the svn-ports-head mailing list