Fork me on GitHub

umount * 提示 device is busy

  报错如下:

umount /data/nginx/html/pc/static
    umount.nfs4: /data/nginx/html/pc/static: device is busy

  1、通过fuser 查看该文件被哪个进程占用

fuser -m -v /data/nginx/html/pc/static/test 

    -m 表示指定文件所在的文件系统或者块设备(处于 mount 状态)。所有访问该文件系统的进程都被列出

    -v 表示 verbose 模式。进程以 ps 的方式显示,包括 PID、USER、COMMAND、ACCESS 字段

  如果提示:-bash: fuser: command not found,则表示没有对应的包,

  解决办法:

yum install psmisc -y

  2、杀掉对应的进程,

kill -9 对应的进程编码

  3、重新取消挂载

umount /data/nginx/html/pc/static

 

posted @ 2021-12-01 16:46  Alex-Lzy  阅读(258)  评论(0编辑  收藏  举报