[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Recovering the original boot sector



Hi,

	When I purchased my PC, it came with Win95 preloaded. After
installing linux on it, lilo did back up the original bootsector and
stored it in /boot, but over the past two years, and after a couple of
Linux reinstalls, I lost the original bootsector (blush). Now, I am
planning to reorganize my Win95 partition again, and I need to recover the
original bootsector.

	The CompUSA support people that I talked to said that there is no
way I could recover just the bootsector - they could recover to the
original configuration shipped. But this is useless to me.

	They did say that 'fdisk /MBR' would recreate the original
bootsector. So here is what I propose to do :

1.  Take backups of th existing bootsector. Create Linux bootdisk.
2.  Run 'fdisk /MBR' from within Win95. This should wipe out my existing
partition table in the MBR (first 512 bytes).
3.  Reboot using my Linux boot disk. Now create a copy of the old (backed
up) bootsector (file A).
4.  do 'dd if=/dev/hda of=/boot/B bs=446 count=1'
5.  do 'dd if=/boot/B of=/boot/A bs=446 count=1'

	This should give me the original bootsector with the current
partition tables. Am I right? Or am I shooting myself in the foot? Better
ideas are welcome.

Jor-el


Reply to: