Quantcast
Channel: Active questions tagged windows - Super User
Viewing all articles
Browse latest Browse all 9907

ls in Docker on Windows not showing one directory

$
0
0

I'm running Windows Server 2016 Datacenter version 1607 (build 14393.6614) with Docker Desktop Community Version 2.0.0.3 (31259).

I'm running an Ubuntu docker container in an interactive mode with my C drive mounted to /mnt/c in the container. This is the command that I run as the user named afish in an elevated PowerShell:

docker run -a stdin -a stdout -t -i --security-opt seccomp:unconfined -v C:\:/mnt/c ubuntu:23.10 /bin/bash

I then go to /mnt/c and do ls -al and those are the directories that I get:

root@047daede994f:/# cd /mnt/croot@047daede994f:/mnt/c# ls -altotal 393drwxrwxrwx 2 root root   8192 Feb  5 15:25  .drwxr-xr-x 1 root root   4096 Feb  8 13:08  ..drwxrwxrwx 2 root root      0 Jan 20 18:19  Afish2drwxrwxrwx 2 root root      0 Feb 26  2023  Afish2_SSDdrwxrwxrwx 2 root root      0 Feb  6 14:25  Afish3drwxrwxrwx 2 root root      0 Feb 18  2023  Afish3_SSDdrwxrwxrwx 2 root root      0 Feb  8 10:25  Afish5drwxrwxrwx 2 root root      0 Jan  1  2023  Afish5_SSDdrwxrwxrwx 2 root root      0 Dec  9 09:49  Afish6drwxrwxrwx 2 root root      0 Dec  9 09:19  Afish6_SSDdrwxrwxrwx 2 root root      0 Sep  1  2021  Afish_SSDdrwxrwxrwx 2 root root      0 Dec  9 09:58  Afish_unencrypted-rwxr-xr-x 1 root root      1 Jul 16  2016  BOOTNXTdrwxrwxrwx 2 root root   4096 Jan 30 06:49 'Documents and Settings'drwxrwxrwx 2 root root      0 Sep 12  2016  Logsdr-xr-xr-x 2 root root      0 Feb  2  2023  MSOCachedrwxrwxrwx 2 root root      0 Mar 15  2022  OneDriveTempdrwxrwxrwx 2 root root      0 Sep  1  2021  PerfLogsdr-xr-xr-x 2 root root      0 Feb  4 07:41 'Program Files'drwxrwxrwx 2 root root      0 Feb  5 15:25 'Program Files (x86)'drwxrwxrwx 2 root root      0 Feb  4 16:37  ProgramDatadrwxrwxrwx 2 root root      0 Sep 27  2021  Python39drwxrwxrwx 2 root root      0 Sep  1  2021  Recoverydrwxrwxrwx 2 root root      0 Feb  7 15:01 'System Volume Information'dr-xr-xr-x 2 root root      0 Jan 30 06:49  Usersdrwxrwxrwx 2 root root      0 Feb  2 09:43  Windows-r-xr-xr-x 1 root root 384322 Jul 16  2016  bootmgrdrwxrwxrwx 2 root root      0 Dec  8 23:33  found.000drwxrwxrwx 2 root root      0 Nov 25  2022  inetpubdrwxrwxrwx 2 root root      0 Jan  4 18:52  minikubedrwxrwxrwx 2 root root      0 Dec 15 06:14  tmp

The problem is there is no directory named Afish. I can see the directory in Windows. Also, I can cd into that directory in the docker container and do other stuff like ls or touch:

root@047daede994f:/mnt/c# cd Afishroot@047daede994f:/mnt/c/Afish#

This is what dir /a on Windows gives:

c:\>dir C: /a Volume in drive C has no label. Volume Serial Number is E414-F089 Directory of c:\12/09/2023  10:17 AM    <DIR>          $Recycle.Bin02/08/2024  02:14 PM    <DIR>          Afish01/20/2024  07:19 PM    <DIR>          Afish202/26/2023  09:24 PM    <DIR>          Afish2_SSD02/06/2024  03:25 PM    <DIR>          Afish302/18/2023  08:28 AM    <DIR>          Afish3_SSD02/08/2024  11:25 AM    <DIR>          Afish501/01/2023  10:11 AM    <DIR>          Afish5_SSD12/09/2023  10:49 AM    <DIR>          Afish612/09/2023  10:19 AM    <DIR>          Afish6_SSD09/01/2021  06:42 AM    <DIR>          Afish_SSD12/09/2023  10:58 AM    <DIR>          Afish_unencrypted07/16/2016  02:18 PM           384,322 bootmgr07/16/2016  02:18 PM                 1 BOOTNXT09/01/2021  01:16 PM    <JUNCTION>     Documents and Settings [C:\Users]12/09/2023  12:33 AM    <DIR>          found.00011/25/2022  09:52 AM    <DIR>          inetpub09/12/2016  12:35 PM    <DIR>          Logs01/04/2024  07:52 PM    <DIR>          minikube02/02/2023  05:29 PM    <DIR>          MSOCache03/15/2022  12:58 PM    <DIR>          OneDriveTemp09/01/2021  08:18 AM    <DIR>          PerfLogs02/04/2024  08:41 AM    <DIR>          Program Files02/05/2024  04:25 PM    <DIR>          Program Files (x86)02/04/2024  05:37 PM    <DIR>          ProgramData09/27/2021  01:17 PM    <DIR>          Python3909/01/2021  01:16 PM    <DIR>          Recovery02/07/2024  04:01 PM    <DIR>          System Volume Information12/15/2023  07:14 AM    <DIR>          tmp01/30/2024  07:49 AM    <DIR>          Users02/02/2024  10:43 AM    <DIR>          Windows               2 File(s)        384,323 bytes              29 Dir(s)  50,478,219,264 bytes free

I don't know if that matters but directories Afish and Afish_SSD are encrypted with EFS by the current user. Afish is a regular directory (not a junction or a symlink).

What's wrong? Why isn't Afish listed in ls in docker?


Listings of C:\Afish:

ls:

root@047daede994f:/mnt/c/Afish# ls -altotal 24drwxrwxrwx 2 root root 8192 Feb  8 13:14 .drwxrwxrwx 2 root root 8192 Feb  5 15:25 ..drwxrwxrwx 2 root root 4096 Dec 27 11:31 Danedrwxrwxrwx 2 root root 4096 Feb  2 10:27 Dokumentydrwxrwxrwx 2 root root    0 Dec  9 10:51 Duze_Danedrwxrwxrwx 2 root root    0 Feb 18  2023 Pierdolydrwxrwxrwx 2 root root    0 Dec 11 06:50 Projekty

dir:

c:\Afish>dir /a Volume in drive C has no label. Volume Serial Number is E414-F089 Directory of c:\Afish02/08/2024  02:14 PM    <DIR>          .02/08/2024  02:14 PM    <DIR>          ..12/09/2023  11:56 AM    <JUNCTION>     Dane [C:\Users\afish\OneDrive\Dane]12/09/2023  11:56 AM    <JUNCTION>     Dokumenty [C:\Users\afish\OneDrive\Dokumenty]12/09/2023  11:51 AM    <DIR>          Duze_Dane02/18/2023  07:46 PM    <DIR>          Pierdoly12/11/2023  07:50 AM    <DIR>          Projekty               0 File(s)              0 bytes               7 Dir(s)  50,359,083,008 bytes free

Viewing all articles
Browse latest Browse all 9907

Trending Articles