Docker Community Forums

Share and learn in the Docker community.

Docker, Data Volume and Azure Storage

docker

(Cjanthony) #1

Hello,

I have two Docker containers that mount an Azure Storage share as a Data Volume. This is to provide redundancy for a file service as the application data needs to be available to both containers. The Azure Storage share is mounted in the host VM via CIFS.

Over the last week I’ve observed an issue where the container will lose access to the data volume. Execing into a container and typing ‘ls’ will result in a very long wait (15 minutes), eventually returning without the mounted data volume.

Jumping back out into the OS and doing an ‘ls’ on the mounted Azure Storage Share results in similarly long wait and an error of “ls: cannot access userdata: Host is down”.

I know about the Azure Docker Volume Driver however it doesn’t suit our needs as we are mounting a few configuration files as singular Data Volumes in addition to entire directories and the Azure Docker Volume Driver seems to support directories only.

Am I using Data Volumes correctly? Is pointing multiple containers to the same data volume mounted to a Azure share something that is good practice, or even supported?


(Cjanthony) #2

I’ve solved this. CIFS was timing out due to inactivity. If anyone comes after me looking for a solution, I created a file on the share and have a cron job on the client vm that does a touch -am on it. The file must be written to in some way for the connection to be refreshed.