Re: pg_restore

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: pg_restore
Дата
Msg-id 20050811204603.GA2886@wolff.to
обсуждение исходный текст
Ответ на pg_restore  ("D Kavan" <bitsandbytes88@hotmail.com>)
Ответы Re: pg_restore
Список pgsql-admin
On Thu, Aug 11, 2005 at 15:29:22 -0400,
  D Kavan <bitsandbytes88@hotmail.com> wrote:
> Hi all,
>
> We are running postgres 8.03.
>
> Getting a dump is no problem on our 6 GB database.  However, the restore is
> a killer, it takes 10 minutes for the dump pg_dump, but over 5 hours for a
> restore.  Is there a way to 'turn off transactions' on the restore to speed
> things up?   I've tried different restore commands, but I don't see
> anything on transactions logging.  What else could speed it up?   oracle
> and sybase can restore the same db in just 90 minutes.    Does postgres
> just not know how to take advantage of the resources unless different users
> are involved?  In other words to speed it up, should I script different
> users to each restore some of the tables to a database and then after all
> the tables have restored, restore keys and then indexes?   Thanks for any
> help.
>
> ~DjK
>
> psql dbname < dump_file
> pg_restore -d test_restore_2 -Fc niehs_dump.backup

Some things you can do are to turn off fsync for the restore and not
restore foreign key contsraints and indexes until after the database
has been loaded.

This topic has been discussed before and you might find some more specific
information in the archives.

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

Предыдущее
От: "Gregory S. Williamson"
Дата:
Сообщение: Re: restoring an old database to a new instance -- possible ?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pg_restore