Re: pg_dump question

From: Aaron Spiteri <aaron(at)m1group(dot)com(dot)au>
To: <pgsql-admin(at)postgresql(dot)org>
Subject: Re: pg_dump question
Date: 2002-10-29 01:38:28
Message-ID: 02102912382808.12232@scooby.m1group.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

One way is to do this is by configuring the remote server to trust the host
that is going to be doing the back up. This can be done in the pg_hba.conf
file which is located in "/var/lib/pgsql/data" on my server.

If the Server that is going to be doing the back up has the IP address of say
192.168.0.2 and then on the database server you can add the following lines

host all 192.168.0.2 255.255.255.255 trust
host all 0.0.0.0 255.255.255.255 password

This will allow the server 192.168.0.2 to access any database it likes
remotly without needing a password. Usename must be valid however.

This can also specify what database the host can access by changing the
key word "all" to the database name.
host template1 192.168.0.2 255.255.255.255 trust

There are possibly much more secure wats to do this and if you here of any
let me know.

Aaron

On Tue, 29 Oct 2002 12:26, you wrote:
> Hi Folks,
>
> Fairly basic question here, I think. I've looked through the archives, but
> can't seem to find anything.
>
> I need to set up a daily cron job that performs a pg_dump on a remote
> database. I can't figure out how to pass a password to it. How do I do
> this. Everything I've tried still comes up with asking me for a password
> when I test it.
>
> Thanks, Tom
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Bruce Momjian 2002-10-29 03:24:58 Re: views across databases
Previous Message Tom Haddon 2002-10-29 01:26:49 pg_dump question