pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@gmail.com>
To: Edward W. Rouse <erouse@comsquared.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: copy users/groups
Date: Tue, 08 Jan 2013 07:25:25 -0800
Message-ID: <50EC3A65.6080203@gmail.com> (raw)
In-Reply-To: <021a01cdedb1$ff7340b0$fe59c210$@com>
References: <021a01cdedb1$ff7340b0$fe59c210$@com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-sql>

On 01/08/2013 07:08 AM, Edward W. Rouse wrote:
> We have a database that was updated from 7.4.1 to 9.1.3. I've gotten
> everything working, but now it seems that the users and groups weren't
> restored. Probably because they weren't backed up. Is there a way to dump
> just the users and groups, plus the passwords and permissions, and restore
> them without overwriting what's been manually added to the new database?

Users/groups i.e roles are global to a cluster, you need to use pg_dumpall:

http://www.postgresql.org/docs/9.1/interactive/app-pg-dumpall.html

pg_dumpall -g

Will dump only the global items.

>
>
> Edward W. Rouse
>
>
>


-- 
Adrian Klaver
adrian.klaver@gmail.com


-- 
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-sql



view thread (2+ messages)

Message-ID: <50EC3A65.6080203@gmail.com>
Permalink:  ../50EC3A65.6080203@gmail.com/
Also on:    postgresql.org/message-id/50EC3A65.6080203@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: adrian.klaver@gmail.com, erouse@comsquared.com
  Subject: Re: copy users/groups
  In-Reply-To: <50EC3A65.6080203@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox