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

Re: restoring MBR



On 30/07/11 21:34, Baurzhan Ismagulov wrote:
> On Sat, Jul 30, 2011 at 03:38:14PM +1000, Scott Ferguson wrote:
>>> I've installed Squeeze to a USB drive, and grub2 installed itself to the
>>> internal hard drive. 
>>
>> Curious. I've never had that problem when installing Squeeze to a USB
>> drive. Can you boot from the USB drive?
> 
> IIRC, no.

Did you want to be able to boot from the USB drive (to the Debian that
installed on the USB drive)?  If so - please make a separate post to
avoid confusion and we'll keep this post for dealing with restoring your
Windoof XP boot record.

> 
> 
>>> Now I can't boot from the internal drive since it
>>> has encryption software checking some sort of CRC of the MBR. 

Encryption and CRC are different things. No matter.

>>>Is the backup of the MBR available somewhere in the Linux rootfs?
>>
>> No.
> 
> That's a pity. IIRC, lilo used to save that under /boot.
> 
> 
>> But it "sounds" like the problem "might" be your BIOS. Have a look and
>> see if you have some sort of boot record protection in the BIOS and turn
>> it off.
> 
> If it were in place, I wouldn't have the problem -- it would have
> protected the internal drive's MBR.

I agree - I was unsure as to what you meant (you could also have been
referring to ProtectDrive or other partition encryption measures). Your
comment further down about Windoof and Sophos explains that.

> 
> 
>> Please provide some information about the OS/s installed on your
>> internal HDD/s and the messages you get when you boot.
> 
> It's Windows XP with Sophos Safe Guard Easy. I added the Windows
> partition to grub2. It seems to load the partition boot sector. After
> that it should have asked the filesystem password. But it says that MBR
> checksum is not correct and refuses to continue.

Before anything else - try booting into Windoof Safe Mode and seeing if
you can placate Sophos - skip to the end of this post for instructions.
If that fails... come back to this next step.

If Windoof is the only OS on the internal hard drive then the best
approach is to remove grub and restore the Windoof boot loader.

I understand that you'd like to boot the Debian installed on the USB
drive from the internal HDD but that is an unreliable approach. Better
to simply choose which drive (internal or external) that you wish to
boot from at startup (F8 is your mate).

> 
> 
>> Also check the boot order in your BIOS.
> 
> IIRC, it didn't boot from the USB drive, so I switched to the internal
> drive.

Unless the BIOS is old... change the BIOS to allow booting from the
external USB drive as well as the internal HDD. Set the boot order to
internal HDD first, external HDD second (CD/DVD third, if required).
F8 (or sometimes, F10) at boot will prompt you to select which BIOS
"allowed" drive you boot from.

This approach has the added advantage of making your external HDD
portable (bootable from any machine)

> 
> 
>> P.S. Don't stress - most likely this is easily fixed.
> 
> I would be happy to know a way to restore the MBR (or, in general, boot
> Windows) without having to reinstall it.
> 
> 
> With kind regards,

NOTE: I'm assuming a standard Windoof boot setup.

3 choices for restoring the Windoof MBR:-

1. with a DOS 7 floppy disk, boot from the floppy and at the command
prompt issue the (undocumented) command:-
A:/ fdisk /mbr
You can grab an image (Win98SE OEM works well) from:-
http://www.bootdisk.com/

2. from a Windoof XP install CD, boot from the CD and when prompted
choose "XP Recovery Console" then follow the directions here:-
http://www.kellys-korner-xp.com/win_xp_rec.htm

3. from SuperGrubDisk, either a CD or a USB key:-
http://www.supergrubdisk.org/
Choose SuperGrubDisk1 as 2 is still in Beta for restoring Windoof MBRs
See documentation on the site.

There are more choices if you'd like (various Live CD, fixmbr.exe, etc,
etc) ;-p

After restoring the Windoof MBR you will need to deal with Sophos...
Just after the BIOS hands over to the boot loader hit F8 until you get
the prompt to boot into Safe Mode. In Safe Mode you can deal with
Sophos. For more help with Sophos please refer to their website.

If you have any problems please note the details, and possibly some info
about your BIOS and motherboard, and post back here.

Cheers

-- 
“Children are smarter than any of us. Know how I know that? I don't know
one child with a full time job and children.”
~ Bill Hicks


Reply to: