microsoft / WSL

Issues found on WSL
https://docs.microsoft.com/windows/wsl
MIT License
17.36k stars 816 forks source link

WslRegisterDistribution failed with error: 0xffffffff #4364

Closed alexey-gusarov closed 8 months ago

alexey-gusarov commented 5 years ago

Please fill out the below information:

PS C:\WINDOWS\system32> wsl --list Windows Subsystem for Linux Distributions: Ubuntu (Default)

PS C:\WINDOWS\system32> wsl --list --verbose NAME STATE VERSION

PS C:\WINDOWS\system32> WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

FeatureName : Microsoft-Windows-Subsystem-Linux DisplayName : Windows Subsystem for Linux Description : Provides services and environments for running native user-mode Linux shells and tools on Windows. RestartRequired : Possible State : Enabled CustomProperties : ServerComponent\Description : Provides services and environments for running native user-mode Linux shells and tools on Windows. ServerComponent\DisplayName : Windows Subsystem for Linux ServerComponent\Id : 1033 ServerComponent\Type : Feature ServerComponent\UniqueName : Microsoft-Windows-Subsystem-Linux ServerComponent\Deploys\Update\Name : Microsoft-Windows-Subsystem-Linux

PS C:\WINDOWS\system32> wsl --unregister ubuntu Unregistering...

PS C:\WINDOWS\system32> ubuntu Installing, this may take a few minutes... WslRegisterDistribution failed with error: 0xffffffff Error: 0xffffffff (null) Press any key to continue...

See our contributing instructions for assistance.

wsl.zip

mbwhite commented 3 years ago

I can't see any word from Microsoft on this issue? I have the error consistently, but netcfg -d from an elevated command prompt and then reboot is so far working for me. The Cisco AnyConnect I have seems to now particular effect, good or bad.

VPraharsha03 commented 3 years ago

@jawabuu Sorry for posting very late, i'd been trying to disable ICS and was wrong. Because the ICS listens on port 53 and also WSL requires it to be running (https://github.com/microsoft/WSL/issues/6646#issue-824861101) an easy solution would be making the start of the DNS server delayed (allowing WSL to listen first) by setting it's startup type to Automatic (Delayed) or keeping the ICS stopped at windows startup and it starts on it's own later

Making DNSCrypt listen to a different port kills the resolution and i don't have support for IPV6

jamieburchell commented 3 years ago

I was able to get AcrylicDNS and WSL2 working together by changing:

LocalIPv4BindingAddress=0.0.0.0

to

LocalIPv4BindingAddress=127.0.0.1

I think otherwise Acrylic tries to bind to the vEthernet (WSL) interface?

likemusic commented 3 years ago

@jamieburchell

I think otherwise Acrylic tries to bind to the vEthernet (WSL) interface?

From the Acrylic DNS config file:

;
; The local IPv4 address to which Acrylic binds. A value of 0.0.0.0 indicates that Acrylic should bind to all available
; addresses and as such it will be able to receive DNS requests coming from all of your network interfaces. A value
; corresponding to the IPv4 address of one of your network interfaces instead will allow Acrylic to receive DNS requests
; only from that specific network interface. An empty value instead indicates that no binding should occur on IPv4.
;
LocalIPv4BindingAddress=0.0.0.0
jamieburchell commented 3 years ago

From the Acrylic DNS config file:

;
; The local IPv4 address to which Acrylic binds. A value of 0.0.0.0 indicates that Acrylic should bind to all available
; addresses and as such it will be able to receive DNS requests coming from all of your network interfaces. A value
; corresponding to the IPv4 address of one of your network interfaces instead will allow Acrylic to receive DNS requests
; only from that specific network interface. An empty value instead indicates that no binding should occur on IPv4.
;
LocalIPv4BindingAddress=0.0.0.0

Yes, this is what makes me think that it clobbers and causes issue with the vEthernet (WSL) interface. I don't know what interface 127.0.0.1 belongs to, but it works.

reidsneo commented 2 years ago

Wow thank you I came here because om installed Acrylic DNS

CaptainCannabis commented 2 years ago

I deinstalled Acrylic but the service was still there and running after reboot - so also check that.

fabiopacifici commented 2 years ago

@jamieburchell thanks dude changing the LocalIPv4BindingAddress=127.0.0.1 worked for me!

dcharlespyle commented 2 years ago

I deinstalled Acrylic but the service was still there and running after reboot - so also check that.

Very NOT cool for a service to be uninstalled and have the service still remain there on the system! What is that? Is it some kind of malware packaged as a DNS proxy service? If not, it sure is acting like malware!

To get rid of it after uninstallation, one can disable the service in Services, or fire up an administrative command prompt and run:

SC DELETE [SERVICE NAME]

Substitute the actual name of the service for [SERVICE NAME]. If you are running PowerShell, type cmd in PowerShell before running the command. (And if the actual service name has spaces, use straight quotation marks around the service name.)

microsoft-github-policy-service[bot] commented 8 months ago

This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request.

Thank you!

hex406 commented 4 months ago

For me it was Acrylic DNS Proxy which was binded on UDP Port 53. Did netstat -anob didn't get program information there but got PID of the process. Opened Task Manager and pasted PID, Voila. Killed the process and game on for WSL2.

Hello Ubuntu !