[GLLUG] Hot Swap an ATA Hard Drive

Matt Graham danceswithcrows@usa.net
Sat, 15 Feb 2003 00:15:30 -0500


On Saturday 15 February 2003 00:03, after a long battle with technology, 
Jeff Lawton wrote:
> I have been looking for a way to remove or add a hard drive to a
> running redhat 8 system and have found nothing. In freebsd I can
> just:
>
> sync
> unmount the drive
> atacontrol detach <ide Channel>
> atacontrol attach <ide Channel>
> mount the drive
> and away I go
>
> How do I this in Linux?

sync
umount /dev/hdN*
hdparm -U /dev/hdN
(remove old drive, put in new drive)
hdparm -R /dev/hdN
mount /dev/hdN*

IDE hot-swapping is a kludge and requires special hardware, like you 
find in laptops with Ultrabays or the equivalent.  I assume Jeff has 
this stuff--remaining is just informational for the rest of the list 
and the archives:

There are adapters (roughly $25 each) for normal IDE disks; the adapter 
plugs into the motherboard's IDE interface, you slide the drive into 
the adapter.  You can't do this with vanilla IDE disks.  (Well, you can 
try, but you'll probably hork up your system.)

-- 
   "A bird in the Senate and the GNU project long before Microsoft was a
    nasty slavering sound, and three of my men were swept up in its
    flabby claws."   --MegaHAL, trained on RMS and H.P. Lovecraft
There is no Darkness in Eternity/But only Light too dim for us to see