Closed laszlojau closed 3 years ago
You need to disable mmp (Multiple Mount Protection). Add -o mkfsOptions="-O ^mmp"
when creating a volume.
Example: docker volume create -d wetopi/rbd -o mkfsOptions="-O ^mmp" rbd_volume
When you add "^" in front of mmp it disables Multiple Mount Protection option.
Thank you!
Environment: OS: CentOS 7 Ceph 14.2.9 nautilus (stable) Docker version: 19.03.9 Using wetopi/rbd:3.0.0
I have been trying to use the same volume with multiple containers on the same host, but I have been running into issues.
Expected result Multiple containers are able to share the same volume, just like with the
local
driver.Issue When the volume is already in use and I try to start a new container using the plugin, it runs
rbd map
. This causes the new container to fail to start and terminate withexit status 32
if another running container is already using this volume. If I stop the original container, I can start up the new container and it doesn't try to runrbd map
again.Steps to reproduce:
Create volume
Start a container in the background that mounts the volume and keeps running:
Check
/dev/rbd/rbd
on the host where the container is running:Try to start another container, using the same volume:
Check
/dev/rbd/rbd
on the host where the container is running: