Re: updating remote database - Mailing list pgsql-sql

From Richard Huxton
Subject Re: updating remote database
Date
Msg-id 200402260815.16538.dev@archonet.com
Whole thread Raw
In response to updating remote database  (Kenneth Gonsalves <lawgon@thenilgiris.com>)
Responses Re: updating remote database  (Achilleus Mantzios <achill@matrix.gatewaynet.com>)
List pgsql-sql
On Thursday 26 February 2004 02:54, Kenneth Gonsalves wrote:
> i have a database on a local machine, and another on a remote machine. I
> have a dialup connection between the two - so band width is a problem. What
> is the most efficient way of updating the remote from the local? Does SQL
> or postgres have simple commands for this?

Sounds like you want some form of (batched) asynchronous replication (as it's 
called). If you've not already set that up though, that won't help here.

Assuming you don't have a complete list of all changes logged somewhere, you 
might want to try:

1. pg_dump the tables you want to synchronise on the local machine (one per 
file)
2. Do the same on the remote machine
3. Use rsync to update the remote dump based on the local one
4. Restore the updated dump on the remote machine.

Failing that, you might want to look into the replication options available - 
you may be able to adapt contrib/dbmirror, or perhaps erserver/rservimp on 
gborg.postgresql.org

--  Richard Huxton Archonet Ltd


pgsql-sql by date:

Previous
From: Richard Huxton
Date:
Subject: Re: Scalar in a range (but textual not numeric)
Next
From: Olivier Hubaut
Date:
Subject: Re: updating remote database