In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
When installing and deploying micro services, you need to install and deploy on different instance machines to modify the docker default path and remap to the new disk space. You need to delete the default installation path, and sometimes you may not be able to delete it normally, as shown below:
Rm-rf / var/lib/docker device or resource busy
[root@test-master playbooks] # rm-rf / var/lib/docker
Rm: unable to delete "/ var/lib/docker/containers/3bee81da15b9cf5a17b5ddbd3f777a3bcacb26f3f9e65f500aee86982c480342/shm": device or resource busy
Rm: unable to delete "/ var/lib/docker/containers/129b31e3f4663219279832a925cbb656339c48d204593e2e74e79e4574a7851a/shm": device or resource busy
Rm: unable to delete "/ var/lib/docker/containers/3033a2d03057ef17612139e998d772047b295aa46a022d3944c12c0d93097a3c/shm": device or resource busy
The troubleshooting methods are as follows:
View the current status of docker
[root@test-master playbooks] # systemctl status docker
● docker.service-Docker Application Container Engine
Loaded: loaded (/ usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
Drop-In: / etc/systemd/system/docker.service.d
└─ custom.conf
Active: active (running) since II 2019-12-24 14:19:53 CST; 19h ago
Docs: http://docs.docker.com
Main PID: 11695 (dockerd-current)
CGroup: / system.slice/docker.service
├─ 11490 / usr/bin/docker-containerd-shim-current f01c5fa965a6627e1b463b13ee8bea3e8a7af6c07653842c5730b1d2c31f000b / var/...
├─ 11695 / usr/bin/dockerd-current-add-runtime docker-runc=/usr/libexec/docker/docker-runc-current-default-runtime=d...
├─ 11704 / usr/bin/docker-containerd-current-l unix:///var/run/docker/libcontainerd/docker-containerd.sock-- metrics-in...
├─ 14828 / usr/bin/docker-containerd-shim-current 3033a2d03057ef17612139e998d772047b295aa46a022d3944c12c0d93097a3c / var/...
├─ 24024 / usr/bin/docker-containerd-shim-current 3bee81da15b9cf5a17b5ddbd3f777a3bcacb26f3f9e65f500aee86982c480342 / var/...
├─ 24042 / usr/bin/docker-containerd-shim-current 129b31e3f4663219279832a925cbb656339c48d204593e2e74e79e4574a7851a / var/...
└─ 24186 / usr/bin/docker-containerd-shim-current 8e75a3776132d00ac5834dce9c69a00954f213d0986ab44245f053649b821328 / var/...
Next, if you stop the docker service from running and delete it, if it succeeds, it will be considered OK.
If you still remind the device that the device is busy, as follows:
[root@test-master playbooks] # systemctl stop docker
[root@test-master playbooks] # rm-rf / var/lib/docker
Rm: unable to delete "/ var/lib/docker/containers/3bee81da15b9cf5a17b5ddbd3f777a3bcacb26f3f9e65f500aee86982c480342/shm": device or resource busy
Rm: unable to delete "/ var/lib/docker/containers/129b31e3f4663219279832a925cbb656339c48d204593e2e74e79e4574a7851a/shm": device or resource busy
Rm: unable to delete "/ var/lib/docker/containers/3033a2d03057ef17612139e998d772047b295aa46a022d3944c12c0d93097a3c/shm": device or resource busy
Rm: unable to delete "/ var/lib/docker/overlay2/c01587998e5dd5ca2e51b3414f528367234615d9c48f589e7abf3b03394c798a/merged": device or resource busy
Rm: unable to delete "/ var/lib/docker/overlay2/e28014890386bc9a1b5824daa46a6b5085db99db981e1e86ca77669e6670215e/merged": device or resource busy
Rm: unable to delete "/ var/lib/docker/overlay2/91bac1b5198296322b23eafd80a58503a2f0ef1d05802483e02b726384bc3991/merged": device or resource busy
Rm: unable to delete "/ var/lib/docker/overlay2/4ddb10bbce9c009aabbadc958c17b81682b74660e167384c8fa32d512a87413d/merged": device or resource busy
As explained in the above question tip, the container files containers and overlay2 need to be remounted, as shown below.
[root@test-master ~] # ls-l / var/lib/docker
Total dosage 0
Drwx-. 2 root root 6 December 25 10:23 containers
Drwx-. 2 root root 6 December 25 10:23 overlay2
[root@test-master ~] #
[root@test-master ~] # umount / var/lib/docker/containers/
[root@test-master ~] # umount / var/lib/docker/overlay2/
Just delete it.
[root@test-master ~] # rm-rf / var/lib/docker
[root@test-master ~] #
[root@test-master ~] #
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.