There is a loop nesting in function "findremapped".
we use "scsi-rescan -f -u -m" to scan all devices.
while read -r hctl sddev id_serial_old ; do
remapped=0
……
# If udev events updated the disks already, but the multipath device isn't update
# check for old devices to make sure we found remapped luns
if [ -n "$mp_enable" ] && [ $remapped -eq 0 ]; then
findmultipath "$sddev" $id_serial
if [ $? -eq 1 ] ; then
remapped=1
fi
fi
……
done < $tmpfile
There is a loop nesting in function "findremapped".
we use "scsi-rescan -f -u -m" to scan all devices.