> On Fri, 13 Jun 2003, Richard Heycock wrote: > >> Hi, >> >> I'm new to this list and I need some help! I just ran grub-install on >> my root partition instead of my boot partition and it appears to have >> wreaked it. > > Ouch. > >> If I run file -s /dev/hda5 I now get 'x86 boot sector' instead of >> 'ReiserFS V3.6 block...' and I can no longer mount it. >> When the machine tries to boot it loads the kernel (from /dev/hda6) >> but when it comes to mount the root partition it kernel panics as it >> cannot mountthe filesystem. >> >> I know at least some of the data is on the partition (`less >> /dev/hda5`). I'm guessing that grub-install has overwritten N number >> of bytes at the beginning of the partition but beyond that I'm at a >> complete loss at what to do. > > Your probably not in too bad shape. The boot sector is just a single
Arr nice to hear some positive thoughts :-) I've only been met with stoney silence on other lists (debian-users and reiserfs), though I'm told there are these things called time zones... > sector, and the rest of the drive should be untouched. The trick is > recovering that first sector. When you say sector do you mean the sector as in the disc drive or something else? > > Your basic tool for moving stuff around is dd which you can use to copy > just the first sector from one file (ie probably a device file) to > another. > > I don't know the details of ReiserFS. There's a good chance though > that the first sector contains only really generic stuff, and/or there > are backups stored elsewhere on the device. You might even find it's > as easy as copying the first sector (only) from a healthy ReiserFS file > system to your damaged one. There's nothing on that sector you're > trying to save, so just give it a whirl, but DONT MOUNT THE FILE SYSTEM > IN OTHER THAN READ ONLY MODE until you're pretty sure its OK, and then > consider copying the most important files out of the file system when > it becomes accessible. The first thing I did was to dd the entire partition on to another partition so I've got some scope for experiment. I've dd'ed the first 512 bytes from a healthy reiserfs partition but without success. I also tried to 'strace grub-install' to see how much data was being copied to the disc but I got an error message (something about the bios) but I am trying to do this from within Knoppix so things are unlikely to be the same. > > If it's not so happily simple and the first sector contains the root of > your file system, device parameters or something similar, then the > place to get help is probably a developers list for the ReiserFS file > system. I posted a message to this list but I haven't heard anything back yet, I'll wait and see what happens this evening. I'm in a bit of a panic at the moment so I'm trying everything I can think of! rgh > > Andrew > > > > -- > > No added Sugar. Not tested on animals. If irritation occurs, > discontinue use. > > ------------------------------------------------------------------- > Andrew McNaughton In Sydney > Working on a Product Recommender System > [EMAIL PROTECTED] > Mobile: +61 422 753 792 http://staff.scoop.co.nz/andrew/cv.doc -- SLUG - Sydney Linux User's Group - http://slug.org.au/ More Info: http://lists.slug.org.au/listinfo/slug