SOLVED

Files in a host mapped volume aren't recognised

Copper Contributor

As the title says, with Insiders 16237, files in a host mapped volume aren't recognised - e.g.

type filename.txt

doesn't work.

 

Specifying the full path however does work:

type C:\MappedVolume\filename.txt

  

Is this a known issue? Is this an appropriate forum to ask questions about docker/containers on Insiders or should I ask on the moby repo?

11 Replies
This should be working - can you share the full docker commandline and full console output of the error in the container?

Thanks!
Patrick

On the server, create a temp dir with a txt file in it:

[dc2dmat05]: PS C:\> mkdir temp

    Directory: C:\

Mode                LastWriteTime         Length Name                                                                                                         
----                -------------         ------ ----                                                                                                         
d-----       14/08/2017   8:17 AM                temp                                                                                               


[dc2dmat05]: PS C:\> cd temp

[dc2dmat05]: PS C:\temp> echo 'This is a test!' > test.txt

[dc2dmat05]: PS C:\temp> type .\test.txt
This is a test!

[dc2dmat05]: PS C:\temp> 

 

Use my (Win7) workstation to create an interactive tty session:

 

C:\tmp
λ $env:DOCKER_HOST='DC2DMAT05:2376'
C:\tmp
λ docker run -it -v C:/temp:C:/temp microsoft/windowsservercore-insider
Microsoft Windows [Version 10.0.16237.1001]
(c) 2017 Microsoft Corporation. All rights reserved.

C:\>dir
 Volume in drive C has no label.
 Volume Serial Number is 7216-718A

 Directory of C:\

07/03/2017  03:14 PM             1,894 License.txt
07/02/2017  03:39 PM    <DIR>          PerfLogs
07/03/2017  03:15 PM    <DIR>          Program Files
07/02/2017  03:39 PM    <DIR>          Program Files (x86)
08/14/2017  08:15 AM    <DIR>          temp
07/03/2017  03:16 PM    <DIR>          Users
07/03/2017  03:14 PM    <DIR>          Windows
               1 File(s)          1,894 bytes
               6 Dir(s)  21,206,704,128 bytes free

C:\>cd temp

C:\temp>dir
 Volume in drive C has no label.
 Volume Serial Number is 7216-718A

 Directory of C:\temp

08/14/2017  07:55 AM    <DIR>          .
08/14/2017  07:55 AM    <DIR>          ..
08/14/2017  07:55 AM                36 test.txt
               1 File(s)             36 bytes
               2 Dir(s)  50,829,029,376 bytes free

C:\temp>type test.txt
The system cannot find the path specified.     <-- !! Doesn't work !!!!!!!!!!

C:\temp>type .\test.txt
The system cannot find the path specified.
C:\temp>type C:\temp\test.txt <- !! Works only with the full path !! This is a test! C:\temp>copy test.txt C:\test.txt <- !! Again, doesn't work without full path !!
The system cannot find the path specified.
0 file(s) copied.

C:\temp>copy C:\temp\test.txt C:\test.txt
1 file(s) copied.

C:\temp>cd ..

C:\>type test.txt <-- !! Commands work fine when file isn't in a host mapped volume !!
This is a test!

C:\>

 

This is a problem because if you map a host volume with config files for an app running on the container the app doesn't believe the config files exist 😞
best response confirmed by David Hirschfeld (Copper Contributor)
Solution

Thanks for the detailed info! I found a dev familiar with the area and it's a known issue in that build. A fix is on the way so please try a new Insider release once it's out and let us know how it goes.

Is there some other forum where I can search for all known issues with insider builds?

There isn't really a best place but this forum could become it.

 

A lot of developers are also reporting issues at https://www.github.com/moby/moby/issues but that's for issues in the open source code that Docker is built on. It's worth searching there too because you can see progress on many issues but it's not just Windows users. Do you have any suggestions on what would work best or other sites you check regularly?

I'd be inclined to start a `Microsoft/insiders-issues` repo on GitHub which could just be used for opening issues to describe problems specific to insiders builds. Being on GitHub you'd also be able to easily xref/link issues on the moby repo.

The only "code" in the repo would be the `README.md` which would describe the purpose of the repo and direct people to this forum for Q&A type questions rather than reporting issues.

We also support feedback via the Feedback Hub tool which comes with the Windows 10 client. Choose the Server category and then the appropriate subcategory. You may add attachments to the feedback if needed. When we release a new build, we provide a current list of known issues in the Feedback Hub announcement that accompanies the build.

We're running Win7 here.

The Windows blog posting that is linked to in the "new build" announcements in this forum has the same information about known issues, example for Build 16267: "See the Windows Insiders blog for more information, or check the Announcements in the Feedback Hub tool on your Windows 10 Insider device." Hope that helps.

Again, we're not running Windows 10 so saying to check the Feedback Hub tool doesn't help much.

A blog post also isn't a viable place to search for known issues as it's not updated with the status of anything or any new issues found. Case in point, *this* issue isn't mentioned anywhere on the blog post but apparently it *is* a known issue with the build.

Anyway, I appreciate the engagement on this forum but it's a terrible solution for soliciting feedback about problems with the builds. Building a tool which excludes everyone not running Win10 also won't do much for the probability of someone bothering to report problems.

This is just my opinion though so you can take it or leave it. For me however the whole process is just too painful so I'll leave it to others to hopefully find and report the bugs and I'll just hope they're fixed by the time it reaches the stable channel...


1 best response

Accepted Solutions
best response confirmed by David Hirschfeld (Copper Contributor)
Solution

Thanks for the detailed info! I found a dev familiar with the area and it's a known issue in that build. A fix is on the way so please try a new Insider release once it's out and let us know how it goes.

View solution in original post