Re: [Hampshire] Removing MBR

Top Page

Reply to this message
Author: Stuart Sears
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] Removing MBR
Rob Malpass wrote:
> Hi all
>
> I'm trying to resurrect an old PC and install an old distribution on it.
> Said PC isn't good enough to be considered anything but an sftp server
> (it's around 1999 vintage). Problem is - I can't get past whatever was
> in the master boot record before. All I get in fact at bootup is "LI"
> - then it hangs.
>
> I know that I can get around this by booting from a DOS disk and doing
> fdisk /mbr. However - out of interest - if I didn't have an MSDOS boot
> disk - how would I do this?
>
> I'm putting slackware 7.1 on it and in booting from that cdrom, I can't
> get fdisk /mbr to work. I can't find anything in the fdisk options
> which is anything to do with the mbr.


wipe it or fix it?

dd if=/dev/zero of=/dev/sda bs=521 count=1

Writing more than 512 bytes to the MBR is also fine, unless you have
partitions you would like to preserve. :) (trust me, you don't want to
do that).

That will wipe the MBR.

to install a new first stage bootloader, use
grub-install /dev/sda

or lilo -v if you use LILO as your bootloader

(this is all assuming you have sata disks or are using a relatively
recent libata. sub /dev/hda instead if this is not the case).

Stuart

--
Stuart Sears RHC*
"It's today!" said Piglet.
"My favourite day," said Pooh.