Docker for windows 'Logon Failure' - windows

I am periodically getting the below error when running docker build . for a windows container. Only thing i've found that can fix it is a complete system reboot. Hoping there's some other way to fix this. Any ideas?
CreateComputeSystem 194bb656d998902d6a1cacabc8f6213df878a70bf9644bb5726a5339b5644f1e: Logon failure: the user has not been granted the requested logon type at this computer.
(extra info: {"SystemType":"Container","Name":"194bb656d998902d6a1cacabc8f6213df878a70bf9644bb5726a5339b5644f1e","Owner":"docker","IgnoreFlushesDuringBoot":true,"LayerFolderPath":"C:\\ProgramData\\Docker\\windowsfilter\\194bb656d998902d6a1cacabc8f6213df878a70bf9644bb5726a5339b5644f1e","Layers":[{"ID":"0d961d17-3e59-57ec-b577-e2fa46e415f7","Path":"C:\\ProgramData\\Docker\\windowsfilter\\a80dd368b3b7cbd9ca1d9ee09f13abda58f99ee3eae3bb608d6c56807739b931"},{"ID":"3d9a0621-57cb-56d8-a59d-98c748f857b3","Path":"C:\\ProgramData\\Docker\\windowsfilter\\b5b087f9597cb06979e26e9fc1a4439001d72a4f9ab728e3c0fae6bb6ca1f386"},{"ID":"2928a4c9-75fe-5800-920a-c63965ccb3e3","Path":"C:\\ProgramData\\Docker\\windowsfilter\\d43421924da6b091e73c586c0635a8a12acacc34ea69a158d1050120c9b4224b"},{"ID":"b8d1ec89-66da-5527-a5f1-15717cd70b32","Path":"C:\\ProgramData\\Docker\\windowsfilter\\7c34e9529e612efe1d517ee3cbb6ca41ca98192b10bb0013aa168bd15b9df836"},{"ID":"5cf70ece-e2bd-5203-942a-75ce472653b2","Path":"C:\\ProgramData\\Docker\\windowsfilter\\e3112b599c90232a36498cd01af8208bdda3c0ae3f28a37eaaf810d75534f753"}],"HostName":"07b2112c2753","HvPartition":true,"EndpointList":["3af7ee72-3894-48ce-9259-fdc853db87da"],"HvRuntime":{"ImagePath":"C:\\ProgramData\\Docker\\windowsfilter\\e3112b599c90232a36498cd01af8208bdda3c0ae3f28a37eaaf810d75534f753\\UtilityVM"},"AllowUnqualifiedDNSQuery":true})

Try running gpupdate /force i've found this works instead of a system restart or vm restart. This command will reapply all group policy settings, see docs for more info.

Related

Can't start Docker Desktop due to Windows group policy

I've updated Docker Desktop from 4.6.1 to 4.11.1, but after that I can't start Docker Desktop nor docker service. I looked in the logs and found this message:
[2022-08-12T19:27:53.379639400Z][com.docker.backend.exe][F] fork/exec C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe: This program is blocked by group policy. For more information, contact your system administrator.
I see the error is provoked by a policy that the company where I work at has on every computer and it's something I can't change, so my question is:
Is there any way to configure Docker to start using CMD instead of Powershell? Or do I have to reinstall previous version and avoid updating?

Permissions to run docker container on self-hosted windows azure devops agent

In an azure devops build pipeline running on a self-hosted windows agent, I am trying to execute a tool that run a docker container.
Unfortunately I get this error :
Failed to start: failed to create container: Error response from daemon: CreateFile c:\Users\BUILDAGENT\.aerokube\selenoid: Access is denied.
The build agent is configured with its own windows local user "BUILDAGENT", so he has permissions on the C:\Users\BUILDAGENT\ folder
Looking at the process manager, I see that except com.docker.service, the others docker processes are running with the user that launched the Docker Desktop (my coworker).
If I restart windows and relaunch docker myself, the settings selected by my coworker ("Disk Image Location" for instance), are not restored...
Is there a way to make docker run as a daemon on startup with a specific user (service or system user, but not mine or my coworker) ?
Once this is done I guess I just have to give permissions for that specific user on the C:\Users\BUILDAGENT\ folder to solve my issue, right ?
Update :
I added my BUILDAGENT user in docker-users group, and it solves the permission issue, but I still would like to run docker as a service, instead of login as my local user to launch it with its GUI...
but I still would like to run docker as a service, instead of login as my local user to launch it with its GUI
You could try to create a task scheduler to run docker with that specific user when your PC starts.
Please check this thread How to create an automated task using Task Scheduler on Windows 10 for some more details.
In this case, docker will start automatically every time you start your computer.

