Last active
September 28, 2018 17:12
-
-
Save ray-odoo/bd97d69b3e308d10f531c8392b71f7d6 to your computer and use it in GitHub Desktop.
Large database backup and restore process
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
OUT: | |
pg_dump production --no-owner --format=c --file=production.sql | |
FILESTORE: | |
tar -czvf /home/ubuntu/production.tar.gz production | |
IN: | |
createdb prod_backup_date --owner=odoo | |
pg_restore --dbname=prod_backup_date --format=c --no-owner --role=odoo < production.sql | |
tar -xvf production.tar.gz ./prod_backup_date |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment