Re: Database backup to network folder

From: Craig Ringer <craig(at)postnewspapers(dot)com(dot)au>
To: kalyan kumar <kalyansai99(at)yahoo(dot)co(dot)in>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Database backup to network folder
Date: 2011-08-01 23:36:13
Message-ID: 4E37386D.50205@postnewspapers.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 1/08/2011 1:35 PM, kalyan kumar wrote:
> Hi,
>
> I am using Postgre SQL 8.3, where I want to backup my entire database.
> For the same I am using pg_dump.exe. I am able to take the backup of my
> database in to my local machine. If I want to take the backup into
> network folder, how to pass "-f" parameter to pg_dump.exe. I am using
> SMB to implement file copy to network folder.

Have you tried using a UNC path, like you would for anything else?
pg_dump shouldn't have to care where the output is being saved.

pg_dump -f \\servername\sharename\foldernames\dumpfile.sql dbname

I haven't tested this, but there's no reason it shouldn't work, as UNC
paths are resolved at the file system level and apps shouldn't notice them.

--
Craig Ringer

POST Newspapers
276 Onslow Rd, Shenton Park
Ph: 08 9381 3088 Fax: 08 9388 2258
ABN: 50 008 917 717
http://www.postnewspapers.com.au/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Craig Ringer 2011-08-01 23:42:29 Re: Postgres 8.0 upgrade to 9.0
Previous Message Craig Ringer 2011-08-01 23:33:41 Re: possible ecpg compatibility problem