Database Reference
In-Depth Information
Creating a backup
By default, PG Backups take backups of your primary database, available via the
DATABASE_URL configuration variable.
To generate a new backup, you must enter the command manually:
$ heroku pgbackups:capture --app your-app-name
HEROKU_POSTGRESQL_COBALT_URL (DATABASE_URL) ----backup--->
b002
Capturing... done
Storing... done
Tip
Backups are always compressed, and are always smaller than the size of your database.
If you have another database in your app, you can specify the database to take the back up
through this configuration variable:
$ heroku pgbackups:capture HEROKU_POSTGRESQL_[COLOR]_URL
--app your-app-name
Tip
Automated backups are always performed on the primary database, available via the
DATABASE_URL configuration variable.
Each plan has a limit for manual backups, so, if you have already reached this limit, you
will need to delete the previous backup so that you can take a new manual backup. You can
do it through the --expire flag:
$ heroku pgbackups:capture --expire --app your-app-name
There is another way to perform backups; you can take backups through the GUI (graphical
user interface) provided to manage your Postgres databases in https://postgres.heroku.com/
databases . For this, click on the name of your database; after this, click on the gear icon on
the right-hand side and select the New Snapshot option.
Search WWH ::




Custom Search