[sheepdog-users] can't umout disk after unplug

Valerio Pachera sirio81 at gmail.com
Fri May 3 17:07:15 CEST 2013


2013/5/3 Liu Yuan <namei.unix at gmail.com>

> I can't reproduce the problem.
>

Stange. I can reproduce it.
I stopped the cluster and checked that
  lsof /mnt/sdb2
was giving no output.

Then I restarted the cluster using md and repeated the procedure

root at test007:~# collie cluster shutdown
root at test007:~# lsof /mnt/sdb2/
root at test007:~# sheep /mnt/sheepdog/,/mnt/sheepdog/obj,/mnt/sdb2
root at test007:~# lsof /mnt/sdb2/
COMMAND  PID USER   FD   TYPE DEVICE SIZE/OFF    NODE NAME
sheep   3238 root   21u   REG   8,18  4198968 4129246
/mnt/sdb2/80257c8a00000000

root at test007:~# ps aux | grep sheepdog
root      3238  0.1  2.1 130372 42264 ?        Sl   16:58   0:00 sheep
/mnt/sheepdog/ /mnt/sheepdog/obj,/mnt/sdb2
root      3239  0.0  0.0  83408   472 ?        Ss   16:58   0:00 sheep
/mnt/sheepdog/ /mnt/sheepdog/obj,/mnt/sdb2
root      3258  0.0  0.0   7848   840 pts/1    S+   17:00   0:00 grep
sheepdog

root at test007:~# collie node md unplug /mnt/sdb2/

root at test007:~# lsof /mnt/sdb2
COMMAND  PID USER   FD   TYPE DEVICE SIZE/OFF    NODE NAME
sheep   3238 root   21u   REG   8,18  4198968 4129246
/mnt/sdb2/80257c8a00000000

root at test007:~# umount /mnt/sdb2
umount: /mnt/sdb2: device is busy.
        (In some cases useful info about processes that use
         the device is found by lsof(8) or fuser(1))

root at test007:~# collie node md info
Id      Size    Use     Path
 0      193 GB  6.9 GB  /mnt/sheepdog/obj



Also on the other node that has a second disk

root at test004:~# lsof /mnt/sdb1/
COMMAND  PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
sheep   3510 root   18u   REG   8,17  4198968  173
/mnt/sdb1/80a34c6700000000

root at test004:~# collie node md unplug /mnt/sdb1

root at test004:~# lsof /mnt/sdb1
COMMAND  PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
sheep   3510 root   18u   REG   8,17  4198968  173
/mnt/sdb1/80a34c6700000000

root at test004:~# umount /mnt/sdb1
umount: /mnt/sdb1: device is busy.
        (In some cases useful info about processes that use
         the device is found by lsof(8) or fuser(1))
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wpkg.org/pipermail/sheepdog-users/attachments/20130503/8117746a/attachment-0001.html>


More information about the sheepdog-users mailing list