On Wednesday July 5, [EMAIL PROTECTED] wrote:
> I am playing around with hot swapping scsi hard drives. My machine is an
> IBM netfinity 5100. Generally I have not been able to hot swat my drives.
> For the moment, I am not using RAID, I thought it better to try a simple
> ext2 file system first. Perhaps hot swapping only works if the only
> things accessed on the drives are raid areas. Anyway, my question is how
> is hot swapping supposed to work as far as linux is concerned?
>
> This is what I find....
>
> 1. If a drive is not present when the machine is booted, but is inserted
> after the machine is up, it can't be mounted. (You get a message that the
> device is not a valid block device.)
>
> 2. If a drive is present at boot time, and then later removed and then
> later yet re-inserted, it cannot be mounted. This occurs even if the
> drive was never accessed before re-inserting. (You get scsi disk error
> messages.)
>
> Is there some step I am missing? If not, I do not think "hot-swap" drives
> work very well with linux, since any change in the disks requires
> rebooting. Granted I did not have to power the machine off/on, but I do
> seem to have to reboot. Perhaps I am just miss-understanding the meaning
> of "hot-swap".
>
> Best Regards,
> Robert Laughlin
>
I think you are right. "hot-swap" is not currently supported in
linux.
However, there is something you could try:
To quota from drivers/scsi/scsi.c:
* Usage: echo "scsi add-single-device 0 1 2 3" >/proc/scsi/scsi
* with "0 1 2 3" replaced by your "Host Channel Id Lun".
* Consider this feature BETA.
* CAUTION: This is not for hotplugging your peripherals. As
* SCSI was not designed for this you could damage your
* hardware !
* However perhaps it is legal to switch on an
* already connected device. It is perhaps not
* guaranteed this device doesn't corrupt an ongoing data transfer.
and
* Usage: echo "scsi remove-single-device 0 1 2 3" >/proc/scsi/scsi
* with "0 1 2 3" replaced by your "Host Channel Id Lun".
*
* Consider this feature pre-BETA.
*
* CAUTION: This is not for hotplugging your peripherals. As
* SCSI was not designed for this you could damage your
* hardware and thoroughly confuse the SCSI subsystem.
Using these you can possibly access drives which have been plugged in
after boot-up.
NeilBrown