<div dir="ltr"><div>Greetings,</div><div><br></div><div>I have an xfs umount hang caused by forcing the block device to return</div><div>i/o errors while copying files to the filesystem.</div><div>Detailed steps to reproduce the problem on virtualbox are below.</div>
<div><br></div><div>The linux version is a recent pull and reports as 3.15.0-rc3.</div><div><br></div><div>[ 2040.248096] INFO: task umount:10303 blocked for more than 120 seconds.</div><div>[ 2040.323947]       Not tainted 3.15.0-rc3 #4</div>
<div>[ 2040.343423] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.</div><div>[ 2040.352665] umount          D ffffffff8180fe40     0 10303   8691 0x00000000</div><div>[ 2040.404918]  ffff88001e33dd58 0000000000000086 ffff88001e33dd48 ffffffff81080f82</div>
<div>[ 2040.489901]  ffff88001b311900 0000000000013180 ffff88001e33dfd8 0000000000013180</div><div>[ 2040.534772]  ffff88003daa3200 ffff88001b311900 ffff88002421aec0 ffff88002421ae80</div><div>[ 2040.587450] Call Trace:</div>
<div>[ 2040.592176]  [<ffffffff81080f82>] ? try_to_wake_up+0x232/0x2b0</div><div>[ 2040.620212]  [<ffffffff816c54d9>] schedule+0x29/0x70</div><div>[ 2040.627685]  [<ffffffffa04c4cd6>] xfs_ail_push_all_sync+0x96/0xd0 [xfs]</div>
<div>[ 2040.632236]  [<ffffffff81092230>] ? __wake_up_sync+0x20/0x20</div><div>[ 2040.659105]  [<ffffffffa04731a3>] xfs_unmountfs+0x63/0x160 [xfs]</div><div>[ 2040.691774]  [<ffffffffa0478f65>] ? kmem_free+0x35/0x40 [xfs]</div>
<div>[ 2040.698610]  [<ffffffffa0474cf5>] xfs_fs_put_super+0x25/0x60 [xfs]</div><div>[ 2040.706838]  [<ffffffff8119561e>] generic_shutdown_super+0x7e/0x100</div><div>[ 2040.723958]  [<ffffffff811956d0>] kill_block_super+0x30/0x80</div>
<div>[ 2040.734963]  [<ffffffff8119591d>] deactivate_locked_super+0x4d/0x80</div><div>[ 2040.745485]  [<ffffffff8119652e>] deactivate_super+0x4e/0x70</div><div>[ 2040.751274]  [<ffffffff811b1d42>] mntput_no_expire+0xd2/0x160</div>
<div>[ 2040.755894]  [<ffffffff811b2fff>] SyS_umount+0xaf/0x3b0</div><div>[ 2040.761032]  [<ffffffff816d1592>] system_call_fastpath+0x16/0x1b</div><div>[ .060058] XFS (sdb): xfs_log_force: error 5 returned.</div>
<div>[ 268059] XFS (sdb): xfs_log_force: error 5 returned.</div><div><br></div><div>I took a look at xfs_ail_push_all_sync and it is pretty easy to see</div><div>the hang. But it is not obvious to me how to fix it.</div><div>
Any ideas would be appreciated.</div><div><br></div><div>I am available to run additional tests or capture more logging</div><div>or whatever if that would help.</div><div><br></div><div>Thanks,</div><div>Bob</div><div><br>
</div><div><div>virtual box setup</div><div>-----------------</div><div>1 GB ram</div><div>8 GB disk</div><div>4 processors</div><div>Operating System: Linux</div><div>Version: Debian (64 bit)</div><div>Bridged networking</div>
<div>iso: debian-7.4.0-amd64-netinst.iso</div><div>Software selection</div><div>    select SSH server</div><div>    select Standard system utilities</div><div>    deselect everything else</div><div>    </div><div>dhcp ip address: 172.17.5.129</div>
<div><br></div><div>upgrade linux to 3.15.0-rc3</div><div>---------------------------</div><div>ssh 172.17.5.129</div><div>su</div><div>cd /mnt/ksrc/linux</div><div>make modules_install</div><div>make install</div><div>reboot</div>
<div><br></div><div>install tools</div><div>-------------</div><div>ssh 172.17.5.129</div><div>su</div><div>apt-get install xfsprogs</div><div>apt-get install open-iscsi</div><div>apt-get install --no-install-recommends targetcli python-urwid</div>
<div>reboot</div><div><br></div><div>reproduce bug</div><div>-------------</div><div>ssh 172.17.5.129</div><div>su</div><div>targetcli</div><div>    cd backstores</div><div>    fileio/ create name=file_backend2 file_or_dev=my_disk2 size=1G</div>
<div>    /iscsi create</div><div>    portals/ create 172.17.5.129</div><div>    cd <</div><div>    luns/ create /backstores/fileio/file_backend2</div><div>    cd <</div><div>    set attribute authentication=0 demo_mode_write_protect=0 generate_node_acls=1 cache_dynamic_acls=1</div>
<div>    exit</div><div><br></div><div>iscsiadm -m discovery -t sendtargets -p 172.17.5.129</div><div>iscsiadm -m node --login --target iqn.from_previous_iscsiadm_cmd_output</div><div>fdisk -l</div><div>mkfs -t xfs -f /dev/sdXX</div>
<div>mkdir /mnt/vola</div><div><br></div><div>put following lines in a shell script "foo.sh", fix up target and block device</div><div>    set -x</div><div>    iscsiadm -m node --target iqn.2003-01.org.linux-iscsi.debian.x8664:sn.51ab79ac3ce2 --login</div>
<div>    sleep 1</div><div>    mount -t xfs /dev/sdb /mnt/vola</div><div>    sleep 10</div><div>    iscsiadm -m node -U all</div><div>    sleep 1</div><div>    umount /mnt/vola</div><div><br></div><div>run the shell script in a loop like:</div>
<div>    while true; do ./foo.sh; done</div><div><br></div><div>in another terminal run the following:</div><div>    while true; do cp -r /usr/lib /mnt/vola; done</div><div><br></div><div>The hang seems to take from two to ten minutes to occur.</div>
</div><div><br></div></div>