[svk-users] What to do when a db/revs/nnn file is sitting on a bad sector

David Landgren david at landgren.net
Sun Oct 14 09:20:18 EDT 2007


Jared Hardy wrote:
> On 10/13/07, David Landgren <david at landgren.net> wrote:
>> it had to happen. I've had a sector go bad on my disk. And the sector in
>> question has been allocated to ~/.svk/local/db/revs/1577. There are two
>> subsequent revisions after that (1578 and 1579).
>> Is there a way to recreate the file by looking at 1576 and 1578 and
>> figuring out the difference?
> 
> Situations like this are why nightly backups are so important. Based

In this particular case it would have been of no help. The file was 
written... and could not be read back. I noticed the problem about 5 
hours later when I attempted to smerge some additional changes.

> on how you structured your question, I assume you don't have any local
> branches you care about losing. Also, look at your logs -- are there

Nope, single user, commits to HEAD, single mirror.

> any files that overlap between 1577 and any later revisions? Those are
> the files you should backup in your Working Copy (WC) right away, to
> prevent corruption. The easiest way may be to just save your WC
> somewhere safe, and re-create your whole setup from scratch. You just
> have to be patient enough to start a fresh sync from your mirror
> source.

That will happen soon enough, when I pick up a new laptop.

>     One hacky way around this might be to mirror a new .svk repository
> from your old one, and use "svk sync --torev 1576 ..." to stop it
> before the corrupt revision. Then you need to "--relocate" the new
> mirror to the original source, and finish the sync from there. You

I'll investigate that avenue.

Thanks for your help,
David

> could even re-create any revisions that don't exist on the original
> mirror source by re-committing any changes between rev 1576 and your
> WC. Just create a fresh WC with an update to 1576, overwrite it with
> your current WC, update to HEAD, resolve and commit.
> :) Jred
> _______________________________________________
> svk-users mailing list
> svk-users at lists.bestpractical.com
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/svk-users
> 



More information about the svk-users mailing list