# broken filesystem or bootdisk

## AnonNomis

I've been dual booting win Me and gentoo on my laptop and i decided to upgrade to windows XP.  The first thing i did was make a boot disk using dd if=/dev/hda2 of=/dev/fd0, I tried out my boot disk and it worked fine so i moved on to installing xp.  XP overwrote my mbr as expected but when i put in my boot disk i got

UDF-fs:  No VRS found

kernel panic: VFS: Unable to mount root fs on 03:06

Does anyone know what happened? 

I've tried to mount the root partition in toms rootboot but its keeps saying bad superblock or wrong filesystem.  I've done similiar installs on my other computer and as far as i know XP installions don't touch any other partitions.  I've never used grub before, could it be it doesn't like being written over?

----------

## daos

I see problem in your script that back up MBR, it should be:

dd if=/dev/hda of=/mnt/floppy/mbrfile bs=512 count=1

(assume floppy is mounted on /mnt/floppy).

Anyway, it's too  late.

You can use GRUB from the GENTOO stage1 ISO boot image (or stage3 ISO image) to try this after booting from this CROM:

grub

>root (hd0,4)

>setup (hd0)

>quit

/* note: all you need is to create a menu.lst file (using nano editor) in /boot/grub after booting up the GENTOO iso image. Please read how to create this file from gnu website */

----------

## AnonNomis

doesn't it still work if you leave ths bs and count out?  I actually tried the disk before putting XP in and it worked.  Well thanks for the help getting grub installed again.  But I still get a kernel panic I think something in the XP install currupted my root filesystem.  I guess i'll have to reinstall.

----------

## Guest

1/ The master boot record is on /dev/hda (not on /dev/hda2). It has only 512 bytes so the command should be exact.

2/ Now I recalled I had the same problem as you have now when installing Windows Me on the c:\ drive. The real problem is: when you  format the c: drive (using windows format tool), it corrupts the extension partition.

Windows format expect the partition tool (fdisk) to clear the first 512 bytes on the primary partition (/dev/hda1).

To avoid this problem, if you partition using Linux fdisk (or cfdisk), you MUST do this step before installing windows:

   dd if=/dev/zero of=/dev/hda1 bs=512 count=1 

(/dev/hda1 is c:\drive under windows).

Take a look at the MAN page for fdisk (man fdisk). It shows you this information.

----------

## AnonNomis

Whoo freaking hooo I found it, I was about to redo the whole thing when i noticed that when i installed xp it shifted all my partitions down a number even though nothing was changed.  Before my root was on hda6 and hda4 was unused.  When i installed XP it shifted everything down.  I didn't notice it in fdisk when using tomsrootboot but when i actually went to redo my partitions i noticed it.  I just changed the menu.lst to read hda5 and now everything works again.    :Very Happy: 

----------

