Volume mounts in windows does not work

It is not possible to use my windows c-drive.

[18:12:47.950][SmbShare       ][Info   ] "C" is not shared
[18:12:47.952][HyperV         ][Info   ] Unmounting volumes /C;/c in a virtual machine named MobyLinuxVM
[18:12:47.954][PowerShell     ][Info   ] Run script with parameters: -Unmount True -UnmountPoints /C;/c...
[18:12:48.402][HyperV         ][Info   ] Un-Mount volume /C;/c
[18:12:55.148][SmbShare       ][Info   ] "C" is not shared
[18:12:55.150][SmbShare       ][Info   ] Sharing "C:\" as "C"
[18:12:55.172][SmbShare       ][Info   ] "C" is not shared
[18:13:22.020][Auth           ][Info   ] Storing credentials: mycomputer\localadmin:***********
[18:13:22.027][Auth           ][Info   ] Retrieved credentials: mycomputer\localadmin:***********
[18:13:22.051][SmbShare       ][Info   ] "C" is not shared
[18:13:22.053][SmbShare       ][Info   ] Sharing "C:\" as "C"
[18:13:22.056][SmbShare       ][Info   ] Creating share C with Full Control to mycomputer\localadmin
[18:13:22.147][SmbShare       ][Info   ] "C" is  shared
[18:13:22.151][SmbShare       ][Info   ] Challenging credentials with host
[18:13:22.190][SmbShare       ][Info   ] Challenging credentials with host succeeded
[18:13:22.196][HyperV         ][Info   ] Mounting volumes /C;/c in a virtual machine named MobyLinuxVM
[18:13:22.200][PowerShell     ][Info   ] Run script with parameters: -Mount True -Credential System.Management.Automation.PSCredential -MountPoints /C;/c...
[18:13:22.640][HyperV         ][Info   ] Un-Mount volume /C;/c
[18:13:22.672][HyperV         ][Info   ] Mounting host filesystem
[18:13:22.703][HyperV         ][Info   ] Mounting with user mycomputer\localadmin

Am i doing something wrong or doesn’t it work if the computer is part of a active directory?

Best regards
Dominic

2 Likes

It is possible. What is the docker command you are running? The thing I find really frustrating is that volumes do not support normal Windows paths. Why not? Why must I use //c/ notation?

Also, it doesn’t appear to work with dashes in the path. I’m doing this in PowerShell with beta 9 and none actually mount the folder with a dash in it.

cd $home
mkdir a-b
echo 'test' > a-b\c.txt
docker run --rm -it -v C:\Users\cameron\a-b:/a-b ubuntu:14.04
docker run --rm -it -v //C/Users/cameron/a-b:/a-b ubuntu:14.04
docker run --rm -it -v //c/Users/cameron/a-b:/a-b ubuntu:14.04

Nevermind, I can’t get any volumes to mount in Docker for Windows.

docker run -i -t --rm --name myproject-v //c:/var/node -p 3000:3000 -e NODE_ENV=dockerdev inspirationlabs/nodejs:4.x-slim /bin/bash

/var/node is empty

I also tried

docker run -i -t --rm --name myproject-v /c:/var/node -p 3000:3000 -e NODE_ENV=dockerdev inspirationlabs/nodejs:4.x-slim /bin/bash

Also does not work for me.

Docker Logs:
[08:37:25.239][Program ][Info ] Version: Version 1.11.0-beta9 (build: 2131) [08:37:25.270][Program ][Info ] Starting on: 5/3/2016 8:37:25 AM [08:37:25.270][Program ][Info ] Resources: C:\Program Files\Docker\Docker\Resources [08:37:25.286][Program ][Info ] OS: Windows 10 Pro Insider Preview [08:37:25.286][Program ][Info ] Edition: Professional [08:37:25.286][Program ][Info ] Id: 1511 [08:37:25.286][Program ][Info ] Build: 14316 ... [08:37:46.851][HyperV ][Info ] The VM MobyLinuxVM started on 10.0.75.2 [08:37:46.905][SmbShare ][Info ] "C" is shared [08:37:46.912][SmbShare ][Info ] Challenging credentials with host [08:37:47.025][SmbShare ][Info ] Challenging credentials with host succeeded [08:37:47.031][HyperV ][Info ] Mounting volumes /C;/c in a virtual machine named MobyLinuxVM [08:37:47.034][PowerShell ][Info ] Run script with parameters: -Mount True -Credential System.Management.Automation.PSCredential -MountPoints /C;/c... [08:37:47.183][HyperV ][Info ] Un-Mount volume /C;/c [08:37:47.324][HyperV ][Info ] Mounting host filesystem

