From: | Murthy Kambhampaty <murthy(dot)kambhampaty(at)goeci(dot)com> |
---|---|
To: | 'Michael A Nachbaur' <mike(at)nachbaur(dot)com>, pgsql-admin(at)postgresql(dot)org |
Subject: | Re: Syncing DBs prior to RServ replication |
Date: | 2003-06-11 14:51:05 |
Message-ID: | 2D92FEBFD3BE1346A6C397223A8DD3FC092310@THOR.goeci.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
I think you'd benefit from a two-stage Rsync (this was discussed on this
list in the past few months):
1. Rsync the $PGDATA cluster from the "hot" server to the "standby" server,
with the postmaster running
2. Stop the postmaster and perform the same rsync again (this will take only
a few seconds on how much time elapses between the completion of the first
stage and postmaster shutdown; 5G of data should take less than 5 minutes to
Rsync over if you're running Fast Ethernet or better).
Start the postmaster on both servers, and do your Rserv thing. (I don't use
Rserv, so I haven't tested this, but it sounds like you don't need the
servers to have identical states, so ...)
Cheers,
Murthy
>-----Original Message-----
>From: Michael A Nachbaur [mailto:mike(at)nachbaur(dot)com]
>Sent: Monday, June 09, 2003 18:25
>To: pgsql-admin(at)postgresql(dot)org
>Subject: [ADMIN] Syncing DBs prior to RServ replication
>
>
>I'm looking at syncronizing two database servers with RServ
>(production / "hot
>standby"), and I'm trying to figure out a way to get the
>initial database on
>the slave server syncronized with the master.
>
>Normally, I would 1) turn off all clients, 2) dump the
>database from the
>master, 3) restore it into the slave, 4) turn clients back on, and 5)
>replicate regularly.
>
>Unfortunately I'm running the master in a production environment where
>anything more than 5 minutes of downtime is a really "Bad
>Thing®". The
>database dump is about 5G, and so leaving the master down for
>that entire
>time isn't possible. Is there a recommended way for
>performing such a "sync"
>without any lengthy downtime?
>
>I'm guessing I could start my dump, and then immediately
>afterward create the
>replication tables in the master. Since the dump is
>transactional (is it?),
>it shouldn't include the replication tables or the replication
>"snapshot"
>information in it's dump, and by the time I finally finish
>importing the dump
>in the new server, I should be able to perform the replication
>and pick up
>all the new / changed records since I started the DB dump.
>
>Will this work? Is there a better recommended way? Thanks.
>
>--
>Michael A Nachbaur <mike(at)nachbaur(dot)com>
>
>
>---------------------------(end of
>broadcast)---------------------------
>TIP 3: if posting/reading through Usenet, please send an appropriate
>subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
>message can get through to the mailing list cleanly
>
From | Date | Subject | |
---|---|---|---|
Next Message | Joe Conway | 2003-06-11 15:29:28 | Re: link servers |
Previous Message | Sidar Lopez Cruz | 2003-06-11 14:28:40 | migrating databases |