Disk replacement

Craig White plug-discuss@lists.plug.phoenix.az.us
11 Feb 2003 20:44:18 -0700


On Tue, 2003-02-11 at 18:06, Scott wrote:
> I have a dilemma...
> 
> I have a system (at work) that has a disk that is failing.  I obtained 
> another disk to replace it with but have run in to issues...
> 
> The original disk is 4g and has the following mount points:
> 
> /
> /usr
> /var
> /tmp
> /opt
> swap (not really a mount point - but it is space used)
> 
> The new disk is 20g.  I hooked it up, created the (larger) partitions, did 
> a mkfs (mkswap for swap), created anchor points (/newroot, /newusr, etc) 
> and mounted the partitions.  I then issued the following command:
> 
> dump -0f - / | (cd /newroot; restore -rf - )
> 
> The above command was appropriately modified for each mount point.  When 
> this was done, I fired up grub and issued this command at the grub prompt:
> 
> find /boot/grub/stage1
> 
> Grub repsonded with (hd0,0) and (hd1,0) (<- this being the new disk)
> I then did:
> 
> root (hd1,0)
> setup (hd1)
> 
> According to all the docs I could find, grub should now be installed in 
> the new disk.  Heres where the problem comes in:  When I attempt to boot 
> from the new disk (appropriate cable and jumper changes), all I get is the 
> work "grub" repeated forever on my screen.
> 
> Has anyone replaced a disk in this fashion and have it work?  If so, what 
> did I forget and/or miss?  I am currently at a loss for ideas.
> 
-----
I have not done this.

First thought...are the partitions in similar /dev/hd?x
e.g. /boot on both in /dev/hda1 and /dev/hd?1

second thought...can you boot CD and use linux rescue mode to mount the
partitions and chroot before you install grub?

third thought...when you installed grub, you installed to hd1 which
would suggest the first hard drive located after the primary
master...did you switch hard drives around so that it would now fail? If
so, could you do the CD, chroot and install grub again?

Craig