Upgrade procedure/advice: boot sector
Jeff Vian
jvian10 at charter.net
Sun May 23 03:58:59 UTC 2004
Don Levey wrote:
>I decided that, given a slow weekend, I would upgrade my personal
>mail/web server from RedHat9 to Fedora2. Wanting to minimise problems,
>I did what I hoped would a complete, sector-for-sector copy of the main
>disk onto another disk of the same geometry using:
> dd if=/dev/hda of=/dev/hdb
>
>This seems to have worked. However, the second hard drive does not
>appear to have a boot sector. That is, when I try to boot from it I get
>messages saying that I am unable to do so (I'd get the exact message,
>but I need the old disk up right now so I can send this message...).
>
>I figured that I simply needed to install the boot loader, and found
>some instructions for installing grub at
> http://geodsoft.com/howto/dualboot/grub.htm
>Basically, this involved booting to a rescue CD, running grub, finding
>the stage1 file to confirm the device/partition, running the 'root'
>command, and then 'setup'. This looked like it had succeeded.
>
>However, I still can't boot from the disk. All the files seem to be
>there; that is, the copy looks like it succeeded.
>
>
>
This may be because you said you did a "sector-for-sector copy of the
main disk onto another disk of the same geometry using: dd if=/dev/hda
of=/dev/hdb"
This should always work *IF AND ONLY IF* the drives are exactly the same
geometry. That means same physical construciton, and even same make,
model, (and maybe even same firmware levels). If the geometry is not
exactly the same it *MAY* work.
What you in effect have done is create an exact *byte-for-byte* copy of
the drive, including boot sector, partiton table, and even the otherwise
inaccessible data that handles LBA mapping, etc. If this changed
information happens to be incompatible with the new hardware it can
fail; particularly if the boot sector is not where the drive firmware
expects it to be.
I assume from what you have said, that the drive is accessible in all
ways /except that it will not boot/. As such I would suspect a
geometry problem that confuses the drive firmware during boot and before
Linux gets loaded.
>Should I:
>1) Just boot to the Fedora CDs and run the upgrade? Would this install
>the boot loader for me? Or...
>2) Work harder at getting the new disk to boot first, and then do the
>upgrade?
>
>
Maybe you should rewrite the partiton table on the new drive and then
copy partiton-by-partition to that drive.
>Thanks in advance,
> -Don
>
>
>
>
More information about the fedora-list
mailing list