[Stgt-devel] [Iscsitarget-devel] subtle differences between IET and tgtd behaviour (from initiator's perspective)

Tomasz Chmielewski mangoo
Mon May 21 11:59:44 CEST 2007

FUJITA Tomonori schrieb:


>> When the initiator uses IET, it shut downs properly.
>> With the initiator uses tgtd, it stalls somewhere at:
>> Umounting proc filesystem                 [ OK ]
>> Halting system...
>> md: stopping all md devices.
>> Synchronizing SCSI cache for disk sda:
>> And it just waits there forever (that's with no changes on the 
>> initiator; only the target program was changed).
> Can you send IET and tgt tcpdump logs (tcpdump -s 1600 -w hoge.log)
> when you shut down the initiator box?

I guess the output will be similar, but in case of tgtd, a bit shorter. 
Below a try to  explain why.

When the machine stalls at "Synchronizing SCSI cache...", it is possible 
to press ctrl + SysRq + s - kernel will report:

SysRq : Emergency Sync
Emergency Sync Complete

Which is not really true, as the machine doesn't have a network 
connection anymore (can't ping it; confirmed by pulling out the network 
cable, and pressing ctrl + SysRq + s - kernel claims that Emergency Sync 
was complete).

So I guess the real reason lies somewhere in my shutdown scripts: with 
IET, it manages to sync the iSCSI drive before the network link 
disappears, and with tgtd, it can't make it.

Hmm. My shutdown scripts are broken, and with tgtd it's just easier to 
prove it.

Tomasz Chmielewski

More information about the stgt mailing list