Master boot record backup and recovery

Master boot record backup and recovery

Post by Colin G » Thu, 15 Mar 2001 15:11:37



Here's a hypothetical situation that some may find themselves in, and that
I'm curious about.

I have a pure linux setup on my system. I have some free, unpartitioned,
space on the hard drive and want to install Windows for whatever reason (I
can't think of one at the moment). I know from past experience that any
Windows install will wipe out the current master boot record (MBR).
Obviously I'll want to be able dual-boot into both Windows and linux. Let us
say that I use dd to create a backup image of my current (lilo) MBR, like
so:

    dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

This will create a 512 byte MBR image on my floppy disk. I go ahead and
install Windows, thereby losing my lilo MBR. After getting Windows setup and
working, I use rawrite to write the MBR image on my floppy back to the hard
disk.

My question is this: Will this work?

Thanks in advance,
Colin G.

 
 
 

Master boot record backup and recovery

Post by Tom Fjellstro » Thu, 15 Mar 2001 15:26:57



> Here's a hypothetical situation that some may find themselves in, and that
> I'm curious about.

> I have a pure linux setup on my system. I have some free, unpartitioned,
> space on the hard drive and want to install Windows for whatever reason (I
> can't think of one at the moment). I know from past experience that any
> Windows install will wipe out the current master boot record (MBR).
> Obviously I'll want to be able dual-boot into both Windows and linux. Let us
> say that I use dd to create a backup image of my current (lilo) MBR, like
> so:

>     dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

> This will create a 512 byte MBR image on my floppy disk. I go ahead and
> install Windows, thereby losing my lilo MBR. After getting Windows setup and
> working, I use rawrite to write the MBR image on my floppy back to the hard
> disk.

> My question is this: Will this work?

I have a question for you:
Is the unpartitioned space at the beginning of the drive?
I don't think windows likes being the second os.
But I think there might be ways to fool windows...

--
"Computer programmers don't byte, they nybble a bit."
Tom Fjellstrom

http://strangesoft.net/

 
 
 

Master boot record backup and recovery

Post by Colin G » Thu, 15 Mar 2001 15:53:28


I've had Windows and linux successfully cooperating on the same drive when
Windows was on a partition at the end or the beginning of the drive. I don't
think it should make a difference. On those instances, though. I had
installed Windows first, then linux.

Colin G.



> Here's a hypothetical situation that some may find themselves in, and that
> I'm curious about.

> I have a pure linux setup on my system. I have some free, unpartitioned,
> space on the hard drive and want to install Windows for whatever reason (I
> can't think of one at the moment). I know from past experience that any
> Windows install will wipe out the current master boot record (MBR).
> Obviously I'll want to be able dual-boot into both Windows and linux. Let
us
> say that I use dd to create a backup image of my current (lilo) MBR, like
> so:

>     dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

> This will create a 512 byte MBR image on my floppy disk. I go ahead and
> install Windows, thereby losing my lilo MBR. After getting Windows setup
and
> working, I use rawrite to write the MBR image on my floppy back to the
hard
> disk.

> My question is this: Will this work?

I have a question for you:
Is the unpartitioned space at the beginning of the drive?
I don't think windows likes being the second os.
But I think there might be ways to fool windows...

--
"Computer programmers don't byte, they nybble a bit."
Tom Fjellstrom

http://strangesoft.net/

 
 
 

Master boot record backup and recovery

Post by dktrjky » Thu, 15 Mar 2001 16:09:25


Why not just go ahead and install windows, use your boot disk to
re-install LILO in the MBR after your 'winstall'?  Done it several
times.  Just reinstall LILO on top of windoze's MBR.  Assuming win is on
the 'back end' of the HD...

dktr


> Here's a hypothetical situation that some may find themselves in, and that
> I'm curious about.

> I have a pure linux setup on my system. I have some free, unpartitioned,
> space on the hard drive and want to install Windows for whatever reason (I
> can't think of one at the moment). I know from past experience that any
> Windows install will wipe out the current master boot record (MBR).
> Obviously I'll want to be able dual-boot into both Windows and linux. Let us
> say that I use dd to create a backup image of my current (lilo) MBR, like
> so:

>     dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

> This will create a 512 byte MBR image on my floppy disk. I go ahead and
> install Windows, thereby losing my lilo MBR. After getting Windows setup and
> working, I use rawrite to write the MBR image on my floppy back to the hard
> disk.

> My question is this: Will this work?

> Thanks in advance,
> Colin G.

 
 
 

Master boot record backup and recovery

Post by dktrjky » Thu, 15 Mar 2001 16:16:28


 Let us

Quote:> > say that I use dd to create a backup image of my current (lilo) MBR, like
> > so:

> >     dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

> > This will create a 512 byte MBR image on my floppy disk. I go ahead and
> > install Windows, thereby losing my lilo MBR. After getting Windows setup and
> > working, I use rawrite to write the MBR image on my floppy back to the hard
> > disk.

> > My question is this: Will this work?

> > Thanks in advance,
> > Colin G.

Because you're going to put a 'Linux only' LILO config into a
linux-windoze setup.  That copy of LILO only knows the single OS
exists.  You will have to reinstall LILO either way.  Windows will
re-write your LILO if you put it back on this way and then you will not
be able to boot into linux using it!

dktr

 
 
 

Master boot record backup and recovery

Post by Colin G » Thu, 15 Mar 2001 16:43:39


I'm aware of this. I was just curious if my proposal would work.

Colin G.


Let us

Quote:> > say that I use dd to create a backup image of my current (lilo) MBR,
like
> > so:

> >     dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

> > This will create a 512 byte MBR image on my floppy disk. I go ahead and
> > install Windows, thereby losing my lilo MBR. After getting Windows setup
and
> > working, I use rawrite to write the MBR image on my floppy back to the
hard
> > disk.

> > My question is this: Will this work?

> > Thanks in advance,
> > Colin G.

Because you're going to put a 'Linux only' LILO config into a
linux-windoze setup.  That copy of LILO only knows the single OS
exists.  You will have to reinstall LILO either way.  Windows will
re-write your LILO if you put it back on this way and then you will not
be able to boot into linux using it!

dktr

 
 
 

Master boot record backup and recovery

Post by Dave Addiso » Thu, 15 Mar 2001 19:03:37


I don't think rawrite would. AFAIK it expects the target to be a floppy. If
you save the kernel onto a floppy you could use loadlin to reboot linux and
then run LILO to rewrite the MBR


Quote:> I'm aware of this. I was just curious if my proposal would work.

> Colin G.

 
 
 

Master boot record backup and recovery

Post by Tomas Nykun » Thu, 15 Mar 2001 20:28:28


Quote:"Tom Fjellstrom" wrote...

<snip>

Quote:> I have a question for you:
> Is the unpartitioned space at the beginning of the drive?
> I don't think windows likes being the second os.
> But I think there might be ways to fool windows...

Windows don't know anything about other OS:es filesystems
so it will not see the Linux partitions at all, and therefore
it doesn't matter if Windows is not on the first partition on
a HD. But Windows *must* be on a primary partition on the*
HD, so it is not possible to install it on a logical partition
in the very end of a HD. AFAIK there is no way to bypass this
Windows/DOS limitation.

Tomas

 
 
 

Master boot record backup and recovery

Post by Gregg Morri » Thu, 15 Mar 2001 21:24:39



> Because you're going to put a 'Linux only' LILO config into a
> linux-windoze setup.  That copy of LILO only knows the single OS
> exists.  You will have to reinstall LILO either way.  Windows will
> re-write your LILO if you put it back on this way and then you will not
> be able to boot into linux using it!

Why not edit lilo.conf on the floppy before reinstalling lilo or
/etc/lilo.conf after reinstalling it and then run lilo again?

Regards,
Gregg

 
 
 

Master boot record backup and recovery

Post by Edward Coate » Sun, 18 Mar 2001 04:35:28


Me personally, I would create an image of the kernel using dd, then use
that to boot back in after the reinstall, then run lilo again after
you've logged in as root.  Using redhat, you can

dd if=/boot/<kernel name> of=/dev/fd0 bs-1024 ; sync

and that should work.  As for other distros, I couldn't tell you where
they keep the kernel hidden.  :)

Ed


> Here's a hypothetical situation that some may find themselves in, and that
> I'm curious about.

> I have a pure linux setup on my system. I have some free, unpartitioned,
> space on the hard drive and want to install Windows for whatever reason (I
> can't think of one at the moment). I know from past experience that any
> Windows install will wipe out the current master boot record (MBR).
> Obviously I'll want to be able dual-boot into both Windows and linux. Let us
> say that I use dd to create a backup image of my current (lilo) MBR, like
> so:

>     dd if=/dev/hda of=/mnt/floppy/backup.mbr bs=512 count=1

> This will create a 512 byte MBR image on my floppy disk. I go ahead and
> install Windows, thereby losing my lilo MBR. After getting Windows setup and
> working, I use rawrite to write the MBR image on my floppy back to the hard
> disk.

> My question is this: Will this work?

> Thanks in advance,
> Colin G.

  edward.coates.vcf
< 1K Download
 
 
 

Master boot record backup and recovery

Post by Tom Fjellstro » Sat, 17 Mar 2001 18:36:17



> "Tom Fjellstrom" wrote...
> <snip>
> > I have a question for you:
> > Is the unpartitioned space at the beginning of the drive?
> > I don't think windows likes being the second os.
> > But I think there might be ways to fool windows...

> Windows don't know anything about other OS:es filesystems
> so it will not see the Linux partitions at all, and therefore
> it doesn't matter if Windows is not on the first partition on
> a HD. But Windows *must* be on a primary partition on the*
> HD, so it is not possible to install it on a logical partition
> in the very end of a HD. AFAIK there is no way to bypass this
> Windows/DOS limitation.

ah... I wasnt sure what the limitation was..
But I was sure you had to install windows first.

--
"Computer programmers don't byte, they nybble a bit."
Tom Fjellstrom

http://www.veryComputer.com/

 
 
 

Master boot record backup and recovery

Post by Brad » Sun, 29 Jul 2001 17:03:51


although i have windows installed on the 1st partition(because i am a
newbie), this may help.  i have both the 1st and 2nd partition set as
primary.  i think i used cfdisk to do that and i have had no problems
with it.  look into it and see if you can get it to work.  it has given
me no trouble at all.

> "Tom Fjellstrom" wrote...
> <snip>
> > I have a question for you:
> > Is the unpartitioned space at the beginning of the drive?
> > I don't think windows likes being the second os.
> > But I think there might be ways to fool windows...

> Windows don't know anything about other OS:es filesystems
> so it will not see the Linux partitions at all, and therefore
> it doesn't matter if Windows is not on the first partition on
> a HD. But Windows *must* be on a primary partition on the*
> HD, so it is not possible to install it on a logical partition
> in the very end of a HD. AFAIK there is no way to bypass this
> Windows/DOS limitation.

> Tomas

 
 
 

1. Master Boot Record - recovery

Hello,

I have Windows NT server and Linux installed on my
Intel workstation.

The Nt server was installed first, and when installing
the Linux, I overwrote the MBR on my disk with LILO,
which did not work.

How do I put the MBR back on my disk without reinstalling
NT and/or Linux?

And what is the best way for NT server and Linux to coexist
on my workstation? I'd like to be able to decide at boot-time
which OS to boot.

Andrea

2. Install UMSDS w/out floppy -- copy file system?

3. Master boot record with NT 4.0/RH5.0

4. NIS VS. NFS

5. Master Boot Record Error

6. lwps; how many are too many?

7. killing the master boot record

8. HELP: adding users

9. master boot record

10. Problem is Master boot record

11. Killed Master Boot Record with Dr Dos.

12. Need to restore Master Boot Record-forgot command-Help!

13. Repair Master Boot Record