dbTalk Databases Forums  

Dump DB users

comp.databases.postgresql comp.databases.postgresql


Discuss Dump DB users in the comp.databases.postgresql forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
GG
 
Posts: n/a

Default Dump DB users - 08-17-2007 , 07:34 AM






Hello

In Postgres "Backup and Restore" documentation I found
"Before restoring a SQL dump, all the users who own objects or were
granted permissions on objects in the dumped database must already
exist". How can I backup postgres users ?


Thanks in advance
GG

Reply With Quote
  #2  
Old   
Laurenz Albe
 
Posts: n/a

Default Re: Dump DB users - 08-20-2007 , 05:05 AM






GG <gg (AT) mymail (DOT) pl> wrote:
Quote:
In Postgres "Backup and Restore" documentation I found
"Before restoring a SQL dump, all the users who own objects or were
granted permissions on objects in the dumped database must already
exist". How can I backup postgres users ?
pg_dumpall --globals-only >metadata.sql

will create a dump of users, roles and tablespaces as SQL script.

You can edit it if you only want specific users.

Yours,
Laurenz Albe


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.