Trying to help a company that is using a RH9 220.127.116.11-9 box as a Firewall / IDS / Proxy server recover from a hard drive failure. I didn't do the original install (ha! I was lucky to get RH9 installed on my own "spare" computer to learn how it works .. sorta ) at home. I know enough about RH9 Linux to know that I don't know what I'm doing.
The box was running 2 - 20GB HD's. One drive failed, the other didn't "kick in" automatically. I fixed that problem by commenting out a line the /etc/fstab that was referring to a /dev/hdb1 /boot2 command. I was able to RMA the defective drive under warranty, Ghost'd (7.5 ) the "good" drive to the new one, the Raid 1 recovered (eventually) and all was grand. I can't recall all of the details, I just know I got it to work again!
Fast forward 2 months - the older 20GB suffered a hardware failure. The system is now running on a single drive with RAID complaining about not having a spare available to reconstruct the array.
The "powers that be" want a pair of 40GB drives installed into the box with all of the data intact. They apparently run a proxy server that only allows their users to access websites they authorize. Fresh install and configuration ( even if I knew exactly how ) isn't an option since the person that set all of this up is not available.
I used Ghost 7.5 to clone 20GB to the 40GB using drive to drive copy. I reset the partition sizes to match the old sizes before cloning. It said it completely successfully - had 20GB or so of unpartitioned space on the drive. I then disconnected the 20GB, set the 40GB as Master (single) and attempted to boot. I got a message that read:
GRUB GRUB GRUB (ASCII smiley face) GEOM error
I did some Googlin' and found that a recommended solution was to /sbin/grub -install /dev/hda from a boot disk or CD. I downloaded the RH9 Shrike Distro ISO1, made a CD and booted from it. Typed Linux Rescue (enter a few times ) and got the choice to Continue, RO, Skip. Continue said it couldn't find any Linux partitions, dropped me to a shell. I tried to mount /dev/hda without any luck. /sbin didn't have any GRUB or LILO stuff in it. I thought to myself "Self, perhaps we need to partition the drive in Linux and try using Ghost 7.5 in a part to part copy mode."
I hooked up the original drive by itself and ran a fdisk -l :
Disk /dev/hda: 20.0 GB, 20020396032 bytes
255 heads, 63 sectors/track, 2434 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 10 80293+ 83 Linux
/dev/hda2 11 43 265072+ 82 Linux swap
/dev/hda3 44 2434 19205707+ fd Linux raid autodetect
Further digging revealed that hda1 is /boot, hda2 is Swap, hda3 is /dev/md0 mounted as /.
At this point, I shut down the server, installed the pair of 40GB drives, and ran a fresh install procedure. I created hda1 and 2 as close to the original sizes I could, then created hda3 using the rest of the disk ( figuring I could go ahead and resize the partition since it's a raid volume anyway ). I did this in graphical mode so that I could use the "minimal" install procedure. I let it finish the installation, rebooted into a clean install of RH9, everything seemed fine - no errors on boot. Shutdown the server.
I then hooked up one of the 40's as a slave, the old 20 as a master and did a ghost partition to partition of hda1 ( /boot ) and /hda3 ( / ) only. (EDIT: Ghost 7.5 only recognized Ext2 and Ext3 partitions .... the Software RAID volume was "unknown" ) I figured the swap file didn't need to be done, since it would be empty anyway. I shutdown, disco'd the 20GB, set the Ghosted 40 as Master, the other Slave, booted up - same GRUB error. Tried to boot off CD and it again wouldn't recognize any Linux partitions on the drives.
I'm completely stumped at this point - I'm not really sure how to migrate the data from the 20GB to the 40GB and make it all work exactly the way it did before.
screams for help from the "mastah's" !!!! Ok ok .... sorry for the 'net speak ... I'm so confused and tired right now .... I need to find something humorous
Contents of /etc/fstab (from 20G drive)
/dev/md0 / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
# LABEL=/boot2 /boot2 ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
/dev/hdb2 swap swap defaults 0 0
/dev/hda2 swap swap defaults 0 0
/dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0
Contents of /boot/grub/grub.conf
# grub.conf generated by anaconda
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/md0
# initrd /initrd-version.img
title Red Hat Linux (2.4.20-18.9)
kernel /vmlinuz-2.4.20-18.9 ro root=/dev/md0
title Red Hat Linux (2.4.20-8)
kernel /vmlinuz-2.4.20-8 ro root=/dev/md0
Thanks in advance for any help you can provide. I apologize for the long post - I am just trying to give as much information as I can.