By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,101 Members | 1,335 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,101 IT Pros & Developers. It's quick & easy.

Backup&Restore Postgres DB

P: 1
Hi all,

I need to backup and restore a DB.
In this particular case the data in the database is not important (strange hum...) but only the schema to put new data...

I m thinking use the pg_dump:

pg_dump -c -C -s schema > file.out

With this i have in file.out the schema, correct?

So, to restore the db from scratch, for example to a new system, what should i do?
it automatically creates all users, rolls, permissions etc?How?

What is the best way of doing it?


Many thanks
Mar 22 '10 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.