Home >System Tutorial >LINUX >Solve the problem of busy devices in Linux
When managing umount devices in Linux, you often encounter "device is busy". If umount a file system encounters this situation, and you are not in the directory to be unmounted. Then there is probably a user or process using that directory.
# umount /mnt
umount: /mnt: device is busy
umount: /mnt: device is busy
Then you must use the fuser command to view the process ID and owner of the process, such as:
# fuser -mu /mnt
/mnt: 25781c(root)
# kill -9 25781
# umount /mnt
In this case, it means that the rhythmbox user is using that directory. Then you can also use fuser -ck /dev/sdc1 to kill the process.
# fuser -m /dev/sdc1
/dev/sdc1: 538
# ps auxw|grep 538
donncha 538 0.4 2.7 219212 56792 SLl Feb11 11:25 rhythmbox
If all these efforts still don't work, after killing the process, you may need to add -f -l parameters at this time to force uninstall
# umount -f -l /mnt
NOTE:
You can use the following command to check the bad blocks of the SATA hard disk.
# badblocks -v /dev/sda
# badblocks -v /dev/sdb
# badblocks -v /dev/mapper/vgosi-lvol1
Checking blocks 0 to 10477568
Checking for bad blocks (read-only test): done
Pass completed, 0 bad blocks found.
The above is the detailed content of Solve the problem of busy devices in Linux. For more information, please follow other related articles on the PHP Chinese website!