Volume driver recommendation for swarm?

Hi

I’m setting up my first swarm cluster, and I want to use named volumes. What plugin should I use?

  • The gluster volume driver is unmantained
  • The flocker volume driver is dead
  • The NFS volume driver that comes with the local volume driver is ok, but I need to create a new share for every volume!

What are you people using for a docker swarm cluster?

Thanks!

Technicaly it is not required to create a new share for every volume. You can use a subfolder of the share in the “device” part of the volume declaration.

In my homelab swarm cluster, I use storageos (even though unsupported with docker swarm!) which creates a blockdevice per volume and takes care of replication of the data amongst the nodes. Work well most of the time. Blockdevice filesytem corruptions were fixable most of the time: usualy it could be still mounted and backuped, so deleteting the old volume and creating a new one with the restored backup usualy did the trick. Had to follow that appoch like maybe 6-7 times in roughtly 3 years. Portworx pretty much follows the same approach, but unlike storageos, it should sitll support swarm.

In production we always used NFSv4. Things just worked nice after tweaking nfs server config, even though you can find severall voices claiming it would cause problems, it worked reliable all of the time. What realy sucked was that a) a declared volume is immutable (any change on the declaration require rm+create) and b) needs to be done on each node the volume was created (by docker stack deploy),

1 Like