Den tors 9 jan. 2025 kl 13:09 skrev Bo Berglund <bo.bergl...@gmail.com>:
...

>
> 4) From then on it took a while but it finally reached rev 4521 and exited
> successfully.
>
> Now my two repositories seem to be exactly the same, which is the whole
> purpose.
>

Good, this is exactly what I was expecting - after an intermittent
communication failure the sync would continue.


> WHAT TO DO NOW?
> ----------------
> I realized by seeng this that my problems with the pc repo might be
> because some
> time ago back in 2023 there was something that made it stop like my first
> stop
> during sync and NOT FINISH, just hang there.
>
> That explains the error message I have reported earlier in this thread
> about the
> lock on the repo that stopped future sync operations to complete.
>
> So is there some way to force svnsync to EXIT with an error when there is
> a stop
> in communications or similar? Maybe a timeout value...
> If not then I believe that svnsync cannot be used in an automated fashion
> to
> keep a mirror updated.
>
> Note that whatever can be done must be done on the Windows Server 2016 that
> hosts the main repositories. So methods used on Linux do not apply here.
>
> In order to handle an svnsync hang I need a way to STOP svnsync rather
> than it
> does a halt. It needs to clear the lock when it exits...
>
> Or a way to have a timeout that exits the svnsync application such that a
> log
> can be created and possibly also a forced restart.
>
> But the restart is not important because the sync will run the followiing
> day
> anyway and then the comm problem (if that is the cause) likely is not
> present
> anymore.
>
> Any ideas?
>

I would say there are too many unknown variables to reliably solve this
without resorting to external solutions.

You say that the svnsync process on the Windows side (which, if I
understand your architecture correctly, is the main server) should remove
the lock if the sync hang. But if the sync hang because of a communication
failure - how do you suggest that the sync should contact the remote server
to tell it "I'm done, please remove the lock"? The sync is, from the remote
server's point of view, only a regular commit with a specific user.

The only solution that will make sure you actually have a working sync is
to monitor that the sync script completes without errors. Maybe you could
have a script that looks for the svn:sync-lock property (something like svn
proplist -v --revprop -r0 http://remote.server.tld/svn/repo) at a time when
the sync SHOULD have completed?

Kind regards,
Daniel

Reply via email to