New hdd, moved RedHat partition, floppy boot won't.

Kevin Buettner kev@primenet.com
Mon, 3 Jul 2000 10:54:12 -0700


On Jul 3, 10:19am, Mark Berkwitt wrote:

> I've been booting RH with my floppy until I got a handle on Partition Magic
> 5's boot program.
> I bought a 20GB hdd to replace those 3 little drives I'd been using.
> Red Hat 6.2 was on hdb1 and is now hda2.
> Now the obvious question is:
> How do I direct my boot floppy to find the root partition at /dev/hda2 ??

Do you have lilo on your boot floppy?

If so, try doing the following at the lilo prompt:

    linux root=/dev/hda2

OTOH, if your boot floppy was made with "make zdisk" or the like,
you won't have lilo on the disk and won't be able to use the above
trick.  In this case, you'll have to get linux booted somehow (more
about this in a moment), then eject your rescue media, reinsert your
boot floppy, and do

    rdev /dev/fd0H1440 /dev/hda2

In order to "get linux booted somehow", I suggest using tomsrtbt
("The most Linux on 1 floppy disk.")  The homepage for tomsrtbt is

        http://www.toms.net/rb/

and on this page you'll find links to version 1.7.185.  YOU DON'T
WANT THIS VERSION.  It will not work with recent versions of Red Hat
Linux.  Instead, go to ftp://ftp.toms.net/rb/ and download either

    ftp://ftp.toms.net/rb/tomsrtbt-1.7.205.dos.zip

or

    ftp://ftp.toms.net/rb/tomsrtbt-1.7.205.tar.gz

Version 1.7.205 *will* work with Red Hat.  (I know from personal
experience.)

Once you get tomsrtbt copied to a floppy and have booted it up,
you should be able to run the rdev command as described above.

Note that even if you have lilo installed on your boot floppy,
you can still use tomsrtbt to help repair it.  Do this by

    1) Boot tomsrtbt.

    2) mount your root file system, e.g,

        mount /dev/hda2 /mnt

    3) Do a chroot as follows:

        chroot /mnt /bin/sh

       You will now be using the binaries in /bin, /usr/bin, etc.

    4) Edit your /etc/fstab and fix it up.

    5) Do additional mounts if necessary.  (I.e, you might want to
       try "mount -a".

    6) Create a new boot floppy.  (Make sure you eject tomsrtbt and insert
       a blank disk.)  Use the "mkbootdisk" command for doing this.


Kevin