Home > System Tutorial > LINUX > body text

Solve the problem of busy devices in Linux

PHPz
Release: 2024-01-02 15:44:42
forward
1242 people have browsed it

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!

Related labels:
source:jb51.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!