containers / docker-lvm-plugin

Docker volume plugin for LVM volumes
GNU Lesser General Public License v3.0
155 stars 64 forks source link

docker-lvm-plugin.service failed -> no directory /run/docker/plugins/ #30

Closed megian closed 7 years ago

megian commented 7 years ago

The service does fail, because the running directory /run/docker/plugins/ does not exist.

After manually creating the path and restart the docker-lvm-plugin service. It does work.

mkdir -p /run/docker/plugins/ systemctl restart docker-lvm-plugin

centos-atomic-host:centos-atomic-host/7/x86_64/standard Version: 7.20161104 (2016-11-04 22:53:08) Commit: daf53c718bd1cd9b84b1b5d21843cd9b981d3634c2444c2bcb09cccee771058b

shishir-a412ed commented 7 years ago

@megian Can you paste the output of docker info and docker version ?

Shishir

megian commented 7 years ago

[centos@host ~]$ sudo docker version Client: Version: 1.10.3 API version: 1.22 Package version: docker-common-1.10.3-46.el7.centos.14.x86_64 Go version: go1.6.3 Git commit: cb079f6-unsupported Built: Fri Sep 16 13:24:25 2016 OS/Arch: linux/amd64

Server: Version: 1.10.3 API version: 1.22 Package version: docker-common-1.10.3-46.el7.centos.14.x86_64 Go version: go1.6.3 Git commit: cb079f6-unsupported Built: Fri Sep 16 13:24:25 2016 OS/Arch: linux/amd64

[centos@host ~]$ sudo docker info Containers: 13 Running: 9 Paused: 0 Stopped: 4 Images: 15 Server Version: 1.10.3 Storage Driver: devicemapper Pool Name: docker--vg-docker--pool Pool Blocksize: 524.3 kB Base Device Size: 10.74 GB Backing Filesystem: xfs Data file: Metadata file: Data Space Used: 9.71 GB Data Space Total: 17.16 GB Data Space Available: 7.449 GB Metadata Space Used: 1.925 MB Metadata Space Total: 46.14 MB Metadata Space Available: 44.21 MB Udev Sync Supported: true Deferred Removal Enabled: true Deferred Deletion Enabled: true Deferred Deleted Device Count: 0 Library Version: 1.02.107-RHEL7 (2016-06-09) Execution Driver: native-0.2 Logging Driver: journald Plugins: Volume: local Network: bridge null host Kernel Version: 3.10.0-327.36.3.el7.x86_64 Operating System: CentOS Linux 7 (Core) OSType: linux Architecture: x86_64 Number of Docker Hooks: 2 CPUs: 2 Total Memory: 7.64 GiB Name: host.localdomain ID: GVO6:AHN4:2VBX:KMF2:FL43:O4D6:DNJU:2ZNR:F5XH:E2CT:KNNC:NISD WARNING: bridge-nf-call-ip6tables is disabled Registries: docker.io (secure)

shishir-a412ed commented 7 years ago

@megian docker-lvm-plugin relies on https://github.com/docker/go-plugins-helpers which creates the directory /run/docker/plugins if it does not exist. https://github.com/docker/go-plugins-helpers/blob/master/sdk/unix_listener.go#L39

I just tried this on a centos VM and I am able to successfully start docker-lvm-plugin.

sh-4.2# cat /etc/redhat-release 
CentOS Linux release 7.2.1511 (Core) 

I am guessing you did a yum install docker-lvm-plugin and that might be a bit outdated. Can you try to build it from the source (The instructions are on the README.md) and try it ? Let me know if you face any problems building it from the source, and I can help.

Shishir

megian commented 7 years ago

No, I don't have installed docker-lvm-plugin manually. It is part of the atomic host image (newest). But it might be, that the image does contain an older version.

bash-4.2# atomic host status State: idle Deployments: â centos-atomic-host:centos-atomic-host/7/x86_64/standard Version: 7.20161104 (2016-11-04 22:53:08) Commit: daf53c718bd1cd9b84b1b5d21843cd9b981d3634c2444c2bcb09cccee771058b OSName: centos-atomic-host GPGSignature: 1 signature Signature made Fri 04 Nov 2016 10:56:08 PM UTC using RSA key ID F17E745691BA8335 Good signature from "CentOS Atomic SIG security@centos.org"

centos-atomic-host:centos-atomic-host/7/x86_64/standard Version: 7.20161006 (2016-10-05 23:28:52) Commit: 2ad34dba5286d69de71b61678d5190b246e7836beada3cdfa18f7bfa4ae3c3f0 OSName: centos-atomic-host GPGSignature: 1 signature Signature made Wed 05 Oct 2016 11:39:15 PM UTC using RSA key ID F17E745691BA8335 Good signature from "CentOS Atomic SIG security@centos.org"

shishir-a412ed commented 7 years ago

@megian Will let you know once the rpm package (docker-lvm-plugin) is updated. Then you can try again and let me know if you are still facing the issue.

Shishir

megian commented 7 years ago

Same issue after the upgrade to atomic host 7.20170117 (2017-01-17 17:45:04).

bash-4.2# atomic host status State: idle Deployments: â centos-atomic-host:centos-atomic-host/7/x86_64/standard Version: 7.20170117 (2017-01-17 17:45:04) Commit: 5d8b88fbdde5e1df9f50a837f881da9d6031ba5a3af5f1681b9d38793a7f503f OSName: centos-atomic-host GPGSignature: 1 signature Signature made Tue 17 Jan 2017 06:00:06 PM UTC using RSA key ID F17E745691BA8335 Good signature from "CentOS Atomic SIG security@centos.org"

bash-4.2# docker info Containers: 45 Running: 23 Paused: 0 Stopped: 22 Images: 30 Server Version: 1.10.3 Storage Driver: devicemapper Pool Name: docker--vg-docker--pool Pool Blocksize: 524.3 kB Base Device Size: 10.74 GB Backing Filesystem: xfs Data file: Metadata file: Data Space Used: 15.13 GB Data Space Total: 29.66 GB Data Space Available: 14.52 GB Metadata Space Used: 3.707 MB Metadata Space Total: 46.14 MB Metadata Space Available: 42.43 MB Udev Sync Supported: true Deferred Removal Enabled: true Deferred Deletion Enabled: true Deferred Deleted Device Count: 0 Library Version: 1.02.135-RHEL7 (2016-09-28) Execution Driver: native-0.2 Logging Driver: journald Plugins: Volume: local Network: null host bridge Kernel Version: 3.10.0-514.2.2.el7.x86_64 Operating System: CentOS Linux 7 (Core) OSType: linux Architecture: x86_64 Number of Docker Hooks: 2 CPUs: 2 Total Memory: 7.64 GiB Name: host.localdomain

bash-4.2# docker version Client: Version: 1.10.3 API version: 1.22 Package version: docker-common-1.10.3-59.el7.centos.x86_64 Go version: go1.6.3 Git commit: 3999ccb-unsupported Built: Thu Dec 15 17:24:43 2016 OS/Arch: linux/amd64

Server: Version: 1.10.3 API version: 1.22 Package version: docker-common-1.10.3-59.el7.centos.x86_64 Go version: go1.6.3 Git commit: 3999ccb-unsupported Built: Thu Dec 15 17:24:43 2016 OS/Arch: linux/amd64

bash-4.2# systemctl status docker-lvm-plugin â docker-lvm-plugin.service - Docker Volume Driver for lvm volumes Loaded: loaded (/usr/lib/systemd/system/docker-lvm-plugin.service; enabled; vendor preset: disabled) Active: failed (Result: exit-code) since Sat 2017-01-21 16:24:21 UTC; 1min 5s ago Docs: man:docker-lvm-plugin(8) Process: 941 ExecStart=/usr/libexec/docker/docker-lvm-plugin (code=exited, status=1/FAILURE) Main PID: 941 (code=exited, status=1/FAILURE)

Jan 21 16:24:20 host.localdomain systemd[1]: Started Docker Volume Driver for lvm volumes. Jan 21 16:24:20 host.localdomain systemd[1]: Starting Docker Volume Driver for lvm volumes... Jan 21 16:24:21 host.localdomain docker-lvm-plugin[941]: time="2017-01-21T16:24:21Z" level=fatal msg="listen unix /run/docker/plugins/lvm.sock: bind: no such file or directory" Jan 21 16:24:21 host.localdomain systemd[1]: docker-lvm-plugin.service: main process exited, code=exited, status=1/FAILURE Jan 21 16:24:21 host.localdomain systemd[1]: Unit docker-lvm-plugin.service entered failed state. Jan 21 16:24:21 host.localdomain systemd[1]: docker-lvm-plugin.service failed.

lsm5 commented 7 years ago

@megian, could you also please post what rpm -q docker says

lsm5 commented 7 years ago

ahh I see that it's 1.10.3-59.el7.centos.x86_64. I'm not sure if CentOS Atomic has the latest update to 1.12.5 which was recently shipped in RHEL. @jperrin any idea?

megian commented 7 years ago

The issue has been resolved in the Atomic Host version 7.20170209 (2017-02-10 00:54:47).

â centos-atomic-host:centos-atomic-host/7/x86_64/standard Version: 7.20170209 (2017-02-10 00:54:47) Commit: d433342b09673c9c4d75ff6eef50a447e73a7541491e5197e1dde14147b164b8 OSName: centos-atomic-host GPGSignature: 1 signature Signature made Fri 10 Feb 2017 01:06:18 AM UTC using RSA key ID F17E745691BA8335 Good signature from "CentOS Atomic SIG security@centos.org"

bash-4.2# docker version Client: Version: 1.12.5 API version: 1.24 Package version: docker-common-1.12.5-14.el7.centos.x86_64 Go version: go1.7.4 Git commit: 047e51b/1.12.5 Built: Mon Jan 23 15:35:13 2017 OS/Arch: linux/amd64

Server: Version: 1.12.5 API version: 1.24 Package version: docker-common-1.12.5-14.el7.centos.x86_64 Go version: go1.7.4 Git commit: 047e51b/1.12.5 Built: Mon Jan 23 15:35:13 2017 OS/Arch: linux/amd64