Tumblelog by Soup.io
Newer posts are loading.
You are at the newest post.
Click here to check if anything new just came in.

Postgresql Upgrade on Gentoo/Linux

Short walkthru Migrating_PostgreSQL
old=9.3
new=9.4

/etc/init.d/postgresql-$old stop
rc-update del postgresql-$old
eselect postgresql set $new
su - postgres
ln -s /etc/postgresql-$old/*.conf /var/lib/postgresql/$old/data
ln -s /etc/postgresql-$new/*.conf /var/lib/postgresql/$new/data
initdb  /var/lib/postgresql/9.4/data \
  -E utf8 --locale=en_US.UTF-8  --lc-collate=C
pg_upgrade94 \
  -b /usr/lib64/postgresql-$old/bin \
  -B /usr/lib64/postgresql-$new/bin \
  -d /var/lib/postgresql/$old/data \
  -D /var/lib/postgresql/$new/data
exit
mv /var/lib/postgresql/$new/data/*.conf /etc/postgresql-$new
/etc/init.d/postgresql-$new start
rc-update add postgresql-$newdefault
Tags: linux own

Don't be the product, buy the product!

Schweinderl