How to copy the /boot partition?

From: Linux Lover (linuxlover992000_at_yahoo.com)
Date: 09/29/03


Date: 29 Sep 2003 09:38:25 -0700

My 4GB HDD is dying. I need to transfer it ASAP to another HDD. I
tried copying it to an 8.4GB HDD I had lying around. I used Partition
Magic (hereby PM) to copy all partitions and at first all seemed well.
But when I tried to boot using the new HDD, it refused. I used Linux's
fdisk to view it and was surprised that Linux's "Extended" partition
(id=5)is not the same as the one PM placed while copying the various
partitions (id=f). I corrected it, but I am still having problem
copying the /boot partition so that it would boot.

My original (failing) HDD looks like this:

~> /sbin/fdisk -lu /dev/hda
       Device Boot Start End Blocks Id System
    /dev/hda1 63 40319 20128+ 83 Linux
    /dev/hda2 40320 7814015 3886848 5 Extended
    /dev/hda5 40383 3322367 1640992+ 83 Linux
    /dev/hda6 3322431 6604415 1640992+ 83 Linux
    /dev/hda7 6604479 7136639 266080+ 83 Linux
    /dev/hda8 7136703 7668863 266080+ 83 Linux
    /dev/hda9 7668927 7805951 68512+ 82 Linux swap

The new disk, OTOH, has for some reason (the way PM set it up), the
extended partition as /dev/hdb1 and the boot partition as /dev/hdb2
(all other partitions are correctly positioned/copied).

My questions are:
1) Why is PM and fdisk are having such a hard time "talking" to each
other?
2) How do I copy the /boot partition, so that not only its contents is
copied but it also boots when I replace the old HDD with the new HDD
(i.e. /dev/hdb becomes /deb/hda). Do I use LILO to do that? If so, how
do I change lilo.conf so that it doesn't change in anyway the original
drive (I still need it, in case something goes awfully wrong with the
new HDD. I cannot boot from a floppy).

Thanks in advance!



Relevant Pages

  • XPe beginner needs help
    ... In Target Device Settings set "Boot partition size" to 250MB, ... to a CD-R, boot the hard drive, let FBA do its thing, and then burn the ... then disable your main HDD to get this extra HDD to boot so FBA can ...
    (microsoft.public.windowsxp.embedded)
  • Cloned XP Professional boot partition - and lost the login prompt
    ... Go to device mgr and set the hdd to generic and do ... >active boot partition to a new hard drive ... drives. ...
    (microsoft.public.windowsxp.setup_deployment)
  • Re: Cd_rom booting error 7B
    ... You can tell us exact message the you see when you run "etprep /all" ... letters so that his HDD is still C: ... The boot is possible but the ... >> I also found the C partition is my HDD'patition. ...
    (microsoft.public.windowsxp.embedded)
  • Re: Partition question when reinstalling XP.
    ... > the system restore partition. ... You don't have to get another HDD. ... Simply running the restore program ... > primary boot drive, or do I copy the image back onto the original drive? ...
    (microsoft.public.windowsxp.help_and_support)
  • Re: WIN XP BIG DODO
    ... I have a PC with 4 HDD partitions and the ... > I Instaled win xp from under win 98 on partition E ... > When I tried to boot win XP is not starting. ... > If I choose install it takes me to License file not found. ...
    (microsoft.public.windowsxp.newusers)