When I try to mount a volume
docker run -v /c/Users:/data alpine ls /data
/data is empty.

Some of the Docker logs for the above command:
[08:51:41.808][Proxy ][Info ] 2016/05/03 08:51:41 proxy >> POST /v1.23/containers/create [rewriteBinds] [08:51:41.813][Proxy ][Info ] 2016/05/03 08:51:41 Rewrote mount to /c/Users:/data

I was told you must enable the shared drives. See the docs:
https://beta.docker.com/docs/windows/getting-started/#docker-settings

But even running that exact command docker run -v c:/Users:/data alpine ls /data, I am unable to list files in beta 10. With beta 11, the folders do not list either.

5 Likes

I have the same behavior. After enabling the shared drives, and running the command listed in the window

docker run -v c:/Users:/data alpine ls /data

There are no results. If I then run

docker run -v c:/:/data alpine ls -R /data

I get the following results

/data:
Users

/data/Users:
4 Likes

I can confirm @samneirinck observation

I can also confirm @samneirinck observation. Same symptom.

The same over here. I tried to use the share drive function but I can only see empty directories in the container.

Hi Cameron

I assume you have ticked the C drive box and provided your credentials before attempting to to run the command? If I do that then the command does show the expected contents

Thanks
Rolf

Hi Rolf,

Yes, I have ticked the C drive box. It just tested again on Docker version 1.11.1 (build 5604cbe) on the work Dell PC and it fails. I tested the same version on my personal laptop and it works. Both have the latest Windows 10 update. The work PC is using Active Directory Windows Auth if that matters. Any other differences or PC specs you would like me to report back?

thanks,
Cameron

Okay, i think Active Directory is the reason…
Cameron Taggart no-reply@forumsmail.docker.com schrieb am Fr., 6. Mai
2016 um 18:39:

ctaggart https://forums.docker.com/users/ctaggart Cameron Taggart
https://forums.docker.com/users/ctaggart
May 6

Hi Rolf,

Yes, I have ticked the C drive box. It just tested again on Docker version
1.11.1 (build 5604cbe) on the work Dell PC and it fails. I tested the same
version on my personal laptop and it works. Both have the latest Windows 10
update. The work PC is using Active Directory Windows Auth if that matters.
Any other differences or PC specs you would like me to report back?

thanks,
Cameron

Visit Topic
https://forums.docker.com/t/volume-mounts-in-windows-does-not-work/10693/12
or reply to this email to respond

In Reply To
rneugeba https://forums.docker.com/users/rneugeba Rolf Neugebauer
https://forums.docker.com/users/rneugeba Docker Staff
May 6
Hi Cameron I assume you have ticked the C drive box and provided your
credentials before attempting to to run the command? If I do that then the
command does show the expected contents Thanks Rolf

Visit Topic
https://forums.docker.com/t/volume-mounts-in-windows-does-not-work/10693/12
or reply to this email to respond

To stop receiving notifications for this particular topic, click here
https://forums.docker.com/t/volume-mounts-in-windows-does-not-work/10693/unsubscribe.
To unsubscribe from these emails, change your user preferences
https://forums.docker.com/my/preferences

Dominic Böttger

Dominic.Boettger@inspirationlabs.com

INSPIRATIONlabs GmbH

Rohrbacher Str. 79 | D-69115 Heidelberg | Germany
Tel. +49-6221-9853-680

Sitz der Gesellschaft: Heidelberg
Handelsregister: Amtsgericht Mannheim, HRB 704782

Well, I have the same issue but not using Active Directory. So the problem is probably not only tied to Active Directory. I can also confirm the behaviour as described by @samneirinck.
For your information I’m using the following:

  • Windows 10 Pro 1511 (10586.218)
  • Docker4Win 1.11.1-beta 10 build 2446

Restarting computer or resetting D4W and again enabling shared drive didn’t solve the issue.

(Not sure if it is important, but as Active Directory is mentioned: I’m using a local Windows account, not my Microsoft account.)

Hi Cameron

thanks for the confirmation. We do have some users which are joined in a Domain and I know it works for them. A few more questions, do either your Username or password contain a space?

Thanks
Rolf

Rolf, neither my username nor password contain a space.

thanks for the quick reply…next step would be to poke around in the VM a little. If you have time, it would be great if you could run:

docker run -it --privileged --pid=host debian nsenter -t 1 -m -n mount
and
docker run -it --privileged --pid=host debian nsenter -t 1 -m -n tail -50 /var/log/messages

preferably, after you have disabled sharing, reset credentials and the re-shared the drive.

Thanks in advance
Rolf

I’m experiencing the same problems as others.

docker run -it --privileged --pid=host debian nsenter -t 1 -m -n mount

is returning

[quote]tmpfs on / type tmpfs (rw,relatime) proc on /proc type proc (rw,nosuid,nodev,noexec,relatime) tmpfs on /run type tmpfs (rw,nodev,relatime,size=204760k,mode=755) binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime) dev on /dev type devtmpfs (rw,nosuid,relatime,size=10240k,nr_inodes=249827,mode=755) mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime) devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000) shm on /dev/shm type tmpfs (rw,nosuid,nodev,noexec,relatime) sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime) securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime) debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime) fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime) cgroup_root on /sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,relatime,size=10240k,mode=755) openrc on /sys/fs/cgroup/openrc type cgroup (rw,nosuid,nodev,noexec,relatime,release_agent=/lib/rc/sh/cgroup-release-agent.sh,name=openrc) cpuset on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset) cpu on /sys/fs/cgroup/cpu type cgroup (rw,nosuid,nodev,noexec,relatime,cpu) cpuacct on /sys/fs/cgroup/cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct) blkio on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio) memory on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory) devices on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices) freezer on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer) net_cls on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls) perf_event on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event) net_prio on /sys/fs/cgroup/net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_prio) hugetlb on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb) pids on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids) tracefs on /sys/kernel/debug/tracing type tracefs (rw,nosuid,nodev,noexec,relatime) /dev/sda2 on /var type ext4 (rw,relatime,data=ordered) /dev/sda2 on /var/lib/docker/aufs type ext4 (rw,relatime,data=ordered) none on /var/lib/docker/aufs/mnt/742172f1a9e0e8472078de72c871c8059750acbcddc02188c6592244724bc4b1 type aufs (rw,relatime,si=a46c07623ae34520,dio,dirperm1) shm on /var/lib/docker/containers/4402900b5c795e0d7bcda9e2bc180c41e63ce81fd48021237b6e827e076c1e7f/shm type tmpfs (rw,nosuid,nodev,noexec,relatime,size=65536k) nsfs on /run/docker/netns/d351533f4c30 type nsfs (rw)[/quote]

and

docker run -it --privileged --pid=host debian nsenter -t 1 -m -n tail -50 /var/log/messages

