Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 1EBBC2E00EE for ; Sat, 26 Jan 2008 17:06:27 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 94883-03 for ; Sat, 26 Jan 2008 17:05:58 -0400 (AST) Received: from web56414.mail.re3.yahoo.com (web56414.mail.re3.yahoo.com [216.252.111.93]) by postgresql.org (Postfix) with SMTP id ACBC02E007C for ; Sat, 26 Jan 2008 17:06:19 -0400 (AST) Received: (qmail 99232 invoked by uid 60001); 26 Jan 2008 21:06:18 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=QooIcT7SUmsnVTCljk763bcZlERLsQjcBbJJqBqCR+U0s+03fe3vBtmyXK7Ed5ly6qvbuPMUd6QW9JJrVdQHb4JtPO3D4MNOgCHFtzq9BFALqVeMY7wkhsrhVhzaK9TM1yxfMoX/EjnQnDcXoSYk1LeL2YDnY9Mksp/94H6iZ1I=; X-YMail-OSG: y2VsyloVM1n6VW_gY.kyeYezafHFHwsTgyI01MEQ5oqo7OxaIkZmCaToz4aJpAtK7nzfcDtOFh2lczaFrbEuh5xqanPx4bPf36ML8thn7Rf89RtW0oA- Received: from [208.73.110.242] by web56414.mail.re3.yahoo.com via HTTP; Sat, 26 Jan 2008 13:06:18 PST Date: Sat, 26 Jan 2008 13:06:18 -0800 (PST) From: NUWAN LIYANAGE Subject: Re: backup including symbolic links? To: Scott Marlowe Cc: pgsql-admin@postgresql.org In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="0-1631176426-1201381578=:98499" Content-Transfer-Encoding: 8bit Message-ID: <447214.98499.qm@web56414.mail.re3.yahoo.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200801/259 X-Sequence-Number: 28033 --0-1631176426-1201381578=:98499 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Yes, I was thinking of doing a pg_dumpall, but my only worry was that the singl file is going to be pretty large. I guess I don't have to worry too much about that. But my question to you sir is, If I want to create the development db using this pg dump file, how do I actually edit create tablespace statements so they will be created in the directory I want them to be. Or should I even worry about this.. (I want my data directory to be in E: drive including all the tablespaces.) Thank you very much for your reply. Nuwan. Scott Marlowe wrote: On Jan 25, 2008 1:55 PM, NUWAN LIYANAGE wrote: > Hello, > > I have a 450gb production database, and was trying to create a development > database using a bkp. > I was following the instructions on postgres documentation, and came across > the paragraph that says... > " If you are using tablespaces that do not reside underneath this (data) > directory, be careful to include them as well (and be sure that your backup > dump archives symbolic links as links, otherwise the restore will mess up > your tablespaces)." > I have a seperate pg_tablespaces folder under E:\ drive since there wasn't > enough space in my C:\ drive to put them. > > My db is 8.2 and is running on windows 2003. > > Can anyone tell me how to backup my database (including the symbolic links > as links). A standard pg_dumpall --globals will dump the create tablespace statement, which you can edit as needed for your new machine. A plain pg_dump of the database will dump out the tables with tablespace statements. A pg_dumpall of the whole database cluster can also be used to do this. ---------------------------(end of broadcast)--------------------------- TIP 2: Don't 'kill -9' the postmaster --------------------------------- Never miss a thing. Make Yahoo your homepage. --0-1631176426-1201381578=:98499 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: 8bit
Yes, I was thinking of doing a pg_dumpall, but my only worry was that the singl file is going to be pretty large. I guess I don't have to worry too much about that.
But my question to you sir is, If I want to create the development db using this pg dump file, how do I actually edit create tablespace statements so they will be created in the directory I want them to be. Or should I even worry about this.. (I want my data directory to be in E: drive including all the tablespaces.)
Thank you very much for your reply.
Nuwan.

Scott Marlowe <scott.marlowe@gmail.com> wrote:
On Jan 25, 2008 1:55 PM, NUWAN LIYANAGE wrote:
> Hello,
>
> I have a 450gb production database, and was trying to create a development
> database using a bkp.
> I was following the instructions on postgres documentation, and came across
> the paragraph that says...
> " If you are using tablespaces that do not reside underneath this (data)
> directory, be careful to include them as well (and be sure that your backup
> dump archives symbolic links as links, otherwise the restore will mess up
> your tablespaces)."
> I have a seperate pg_tablespaces folder under E:\ drive since there wasn't
> enough space in my C:\ drive to put them.
>
> My db is 8.2 and is running on windows 2003.
>
> Can anyone tell me how to backup my database (including the symbolic links
> as links).

A standard pg_dumpall --globals will dump the create tablespace
statement, which you can edit as needed for your new machine. A plain
pg_dump of the database will dump out the tables with tablespace
statements. A pg_dumpall of the whole database cluster can also be
used to do this.

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster


Never miss a thing. Make Yahoo your homepage. --0-1631176426-1201381578=:98499--