newbie psql - Backup/Restore - database

From: "Nguyen, Dan" <danguyen(at)lsil(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Subject: newbie psql - Backup/Restore - database
Date: 2002-10-21 18:39:43
Message-ID: EB1DF7EA0D32D611B79C0002A51363F17004F2@exw-ks.ks.lsil.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hello all,

I just convert a MSQL database to PSQL and wondering if someone can help me
to duplicate or restore a database in a short period. Here is what I have
done.

Backup <users> database:
pg_dump -C -D -n -f backupDB.psql users

Duplicate <users> database:
1. createdb test
2. edit the backupDB.psql file and remove the first block regarding users
DATABASE
3. psql -a -e -f backupDB.psql test

Doing this way will take about a hour to duplicate a database with about
50,000 records. Is there any other ways that you can help me to speed up
the process?

All of your help will be greatly appreciated.

Dan

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Josh Goldberg 2002-10-21 18:41:10 Re: How to get user names and passwords
Previous Message Rusty Wright 2002-10-21 18:22:31 Re: newbie qs; examining databases and tables