-
-
Save ceesco53/c0d9766ff313b350931b42748e429496 to your computer and use it in GitHub Desktop.
Backup/Restore Concourse DB
This file contains hidden or 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
| # from Concourse DB VM: | |
| # /var/vcap/packages/postgres-9.6.8/bin/psql -U vcap -d atc | |
| # \l | |
| # backup | |
| cd /var/vcap/packages/postgres-9.6.8/bin | |
| ./pg_dump -U vcap -d atc --format=c --schema-only --file=concourse-schema.sql | |
| ./pg_dump -U vcap -d atc --format=c --data-only --file=concourse-data.sql | |
| # restore | |
| /var/vcap/packages/postgres-9.6.8/bin | |
| ./pg_restore -U vcap -d atc -v concourse-schema.sql | |
| ./pg_restore -U vcap -d atc -v concourse-data.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment