Hello,
I have a Red Hat server running Docker, that is capable of discovering remote storage using Fiber Channel. I would like to run traffic to the remote storage using containers, by mounting the remote storage disks to different volumes from different containers and run a traffic generation tool. The issue I am facing is with the mounting of the disk to a volume in a container.
For the traffic generation part, I have created an ubuntu image that comes with IOMeter installed in it. The container also has a volume created for mounting and running traffic. The volume is named /dev/sdb in the container. I am stuck at the point, where I am not able to mount a remotely discovered disk and attach it to this volume. My red hat server has two disks discovered and attached to it over Fiber Channel, namely ‘/dev/sdb’ and ‘/dev/sdc’. I would like to mount the disk /dev/sdb to the volume /dev/sdb in the container. I was able to successfully create a volume called SB_LUN_DISK1 using the following command:
docker create volume SB_LUN_DISK1 --driver local --opt o=device=/dev/sdb
When I try to mount this newly created volume to the Container volume /dev/sdb, I get the following error:
docker: Error response from daemon: error while mounting volume ‘/var/lib/docker/volumes/SB_LUN_DISK1/_data’ : missing device in volume options.
The discovered remote disks as seen from my red hat server is given below:
Disk /dev/sdb: 16 MB, 16777216 bytes, 32768 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdc: 16 MB, 16777216 bytes, 32768 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Was wondering how I could fix the mount issue? Would be great if anyone has experience with mounting disks to a container.
My docker version is the following:
[root@MPR_DKR_162130 ~]# docker version
Client:
Version: 1.13.0
API version: 1.25
Go version: go1.7.3
Git commit: 49bf474
Built: Tue Jan 17 09:55:28 2017
OS/Arch: linux/amd64
Server:
Version: 1.13.0
API version: 1.25 (minimum version 1.12)
Go version: go1.7.3
Git commit: 49bf474
Built: Tue Jan 17 09:55:28 2017
OS/Arch: linux/amd64
Experimental: false
[root@MPR_DKR_162130 ~]#
Here a few details of my server:
[root@MPR_DKR_162130 ~]# uname -a
Linux MPR_DKR_162130 3.10.0-327.el7.x86_64 #1 SMP Thu Oct 29 17:29:29 EDT 2015 x86_64 x86_64 x86_64 GNU/Linux
[root@MPR_DKR_162130 ~]# cat /etc/redhat-release
Red Hat Enterprise Linux Server release 7.2 (Maipo)
Finally here is how my mount for the container I created looks like:
“Mounts”: [
{
“Type”: “volume”,
“Name”: “be025e42618dfe67fdc7b11d0e19ec2de8cf22bba8424f7a0efddf1a035fd76e”,
“Source”: “/var/lib/docker/volumes/be025e42618dfe67fdc7b11d0e19ec2de8cf22bba8424f7a0efddf1a035fd76e/_data”,
“Destination”: “/localdata”,
“Driver”: “local”,
“Mode”: “”,
“RW”: true,
“Propagation”: “”
},
{
“Type”: “volume”,
“Name”: “SB_LUN_DISK1”,
“Source”: “/var/lib/docker/volumes/SB_LUN_DISK1/_data”,
“Destination”: “/dev/sdb”,
“Driver”: “local”,
“Mode”: “z”,
“RW”: true,
“Propagation”: “”
}
],
Appreciate any feedback and steps to fix the issue.
Thanks,
Kaushik Prakash