-
-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docker volume rm fails on an unmounted volume #44
Comments
Going to try to learn how to do this myself and learn Go at the same time https://github.com/trajano/glusterfs-volume-plugin |
In my case I'm always unable to remove created volume. It doesn't care if it was used by a container or not. |
When I was building my plugin I found that this was because it was still in the backing store. Since my backing store now is boltdb and unmounting caused an error which I didn't ignore I had to remove the plugin and reinstall it. |
I am also experiencing this. its almost as if the name the volume is stored as (StackName-serviceName) under the /var/lib/docker/plugins/be1c976936ea6cc8cfbd63affbdbaf13b52934cdf42bcdaeb41dcf8195c5cdf7/rootfs/var/lib/docker-volumes/gluster/logging_elasticsearch but once the stack has been removed, the volumes are listed by the swarm daemon and on the hosts, but if I run docker volume rm logging_elasticsearch it says : Volume not found. then if I relaunch the stack , I get "Volume plugin error" and have to remove and reinstall the plugin before I can deploy the stack again. |
To resolve it simply ignore https://github.com/trajano/docker-volume-plugins/blob/master/mounted-volume/driver.go#L273-L274 that's the error that gets raised when unmounting a non-valid mount which is the scenario after a reboot. |
@Muscothym I must be that the volume was not mounted at the start. I need to take time to find a solution to report failure of mount but docker current api doesn't provide health for volume. @trajano I don't find satisfying to ignore error (even if it is ignoring a mountpoint that doesn't exist) but it works. The best solution should be to report the failed mountpoint. |
I would be curious about it too. I log the event but do not do anything about it. One way I can think of is on start up check which mounts that are recorded in the data store are valid and remove them when they are not valid. |
Description
umount
the glusterfs mountdocker volume rm
fails with error code 32 in the logs because the mount point does not exist.The scenario happens as well when you reboot the cluster.
I think a quick fix would be to check if there is a mount before doing a
umount
when doing anrm
rm -f
still works thoughThe text was updated successfully, but these errors were encountered: