[Email protected] ~]# umount/drbd/
Umount:/drbd:device is busy.
(In some cases useful info about processes, use the device are found by lsof (8) or fuser (1))
Solution One:
First, find the process and command to use this file, the specific operation code
[Email protected] ~]# lsof |grep "/DRBD"
JBD2/DRBD 8219 root CWD DIR 253,0 4096 2/
JBD2/DRBD 8219 root RTD DIR 253,0 4096 2/
JBD2/DRBD 8219 Root txt unknown/proc/8219/exe
Bash 8510 root cwd DIR 147,0 4096 3801089/drbd/mysql
Second, then execute the PS command to find the command to execute this process
[Email protected] ~]# Ps-ef|grep 8510
Root 8510 8505 0 10:54 pts/0 00:00:00-bash
Root 8536 8455 0 10:58 pts/1 00:00:00 grep 8510
Iii. forced closure of unrelated processes
[Email protected] ~]# kill-9 8510
Four, then unload the relevant mount
[Email protected] ~]# UMOUNT/DRBD
Solution Two:
[Email protected] ~]# lsof-w/DRBD
COMMAND PID USER FD TYPE DEVICE size/off NODE NAME
Bash 8510 root cwd DIR 147,0 4096 3801089/drbd/mysql
Note: The-w parameter indicates that no warning message is printed.
Direct Kill-9 8510
Solution Three:
List the process:
[Email protected] ~]# fuser-m/DRBD
/drbd:8510c
Kill the process that uses the/DRBD mount point (and users who use the process will also pop up)
[Email protected] ~]# FUSER-KM/DRBD
/drbd:8510c
The user of the machine using this process also kicked out, as follows:
[Email protected] mysql]# Connection to 192.168.88.7 closed.
[Email protected] ~]# umount/drbd/
Linux cannot umount solution