I am trying to mount local file system (/mnt/gpfs) inside docker on RHEL 7.6 (ppc64le) arch.
I need to know the “image name” that I need to pull or download to be used while mounting
Can anyone please assist
Docker version
Client:
Version: 18.03.1-ce
API version: 1.37
Go version: go1.9.5
Git commit: ccde200
Built: Tue May 29 17:39:14 2018
OS/Arch: linux/ppc64le
Experimental: false
Orchestrator: swarm
Server:
Engine:
Version: 18.03.1-ce
API version: 1.37 (minimum version 1.12)
Go version: go1.9.5
Git commit: ccde200
Built: Tue May 29 17:41:41 2018
OS/Arch: linux/ppc64le
Experimental: false
I have mount point (gpfs/prod) at remote host (Host A) and I have successfully mount it as (/mnt/gpfs) on Host B (local host ) where we also have docker running .
Now the next step is to mount (/mnt/gpfs) under docker so i can see it under docker file system.
I have seen several articles on web for the mount procedure but what i need image name (in our case ) as most of the examples show images/repositories (which can be pulled or downloaded) as ubuntu , debian, busybox , nginx etc.
Can i use any of these images (debian , nginx etc ) in my case ?
OR
Some specific redhat linux related image would be required ??
Example Links :
My Env
#######
OS: RHEL 7.6 (ppc64le)
Docker
Client:
Version: 18.03.1-ce
API version: 1.37
Go version: go1.9.5
Git commit: ccde200
Built: Tue May 29 17:39:14 2018
OS/Arch: linux/ppc64le
Experimental: false
Orchestrator: swarm
Server:
Engine:
Version: 18.03.1-ce
API version: 1.37 (minimum version 1.12)
Go version: go1.9.5
Git commit: ccde200
Built: Tue May 29 17:41:41 2018
OS/Arch: linux/ppc64le
Experimental: false
Also , you can suggest any other way to achieve this task
Yes mounting a filesystem is a docker feature, that you can use in any images.
You mention busybox, and example of this could be:
docker run -ti -v /mnt/gpfs:/mnt/gpfs -v busybox
This will start a container, from the image busybox and it will give you a promth (since you dont have -d in docker run)
and there you should now have the same mountpoint /mnt/gpfs
Hi Martin,
Thanks, I got a hint from the command you shared and it WORKED for a new container and target mount point can be seen !!
However, We are still looking to mount (/mnt/gpfs) into an exisitng container (NAMES=Db2wh) , Please check the command and its response at the end.
[root@node1-db2wh gpfs]# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
store/ibmcorp/db2wh_ee v11.5.2.0-db2wh-ppcle 6fbe8385dfd8 2 years ago 9.05GB
veritasnetbackup/client 8.1.2 182088531fa8 3 years ago 1.23GB
DOCKER PS
[root@node1-db2wh gpfs]# docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
2e4baf2805cb store/ibmcorp/db2wh_ee:v11.5.2.0-db2wh-ppcle “/usr/sbin/init” 4 months ago Up 4 months Db2wh
[root@node1-db2wh gpfs]# docker run -d -it --privileged=true --net=host --name=Db2wh -v /mnt/gpfs:/mnt/gpfs 6fbe8385dfd8
docker: Error response from daemon: Conflict. The container name “/Db2wh” is already in use by container “2e4baf2805cb1313f24056c2a17c6daf3b4b590dec4637176edb12b69bd3 f8ae”. You have to remove (or rename) that container to be able to reuse that name.