[root@lydb /]# lvremove /dev/mapper/openeuler-home
Logical volume openeuler/home contains a filesystem in use.
[root@lydb /]# df -h
Filesystem Size Used Avail Use% Mounted on
devtmpfs 4.0M 0 4.0M 0% /dev
tmpfs 7.6G 0 7.6G 0% /dev/shm
tmpfs 3.1G 8.6M 3.1G 1% /run
tmpfs 4.0M 0 4.0M 0% /sys/fs/cgroup
/dev/mapper/openeuler-root 60G 13G 45G 22% /
tmpfs 7.6G 0 7.6G 0% /tmp
/dev/vda1 974M 264M 643M 30% /boot
[root@lydb /]# mount /dev/mapper/openeuler-home /home
[root@lydb /]# df -h
Filesystem Size Used Avail Use% Mounted on
devtmpfs 4.0M 0 4.0M 0% /dev
tmpfs 7.6G 0 7.6G 0% /dev/shm
tmpfs 3.1G 8.6M 3.1G 1% /run
tmpfs 4.0M 0 4.0M 0% /sys/fs/cgroup
/dev/mapper/openeuler-root 60G 13G 45G 22% /
tmpfs 7.6G 0 7.6G 0% /tmp
/dev/vda1 974M 264M 643M 30% /boot
/dev/mapper/openeuler-home 30G 28K 28G 1% /home
[root@lydb /]# lsof /home
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
bash 840672 oracle cwd DIR 253,2 0 1700609 /oracle (deleted)
[root@lydb /]# kill -9 840672
[root@lydb /]# lsof /home/
[root@lydb /]# umount -l /home
[root@lydb /]# df -h
Filesystem Size Used Avail Use% Mounted on
devtmpfs 4.0M 0 4.0M 0% /dev
tmpfs 7.6G 0 7.6G 0% /dev/shm
tmpfs 3.1G 8.6M 3.1G 1% /run
tmpfs 4.0M 0 4.0M 0% /sys/fs/cgroup
/dev/mapper/openeuler-root 60G 13G 45G 22% /
tmpfs 7.6G 0 7.6G 0% /tmp
/dev/vda1 974M 264M 643M 30% /boot
[root@lydb /]# lvremove /dev/mapper/openeuler-home
Do you really want to remove active logical volume openeuler/home? [y/n]: y
Logical volume "home" successfully removed.