9fans archive / 2007 / 12 / 460 prev next
From: Pietro Gagliardi <pietro10@mac.com>
Subject: Corrupted file entry on QEMU - how to recover?
Date: Mon, 31 Dec 2007 20:37:37 -0500
I decided to take a peek at the corrupted entry. All of the fields of
the Entry are zeros! This causes the sourceAlloc() function to fail,
and thus I can't get a source without the program crashing (I tried
once). Is there a way to fix this?
On Dec 27, 2007, at 11:23 AM, Russ Cox wrote:
>> Can someone PLEASE give me some information so I can get my files
>> back? Otherwise, there goes my 3D library, my hoc implementation,
>> etc.
>
> I'm afraid you're probably out of luck, without a lot of work.
>
> The disk data structures are all described in /sys/doc/fossil.ps.
>
> If you were using snapshots, then you might be able to
> use the information in /sys/doc/fossil.ps to write a program
> to find all the fossil snapshot roots, and then you
> could rewrite the super block to point at an older,
> hopefully not corrupt, root.
>
> However, it looks like in plain fossil mode (not fossil+venti),
> the installer does not configure any snapshots, so you'd
> have had to turn them on yourself.
>
> Without snapshots, you'd have to poke around on the
> disk looking for a VtSource that looked like the root
> directory and then fix up the root block to be valid and
> point at it.
>
> If you're not used to poking at file system data structures,
> this might well be more work than just recreating your
> hoc and 3D code.
>
> Russ
>