for-win icon indicating copy to clipboard operation
for-win copied to clipboard

Shared drive not mounting after Windows password changed.

Open jonathanlaf opened this issue 8 years ago • 18 comments

Expected behavior

Docker should respect provided volumes and ask for credentials when needed.

Actual behavior

Docker asks for credentials only from the setting page. If credentials change after that, docker just doesn't mount any volumes with no failure.

Information

  • Windows 10 Pro Version 1709 Build 16299.248
  • Windows domain installed (Do someone on regular Windows 10 can test please ?)
  • Docker Version 17.12.0-ce-win47 (15139)
  • Channel: stable
  • 9c692cd

Steps to reproduce the behavior

  1. Configure Shared Drives in docker settings interface
  2. Run a docker container and mount a configured shared drive
  3. Stop that container
  4. Change your windows password
  5. Restart that container
  6. It should start with no problem, but there will be no files in your docker when it should mount the shared drive.

jonathanlaf avatar Feb 16 '18 14:02 jonathanlaf

I can confirm this bug on my maschine with the newest version of docker:

  • Windows 10 Enterprise Version 1607 (Build 14393.2189)
  • Windows domain installed too
  • Docker version 18.03.1-ce, build 9ee9f40

Turael avatar May 16 '18 08:05 Turael

Just wasted a bunch of time today because of this.

  • Windows 10 Pro Version 10.0.17134 Build 17134
  • Docker Version 18.06.0-ce-win70 (19075)
  • Local User Account (no Active Directory, no Microsoft Account)

Workaround:

  1. Open Docker Settings
  2. Click on the Shared Drives tab
  3. Deselect your shared drives
  4. Click Apply
  5. Select the drives you want to share
  6. Click Apply
  7. Docker should prompt you to re-enter your credentials
  8. Restart your affected Docker containers

ScottShingler avatar Jul 25 '18 20:07 ScottShingler

This happened to me as well. This is creepy behaviour all over. I would have never thought docker would silently fail to mount a volume mapped to a folder on the C:-drive due to a password reset, but it does! I ended up uninstalling Docker and reinstalling it, as a part of the setup process I had to enter a user/password combo to share C:. This clued me in and finally led me here.

I have been questioning my configuration of the volume mounts in my docker.compose.yml for hours, trying different combos and failing miserably again and again (for obvious reasons, as I later learned)

sorry for the rant, hopefully this entry prevents someone else from spending hours on failing volumes

Mikael-Gustavsson avatar Oct 11 '18 11:10 Mikael-Gustavsson

Issues go stale after 90d of inactivity. Mark the issue as fresh with /remove-lifecycle stale comment. Stale issues will be closed after an additional 30d of inactivity.

Prevent issues from auto-closing with an /lifecycle frozen comment.

If this issue is safe to close now please do so.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle stale

docker-robott avatar Jan 09 '19 02:01 docker-robott

/remove-lifecycle stale /lifecycle frozen

I have the same problem. Is there a way to fix this issue without the workaround again and again?

bekihm avatar Jan 09 '19 07:01 bekihm

This has been an issue for me for over a year, one that took me quite awhile to figure out initially. It's worse now (changed my password today), Docker crashes when I try to right click it in the notification tray.

Docker failed to initialize Attempted to perform an unauthorized operation.

  • [x] I have tried with the latest version of my channel (Stable or Edge) see below
  • [x] I have uploaded Diagnostics
  • Diagnostics ID: 69AAE987-CFD6-4ED6-B7E8-B830E896B8D6/20190123065455

Information

OS: Windows 10 Enterprise Edition: Enterprise Id: 1809 Build: 17763 BuildLabName: 17763.1.amd64fre.rs5_release.180914-1434 Channel: stable

> docker version
Client: Docker Engine - Community
 Version:           18.09.1
 API version:       1.39
 Go version:        go1.10.6
 Git commit:        4c52b90
 Built:             Wed Jan  9 19:34:26 2019
 OS/Arch:           windows/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          18.09.1
  API version:      1.39 (minimum version 1.12)
  Go version:       go1.10.6
  Git commit:       4c52b90
  Built:            Wed Jan  9 19:41:49 2019
  OS/Arch:          linux/amd64
  Experimental:     true

Steps to reproduce the behavior

  1. Change your windows password
  2. It should start with no problem, but there will be no files in your docker when it should mount the shared drive.
  3. Attempt to open the settings via the notification tray icon to apply the workaround mentioned by ScottShingler.
  4. Receive Docker failed to initialize due to attempt to perform unauthorized operation. Docker crashes.

dalexander-trc avatar Jan 23 '19 14:01 dalexander-trc

This is still an issue...

Expected behavior

Docker prompts for new password to access shared drives after a system password change.

Actual behavior

Docker starts after system restart and service runs, but can't mount a volume (Error response from daemon: error while creating mount source path ''). Right clicking on Docker icon in system tray causes the client to crash and can't change/see any settings. Docker containers with no volume mounts do still run.

Information

  • [x] I have tried with the latest version of my channel (Stable or Edge)

  • [x] I have uploaded Diagnostics

  • Diagnostics ID: 3943FED3-E8B8-4377-BF17-B5C25621D49D/20190126141342

  • Windows Version: Windows 10 Pro Version 1809 (OS Build 17763.253)

  • Docker for Windows Version:

Client: Docker Engine - Community
 Version:           18.09.1
 API version:       1.39
 Go version:        go1.10.6
 Git commit:        4c52b90
 Built:             Wed Jan  9 19:34:26 2019
 OS/Arch:           windows/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          18.09.1
  API version:      1.39 (minimum version 1.12)
  Go version:       go1.10.6
  Git commit:       4c52b90
  Built:            Wed Jan  9 19:41:49 2019
  OS/Arch:          linux/amd64
  Experimental:     true

Steps to reproduce the behavior

  1. Change Windows password
  2. Run a container with a volume mount

aarongoldenthal avatar Jan 26 '19 21:01 aarongoldenthal

Today the windows password expired again and of course, docker mounted folder failed. When this will be fixed?

rsunmoto avatar Feb 28 '19 22:02 rsunmoto

Same issue, docker noob here trying to get OSRM(Open Source Routing Machine)working on windows and failing constantly with "Input file not found!". reset the credentials and voila, it works...cmon man, this really screws with the first hour impressions. all the tutorials i had to read to get to this point make me think that docker on windows is not mature

kkarakk avatar Apr 04 '19 06:04 kkarakk

This was fixed for me in the latest version (below). After a password change I was able to open the client and go to Settings > Shared Drive >Reset credentials.

Client: Docker Engine - Community
 Version:           18.09.2
 API version:       1.39
 Go version:        go1.10.8
 Git commit:        6247962
 Built:             Sun Feb 10 04:12:31 2019
 OS/Arch:           windows/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          18.09.2
  API version:      1.39 (minimum version 1.12)
  Go version:       go1.10.6
  Git commit:       6247962
  Built:            Sun Feb 10 04:13:06 2019
  OS/Arch:          linux/amd64
  Experimental:     true

...but I would agree that volume mounts in Docker for Windows are not robust.

aarongoldenthal avatar Apr 04 '19 12:04 aarongoldenthal

That is not "fixed". it fails silently when you try to docker run -v files by saying "files not found". how are you supposed to jump from that error message to "docker doesn't know the credentials to use to access the file system"?

kkarakk avatar Apr 04 '19 12:04 kkarakk

@kkarakk That's a fair point. By "fixed" I mean Docker no longer crashes in this case and you can actually get to reset the credentials (previously without the workaround described above you had to reinstall Docker, at least I did).

aarongoldenthal avatar Apr 04 '19 12:04 aarongoldenthal

I vote for a solution where docker fails fast when a "cant mount volume"-condition occurrs. This is a fatal error that might have far-reaching-consequenses if left unchecked. I think Docker should refuse to start containers where a volume mout fails. I would prefer a descriptive error message as well, making it easy for me to diagnose the root cause of failing to mount a volume.

Mikael-Gustavsson avatar Apr 04 '19 15:04 Mikael-Gustavsson

Any updates on this? The issue still persists, and it is REALLY frustrating as it leads to to wasting time every time the password changes. Docker should ideally prompt the user to update credentials after a password change (as other apps do), and at the very least log a descriptive error and possibly refuse to start the container for which the volume mount failed, as @Mikael-Gustavsson suggested.

esune avatar Jun 13 '19 17:06 esune

Just wasted a bunch of time today because of this.

  • Windows 10 Pro Version 10.0.17134 Build 17134
  • Docker Version 18.06.0-ce-win70 (19075)
  • Local User Account (no Active Directory, no Microsoft Account)

Workaround:

  1. Open Docker Settings
  2. Click on the Shared Drives tab
  3. Deselect your shared drives
  4. Click Apply
  5. Select the drives you want to share
  6. Click Apply
  7. Docker should prompt you to re-enter your credentials
  8. Restart your affected Docker containers

How can I execute the same in Windows 8.1?

Shivendra30 avatar Jun 15 '19 02:06 Shivendra30

Create a new local admin user just for Docker Desktop

  1. Go to Computer Management > System Tools > Local Users & Groups
  2. Right Click on Users folder and select New User...
  3. Fill UserName by DockerDesktopUser
  4. Fill the password fields
  5. Uncheck User must change password at next logon
  6. Check User cannot change password
  7. Check Password never expires
  8. Click on the Create button
  9. Right Click on DockerDesktopUser user and select Properties
  10. Go to the Member Of tab
  11. Click on Add... button
  12. Write Administrators (In your computer language) in the field and click on Check Names
  13. Click Ok > Apply > Ok
  14. Now on the Docker Destop prompt for Drives permissions you can use the username DockerDesktopUser/yourpassword

Your password will never expires and you won't have this issue anymore.

M07 avatar Feb 09 '20 18:02 M07

This is fixed with the new filesharing implementation in 2.2.0.3, so closing this ticket.

stephen-turner avatar Feb 11 '20 14:02 stephen-turner

Closed issues are locked after 30 days of inactivity. This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. /lifecycle locked

docker-robott avatar Jun 26 '20 03:06 docker-robott