restoring database

Поиск
Список
Период
Сортировка
Искать

restoring database

От:
Lucas Lain <lainl@aconectarse.com>
Дата:
Hi everybody ... i need to restore only one database from a pg_dumpall backup 
file... how can i do it?

Thanks a lot !

Re: restoring database

От:
Theodore Petrosky <tedpet5@yahoo.com>
Дата:
As I am not someone with a lot of experience....
(depending on the size of the 'dumpall') I would
create a new database to suck up the 'all' then
pg_dump the table I really cared about. 

Obviously, if the dump_all is a terabyte database this
method is inconvenient.... (to say the least).

However it will work.

Ted

--- Lucas Lain  wrote:
> Hi everybody ... i need to restore only one database
> from a pg_dumpall backup 
> file... how can i do it?
> 
> Thanks a lot !
> 
> ---------------------------(end of
> broadcast)---------------------------
> TIP 8: explain analyze is your friend

__________________________________
Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing.
http://photos.yahoo.com/

Re: restoring database

От:
"scott.marlowe" <scott.marlowe@ihs.com>
Дата:
On Mon, 22 Dec 2003, Theodore Petrosky wrote:

> As I am not someone with a lot of experience....
> (depending on the size of the 'dumpall') I would
> create a new database to suck up the 'all' then
> pg_dump the table I really cared about. 
> 
> Obviously, if the dump_all is a terabyte database this
> method is inconvenient.... (to say the least).
> 
> However it will work.

In the past I've used 

'cat -n filename'|grep -4 database

to find the starting points of individual databases etc... and then used 
split to break it into the exact right size pieces to do this.


Re: restoring database

От:
Markus Bertheau <twanger@bluetwanger.de>
Дата:
В Пнд, 22.12.2003, в 18:53, scott.marlowe пишет:
> On Mon, 22 Dec 2003, Theodore Petrosky wrote:
> 
> > As I am not someone with a lot of experience....
> > (depending on the size of the 'dumpall') I would
> > create a new database to suck up the 'all' then
> > pg_dump the table I really cared about. 
> > 
> > Obviously, if the dump_all is a terabyte database this
> > method is inconvenient.... (to say the least).
> > 
> > However it will work.
> 
> In the past I've used 
> 
> 'cat -n filename'|grep -4 database
> 
> to find the starting points of individual databases etc... and then used 
> split to break it into the exact right size pieces to do this.

That sounds like something pg_dump / pg_dumpall should be able to do
itself, don't you think?

-- 
Markus Bertheau 

FAQ