Linux 强制卸载硬盘 (Device is busy)

您所在的位置:网站首页 ubuntu卸载磁盘 Linux 强制卸载硬盘 (Device is busy)

Linux 强制卸载硬盘 (Device is busy)

#Linux 强制卸载硬盘 (Device is busy)| 来源: 网络整理| 查看: 265

Table of Contents Linux 强制卸载硬盘 (Device is busy) 终止程序 查询占用的程序 终止占用的程序 卸载硬盘

Linux 强制卸载硬盘 (Device is busy)

有时,挂载的硬盘会由于程序占用或者系统故障(实际上也算是程序占用)导致无法正常卸载。直接移除又会有数据丢失甚至直接硬盘损坏的风险。所以我们需要先终止相关程序再卸载硬盘。

终止程序

/mnt/hdd0 是硬盘挂载的路径,fuser 和 unount 需要 root 权限。

查询占用的程序 fuser -m -v /mnt/hdd0

终止占用的程序

不询问

fuser -km /mnt/hdd0

逐个程序询问

fuser -m -k -i -v /mnt/hdd0

卸载硬盘 unount /mnt/hdd0


【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3