Using following commands you can backup and restore the database without worrying about the versions.
Backup: pg_dump --host host_name -U USER_NAME --port DB_PORT DB_NAME > path/file_name.sql
Restore: psql DB_NAME -U USER_NAME -f path/file_name.sql
I think the easiest way is to upgrade 8.4 cluster instead of migrating one database. Below I provide steps to do that, hope it'll be helpful.
1. Install both PostgreSQLs: 8.4 and 9.1
2. Check that you have two clusters running using the command:
3. Drop cluster 9.1
pg_dropcluster --stop 9.1
4. Upgrade cluster 8.4
pg_upgradecluster 8.4 main
5. It will take some time to upgrade, and copying all your config from old cluster to the new one.
6. Test if it works
7. Drop 8.4
pg_dropcluster --stop 8.4
8. Upgrade to 9.3 eventually. ;)
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
|Asked: 7/29/14, 3:08 AM|
|Seen: 935 times|
|Last updated: 10/16/15, 5:54 AM|