Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Full Backup

Creating database backups is essential in any server setup in case of a server crash or if a modification goes wrong and data is accidentally deleted.

pg_dumpall > backupfile

pg_dumpall backs up all databases, users and permissions. ..This is good for small databases that do not require a lot of space.

Incremental Backup

To make incremental backups you need to create a base backup 

pg_dump db > backupfile

pg_dump only backs up one database at a time and does not save the users or permissions. ..Restoring from pg_dump requires that you have a base backup set in before you can restore otherwise you will get errors when you restore. 

Restoring Database

pg_restore

...