PostgreSQL 8.4 - dumping database connection privileges

Поиск
Список
Период
Сортировка
От Russell Smith
Тема PostgreSQL 8.4 - dumping database connection privileges
Дата
Msg-id 4BDBF507.5030006@pws.com.au
обсуждение исходный текст
Ответы Re: PostgreSQL 8.4 - dumping database connection privileges  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
Hi,

I've recently upgraded to PostgreSQL 8.4 as Redhat had begun supporting
it.  I have tried to dump database grants, but have only found an
obscure way to do it.

I would expect;

postgres$ pg_dump -Fc database_name > backup.pgdump

would include all of the GRANT CONNECT on database_name TO "Role";
commands.  It does not.

Second I tried;

postgres$ pg_dumpall -g  > globals.sql

This also did not produce any GRANT CONNECT statements.


The only method I found that works is;

postgres$ pg_dumpall -s | grep 'ON DATABASE'

This method is not exactly fool proof and isn't what I expected to have
to do.


Is this considered a bug that the only way to do a dump/restore with
database privileges is to use pg_dumpall?  I expect that pg_dump of a
database would include all of that information.  I would argue it is at
least a misfeature and difficult for even an experienced user to understand.

Regards

Russell

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Vladimir Kokovic
Дата:
Сообщение: CVS build problem - make world target
Следующее
От: Robert Haas
Дата:
Сообщение: Re: BUG #5444: Database Backup Restore - Out of memory problem