failing to start docker engine open //./pipe/docker_engine

I'm receiving the following error in docker on windows 10 laptop.
I've try to reinstall and restart but nothing helps.
The docker service is running OK but what i understand that i have a problem with the docker daemon (from what i read)
The whole issue started when i run the 2 commands:
net stop com.docker.service
net start com.docker.service
from there on i keep getting the error below and cannot solve it.
C:\Users\xxxx>docker images error during connect: Get
http://%2F%2F.%2Fpipe%2Fdocker_engine/v1.30/images/json: open
//./pipe/docker_engine: The system cannot find the file specified. In
the default daemon configuration on Windows, the docker client must be
run elevated to connect. This error may also indicate that the docker
daemon is not running.
anyone succeed to solve it?
docker client must be run elevated to connect
This indicates that you do not have enough permissions. Try starting the terminal as administrator.
I run Docker remotely as a non admin user.
For this the user running docker should have full permission to location where Docker is installed.
User should be part of docker_users group
docker daemon runs on port 2375 by default. Try to whitelist this port. Allow incoming connections to 2375 in Windows Firewall settings
Restart your docker daemon and Docker service.
Restart the running Docker instance[Docker for Windows] if required. You do not have to reinstall.

mongodb : listen() attempts to access socket in a forbidden way

I downloaded 64-bit zipped version of mongodb for windows, created '/data/db' as instructed.
Now, when I run "mongod" command, I am getting the following error & the mongodb server shuts down automatically.
"ERROR : listen() failed error-10013. An attempt was made to access socket in a way forbidden by its access permissions. "
Please help me to clear the firewall settings in windows to prevent this error & run mongodb.
I was able to fix the error by using the following command : "mongod --bind_ip="127.0.0.1". :)
This error also seems to happen when mongod is already running. On Windows 10, mongod will be listed under Background Processes in the Task Manager if it is running. If it is already running, ending the task should allow you to run mongod again without this error occurring. Also check that it is not running as a service; it may be set to restart automatically.
Also, if you have a docker container running mongodb, you also get this error. If you stop your container(s) running mongodb, then it should start up.
I was able to fix this issue by allowing access for Mongo Db Server Application under firewall settings in my antivirus settings.
After you did the above step,open the cmd as administrator and go to the bin path of mongodb application in your system.
Then run the below command.
mongod
Note : try the above steps only after you tried the below steps
1) https://docs.mongodb.com/manual/tutorial/configure-windows-netsh-firewall/
2)https://www.tomshardware.com/news/how-to-open-firewall-ports-in-windows-10,36451.html
I ran across a similar error which is why I ended up on this thread. For me, my solution was that McAfee Antivirus was blocking MongoDB.
The initial error basically showed that access was denied for mongo:
mongo error
I was able to do a search on the internet and found steps to allow MongoDB to run under McAfee Antivirus software by changing the setting for the app directly.
mcaffee settings
When I located MongoDB in the apps requesting internet access, it was initially set to blocked. I selected the app, clicked on edit and changed it to 'Designated ports'.
mongodb settings changed
Now, I am able to run mongo whether the mongod service is started automatically or if I start it manually in a hyper terminal window.

Silent Install of DataStax Cassandra Community Edition from Windows Server fails

I am using the datastax-community-64bit_1.2.5.msi for installing on Windows VM. I am using the silent install command
msiexec /i
C:\ddapplications\cassandra\datastax-community-64bit_1.2.5.msi /quiet
/qn /le C:\ddapplications\cassandra\installlog.txt
If I run the installation command from the command line it installs as expected. No issues.
If I run the command from a Windows Service that runs as LocalSystem, I get the following error.
Is this a known issue? Is there a workaround? I also manually tried creating a group named WORKGROUP and adding the SYSTEM user to that group.
The SYSTEM user exists in the VM.
=== Logging started: 6/7/2013 23:52:23 === Error 1609. An error occurred while applying security settings. WORKGROUP\SYSTEM is not a
valid user or group. This could be a problem with the package, or a
problem connecting to a domain controller on the network. Check your
network connection and click Retry, or Cancel to end the install.
Unable to locate the user's SID, system error 1332
=== Logging stopped: 6/7/2013 23:52:25 ===
Is your VM in a domain? What is the service that you are using to trigger the installer running as?
A possible workaround may be to make that service run as Administrator.

Resources