Page 1 of 1

Adding or removing scsi devices

Posted: Sun Dec 06, 2009 6:28 pm
by thockman
The below command will rescan fibre attached storage - LIP (loop initialization primitive)

Code: Select all

echo "1" > /sys/class/fc_host/host#/issue_lip
RH 4 or 5
The below command will can other scsi attached storage

Code: Select all

echo "- - -" > /sys/class/scsi_host/host#/scan
RH 4 or 5
To remove a single existing device explicitly

Code: Select all

echo 1 > /sys/block/<dev>/device/delete
RH 3,4 or 5
To add a single device explicitly:

Code: Select all

echo "scsi add-single-device <H> <B> <T> <L>" > /proc/scsi/scsi
To remove a device explicitly:

Code: Select all

echo "scsi remove-single-device <H> <B> <T> <L>" > /proc/scsi/scsi