Erez Zilber wrote:
> Mike,
> We're trying to solve a problem, but first the motivation: a user may
> want to stop the InfiniBand modules (/etc/init.d/openibd stop) while
> open-iscsi is running. In order to do that, we must remove ib_iser.
> Now, the question: is it ok to modprobe -r ib_iser (or iscsi_tcp) before

It is and it isn't :)

> stopping iscsid? From what I see in the init.d scripts in open-iscsi, we
> kill iscsid first. Is there a reason for that?

We kill iscsid first because it has a ref to scsi_transport_iscsi (load 
that module and run iscsid and then do a lsmod). So if you ran iscsid, 
then just modprobe -r ib_iser, it would leave scsi_transport_iscsi loaded.

The iscsi script will also remove the running sessions, before killing 
iscsid, because if there is a session running then ib_iser would also 
have a module refcount greater than 0, and the modprobe -r would fail.

There is also a bug in iscsid (iscsi_sysfs.c) where if iscsid had 
detected ib_iser it would grab (iscsi_sysfs.c:read_transports) the 
transport handle for it. And if you were to unload and reload it, then 
iscsid is not picking up the new transport handle (transport handle is 
just the pointer value of that iscsi_transport remember). So if you made 
the module loading and unloading more dynamic but did not restart 
iscsid, you have to just tweak iscsi_sysfs.c:read_transports to pick up 
the new handles.

You received this message because you are subscribed to the Google Groups 
"open-iscsi" group.
To post to this group, send email to
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at

Reply via email to