当前位置:   article > 正文

umount 出现 device is busy_umount device is busy

umount device is busy

当mount挂载了文件系统之后,卸载的时候

umount遇到 device is busy


[root@linusfay ~]# umount /mnt/share
umount: /mnt/share: device is busy
umount: /mnt/share: device is busy

原因:当任何目录有 mount, 然后有程序使用/挂在那个目录上的话, 就没有办法 umount 掉, 於 umount 时会出现 Device is busy 的错误。

类似的解决办法:

1、找哪个进程在使用该挂载目录,然后杀掉该进程,卸载目录。

[root@linusfay share]# fuser -m /mnt/share
/mnt/share:           5161c


[root@linusfay share]# ps aux |grep 5161 |grep -v grep
root      5161  0.0  0.0  66076  1520 pts/3    Ss   04:53   0:00 bash

[root@linusfay share]#kill  -9   5161

[root@linusfay ~]# umount share1

2、mount  -l  /mnt/share  当需卸载文件系统的引用不繁忙时直接卸载。

[root@linusfay share]# umount share1
umount: /mnt/share: device is busy
umount: /mnt/share: device is busy

[root@linusfay share]# umount  -l share1


查看是否完成卸载:

[root@linusfay share]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                       36G   14G   21G  40% /
/dev/sda1              99M   23M   71M  25% /boot
tmpfs                 765M  364M  401M  48% /dev/shm


--没有看到  share1目录umount  -l share1已经完成卸载

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/羊村懒王/article/detail/459232
推荐阅读
相关标签
  

闽ICP备14008679号