InterNetWorkingSolutions Support Site


Backing up your Postgresql Database

Posted in by kevin on Tue, 08/08/2006 - 11:16am

Following are the steps to backup your Postgresql Database(s):

  1. Login to http://YOURDOMAINNAME.COM:10000
    postgres.backup.1
  2. Go to the "System" Link on the top then on the "Scheduled Cron Jobs"
    postgres.backup.2
  3. Click on the "Create a new scheduled cron job" link.
  4. Type the following in the following sections:
    1. Command: /usr/bin/pg_dump -f ~/DATABASENAME.backup.sql DATABASENAME
      1. If you want to have unique backups by day
        1. /usr/bin/pg_dump -f ~/DATABASENAME.`date "+%d%b"`.backup.sql DATABASENAME
    2. When to execute
      1. simple schedule:  Daily
        postgres.backup.3
         
  5. Click on create.
  6. Repeat for each of your databases.
    1. The names of your databases can be found by going to "Servers"  then postgreql.
login or register to post comments | 669 reads