[quote]May 7 08:02:46 docker kern.info kernel: device veth6004ef4 left promiscuous mode May 7 08:02:46 docker kern.info kernel: docker0: port 1(veth6004ef4) entered disabled state May 7 08:02:46 docker kern.info kernel: docker0: port 1(veth6004ef4) entered disabled state May 7 08:02:55 docker user.info KVP: umount: /C and /c May 7 08:02:55 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:02:55 docker user.info KVP: mount: cifs //10.0.75.1/C to /C and /c May 7 08:02:55 docker user.err KVP: mount: error: 2 No such file or directory May 7 08:02:55 docker kern.notice kernel: Status code returned 0xc000006d NT_STATUS_LOGON_FAILURE May 7 08:02:55 docker kern.err kernel: CIFS VFS: Send error in SessSetup = -13 May 7 08:02:55 docker kern.err kernel: CIFS VFS: cifs_mount failed w/return code = -13 May 7 08:02:55 docker user.info KVP: umount: /D and /d May 7 08:02:55 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:02:55 docker user.info KVP: umount: /F and /f May 7 08:02:55 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:09 docker user.info KVP: umount: /C and /c May 7 08:03:09 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:10 docker user.info KVP: umount: /D and /d May 7 08:03:10 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:10 docker user.info KVP: umount: /F and /f May 7 08:03:10 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:20 docker user.info KVP: umount: /C and /c May 7 08:03:20 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:20 docker user.info KVP: mount: cifs //10.0.75.1/C to /C and /c May 7 08:03:20 docker user.err KVP: mount: error: 2 No such file or directory May 7 08:03:20 docker kern.notice kernel: Status code returned 0xc000006d NT_STATUS_LOGON_FAILURE May 7 08:03:20 docker kern.err kernel: CIFS VFS: Send error in SessSetup = -13 May 7 08:03:20 docker kern.err kernel: CIFS VFS: cifs_mount failed w/return code = -13 May 7 08:03:20 docker user.info KVP: umount: /D and /d May 7 08:03:20 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:21 docker user.info KVP: umount: /F and /f May 7 08:03:21 docker user.err KVP: umount: error: 2 No such file or directory May 7 08:03:30 docker kern.info kernel: device veth641ec63 entered promiscuous mode May 7 08:03:30 docker kern.info kernel: IPv6: ADDRCONF(NETDEV_UP): veth641ec63: link is not ready May 7 08:03:30 docker kern.info kernel: IPVS: Creating netns size=1328 id=4 May 7 08:03:30 docker kern.info kernel: eth0: renamed from veth828ee12 May 7 08:03:30 docker kern.info kernel: IPv6: ADDRCONF(NETDEV_CHANGE): veth641ec63: link becomes ready May 7 08:03:30 docker kern.info kernel: docker0: port 1(veth641ec63) entered forwarding state May 7 08:03:30 docker kern.info kernel: docker0: port 1(veth641ec63) entered forwarding state May 7 08:03:30 docker kern.info kernel: veth828ee12: renamed from eth0 May 7 08:03:30 docker kern.info kernel: docker0: port 1(veth641ec63) entered disabled state May 7 08:03:30 docker kern.info kernel: docker0: port 1(veth641ec63) entered disabled state May 7 08:03:30 docker kern.info kernel: device veth641ec63 left promiscuous mode May 7 08:03:30 docker kern.info kernel: docker0: port 1(veth641ec63) entered disabled state May 7 08:06:18 docker kern.info kernel: device veth6b7d5f7 entered promiscuous mode May 7 08:06:18 docker kern.info kernel: IPv6: ADDRCONF(NETDEV_UP): veth6b7d5f7: link is not ready May 7 08:06:18 docker kern.info kernel: IPVS: Creating netns size=1328 id=5 May 7 08:06:18 docker kern.info kernel: eth0: renamed from vethc9f5370 May 7 08:06:18 docker kern.info kernel: IPv6: ADDRCONF(NETDEV_CHANGE): veth6b7d5f7: link becomes ready May 7 08:06:18 docker kern.info kernel: docker0: port 1(veth6b7d5f7) entered forwarding state May 7 08:06:18 docker kern.info kernel: docker0: port 1(veth6b7d5f7) entered forwarding state[/quote]

Mounting started working after I’ve changed my user password. Before the change it contained some unicode characters (russian letters). Seems that changing it to plain English fixed this problem for me.

1 Like

Changing my domain password fixed it! Yay, I’m back in business.