[prev in list] [next in list] [prev in thread] [next in thread]
List: subversion-users
Subject: Re: Keeping a hot/live FSFS repo for failover
From: "Kyle Kline" <kyle.kline () gmail ! com>
Date: 2006-10-30 21:20:10
Message-ID: c0bd0d890610301320i92161dex63e1662aedf8e348 () mail ! gmail ! com
[Download RAW message or body]
Thank you. It wound up being a permission issue. Post-commits are working
100%.
I am using this for web content authoring in an HA scenario for authoring --
the final solution is as follos:
Hardware load balancer pointing traffic of http://dav/ to SVN/Apache on
BoxA.
Web site served by both BoxA and BoxB, load balanced for HA.
On each commit, a post-commit on BoxA:
- asynchronously fires an svnsync sync http://dav-backup/ to Box B
(no commits are allowed to dav-backup url save the svnsync stuff)
- asynchronously fires an "svn update" to a working copy on Box A that
serves a web site
Post-commit hook on Box B (triggered by svnsync commits from Box A):
- same async "svn update" to working copies of on Box B (in practice,
working copy on Box B is updated less than 0.25 seconds after commit
to repo on BoxA)
- synchoronously does a dump file append to a back up dump file (hit
of appending is not taken by primary commits/user)
In a failure scenario, repoints traffic of http://dav/ to BoxB. One manual
step to change the revprops file on rev 0 on Box B, but other than that,
pretty seamless.
In restoration, run an svnadmin hotcopy to restore repo to Box A, repoint
http://dav/ to Box A, restore revprops:0, and everyone is on their happy way
again.
On 10/30/06, Garrett Rooney <rooneg@electricjellyfish.net> wrote:
>
> On 10/30/06, Kyle Kline <kyle.kline@gmail.com> wrote:
> > Thanks all for the responses. SVNSync works well for this purpose.
> >
> > A quick Q though -- I notice that when locally run on the mirror side
> > (backup repo server), the svnsync also seems to run the post-commit
> script
> > hook (desired behavior for me, I append to a dump file) -- ie
> > svnsync sync file:///c:/svn/myrepo
> >
> > However, if I trigger the sync from the primary (like in a post-commit),
> the
> > post-commit script does not seem to be run on the remote mirror box --
> ie
> > svnsync sync http://svnbackup.domain.com/myrepo
> >
> > Any thoughts? Or is that for a separate thread?
>
> It should always be running post-commits on the destination
> repository, svnsync uses exactly the same mechanism to do the commit
> as svn does, there should be no difference.
>
> -garrett
>
[Attachment #3 (text/html)]
Thank you. It wound up being a permission issue. Post-commits are working \
100%.<br><br>I am using this for web content authoring in an HA scenario for \
authoring -- the final solution is as follos:<br><br>Hardware load balancer pointing \
traffic of <a href="http://dav/">http://dav/</a> to SVN/Apache on BoxA.<br><br>Web \
site served by both BoxA and BoxB, load balanced for HA.<br><br>On each commit, a \
post-commit on BoxA:<br><ul><li>asynchronously fires an svnsync sync <a \
href="http://dav-backup/">http://dav-backup/</a> to Box B (no commits are \
allowed to dav-backup url save the svnsync stuff)<br></li><li>asynchronously fires an \
"svn update" to a working copy on Box A that serves a web site \
</li></ul>Post-commit hook on Box B (triggered by svnsync commits from Box \
A):<br><ul><li>same async "svn update" to working copies of on Box B (in \
practice, working copy on Box B is updated less than 0.25 seconds after commit to \
repo on BoxA) </li><li>synchoronously does a dump file append to a back up dump file \
(hit of appending is not taken by primary commits/user)</li></ul>In a failure \
scenario, repoints traffic of <a href="http://dav/">http://dav/</a> to BoxB. \
One manual step to change the revprops file on rev 0 on Box B, but other than that, \
pretty seamless. <br><br>In restoration, run an svnadmin hotcopy to restore repo to \
Box A, repoint <a href="http://dav/">http://dav/</a> to Box A, restore revprops:0, \
and everyone is on their happy way again.<br><br><div><span class="gmail_quote"> On \
10/30/06, <b class="gmail_sendername">Garrett Rooney</b> <<a \
href="mailto:rooneg@electricjellyfish.net">rooneg@electricjellyfish.net</a>> \
wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, \
204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"> On 10/30/06, Kyle Kline \
<<a href="mailto:kyle.kline@gmail.com">kyle.kline@gmail.com</a>> wrote:<br>> \
Thanks all for the responses. SVNSync works well for this \
purpose.<br>><br>> A quick Q though -- I notice that when locally run on the \
mirror side <br>> (backup repo server), the svnsync also seems to run the \
post-commit script<br>> hook (desired behavior for me, I append to a dump file) -- \
ie<br>> svnsync sync <a href="file:///c:/svn/myrepo">file:///c:/svn/myrepo \
</a><br>><br>> However, if I trigger the sync from the primary (like in a \
post-commit), the<br>> post-commit script does not seem to be run on the remote \
mirror box -- ie<br>> svnsync sync <a \
href="http://svnbackup.domain.com/myrepo"> \
http://svnbackup.domain.com/myrepo</a><br>><br>> Any thoughts? Or is \
that for a separate thread?<br><br>It should always be running post-commits on the \
destination<br>repository, svnsync uses exactly the same mechanism to do the commit \
<br>as svn does, there should be no \
difference.<br><br>-garrett<br></blockquote></div><br>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic