We are having some problems when trying to upgrade PostgreSQL 9.4. to 9.6 #57
tabdoelhafiezkhan
started this conversation in
General
Replies: 2 comments
-
Where is the 9.4 data currently stored on the host (precise path), and where do you want the 9.6 data to be stored after the upgrade? |
Beta Was this translation helpful? Give feedback.
0 replies
-
hello tianon,
Thanks for the quick reply. We managed to do the upgrade.
These where some of the issues:
1. Our environment did not seem to be able to handle the quotes in ex:
OLD='9.4'
2. We forgot to run a container on the mountpount / volume
3. We where a bit confused with this in your documentation:
$ docker run --rm \
-v /mnt/bigdrive/postgresql-9.4:/var/lib/postgresql/9.4/data \
-v /mnt/bigdrive/postgresql-9.5:/var/lib/postgresql/9.5/data \
tianon/postgres-upgrade:9.4-to-9.5
...
(which assumes that your previous postgres:9.4 instance was running with -v
/mnt/bigdrive/postgresql-9.4:/var/lib/postgresql/data, and your new
postgres:9.5 instance will run with -v
/mnt/bigdrive/postgresql-9.5:/var/lib/postgresql/data)
Kind regards,
Tim
2017-05-30 8:10 GMT+02:00 Tianon Gravi <[email protected]>:
… Where is the 9.4 data currently stored on the host (precise path), and
where do you want the 9.6 data to be stored after the upgrade?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#3 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ARcBOh50oT4zIJpuDh0Im_HmVGgfscC2ks5r-7LDgaJpZM4NpKnf>
.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello tianon,
Thank you for the image. We hope you can help us with this question: We are trying to upgrade from postgres 9.4 to 9.6, but the docker hub default images do not have the postgres version in there path $PGDATA. So it's /var/lib/postgresql/data and not /var/lib/postgresql/9.4/data.
We are getting these errors when trying the upgrade:
TEST1:
[tiabd@dockerbuild tmp]$ docker run --rm
-v /tmp/9.4:/var/lib/postgresql/data
-v /tmp/9.6:/var/lib/postgresql/data
tianon/postgres-upgrade:9.4-to-9.6
docker: Error response from daemon: Duplicate mount point '/var/lib/postgresql/data'.
See 'docker run --help'.
[tiabd@dockerbuild tmp]$
TEST2:
[tiabd@dockerbuild tmp]$ docker run --rm \
...
...
initdb: directory "/var/lib/postgresql/9.6/data" exists but is not empty
If you want to create a new database system, either remove or empty
the directory "/var/lib/postgresql/9.6/data" or run initdb
with an argument other than "/var/lib/postgresql/9.6/data".
Failure, exiting
TEST3:
[tiabd@dockerbuild tmp]$ docker run --rm -v /tmp/9.4:/var/lib/postgresql/9.4/data -v /tmp/9.6:/var/lib/postgresql/9.6/data tianon/postgres-upgrade:9.4-to-9.6
...
check for "/var/lib/postgresql/9.4/data/base" failed: No such file or directory
Failure, exiting
Hope you can help us further.
Kind regards,
Tim
Beta Was this translation helpful? Give feedback.
All reactions