Lists: | pgsql-performance |
---|
From: | Roberto Grandi <roberto(dot)grandi(at)trovaprezzi(dot)it> |
---|---|
To: | pgsql-performance(at)postgresql(dot)org |
Subject: | RESTORE multiple DBs concurrently |
Date: | 2013-09-06 15:52:07 |
Message-ID: | 188484362.829358.1378482727925.JavaMail.root@trovaprezzi.it |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-performance |
Dear All,
I'm dealing with restore 3 DB at the same time. Previously this task was sequential but we need to make shorter as possible our daily maintenance window.
Is this possible from your point of view to restore on the same server more than 1 DB at time? I havwn't found any clear answer on the web.
Many thanks in advance.
BR
Roberto
From: | Michael Paquier <michael(dot)paquier(at)gmail(dot)com> |
---|---|
To: | Roberto Grandi <roberto(dot)grandi(at)trovaprezzi(dot)it> |
Cc: | PostgreSQL mailing lists <pgsql-performance(at)postgresql(dot)org> |
Subject: | Re: RESTORE multiple DBs concurrently |
Date: | 2013-09-07 09:46:53 |
Message-ID: | CAB7nPqQS6-JvsrDNh5Txk7h1qj6Z-+3VrGS+DEgH10C+aQuTWQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-performance |
On Sat, Sep 7, 2013 at 12:52 AM, Roberto Grandi
<roberto(dot)grandi(at)trovaprezzi(dot)it> wrote:
> Is this possible from your point of view to restore on the same server more than 1 DB at time?
Yes, it is possible: simply run multiple instances of pg_restore in
parallel and just don't blow up your disk(s) I/O.
Also, why not restoring one database at the same time and accelerating
a single restore with parallel jobs? If your dump format is compatible
with this option, use -j when running pg_restore to define a number of
concurrent jobs. More info here:
http://www.postgresql.org/docs/9.2/interactive/app-pgrestore.html
This might be useful as well in your case.
--
Michael