WhitewaterFoundry / Fedora-Remix-for-WSL

Fedora Remix for Windows Subsystem for Linux.
Other
698 stars 51 forks source link

nmcli unable to run under Fedora Remix in WSL2 - all networking broken ? #87

Closed Gaibhne closed 3 years ago

Gaibhne commented 3 years ago

Describe the bug

sudo nmcli
Error: Could not create NMClient object: Could not connect: No such file or directory.

As I understand it, nmcli is the way to configure networking on Fedora 31. Since networking isn't working out of the box with Fedora Remix and WSL 2 (at least not for me), and I am unable to configure it due to nmcli not working, I am at a loss as to whether networking with this build is possible at all.

To Reproduce Steps to reproduce the behavior:

  1. Go to bash
  2. Run sudo nmcli
  3. See error meessage

Expected behavior I expect the nmcli tool to work without error.

Basic Troubleshooting Checklist

[x] I have searched Google for the error message. [x] I have checked official WSL troubleshooting documentation: https://docs.microsoft.com/en-us/windows/wsl/troubleshooting#confirm-wsl-is-enabled. [x] I have searched the official Microsoft WSL issues page: https://github.com/Microsoft/WSL/issues. [x] I have searched the WLinux issues page: https://github.com/WhitewaterFoundry/WLinux/issues. [*] I have reset WLinux: Settings->Apps->Apps & features->WLinux->Advanced Options->Reset. [x] I have disabled and re-enabled WSL in Windows Features. [x] I have run Windows 10 updates and restarted.

What other troubleshooting have you attempted?

Insert here:

WLinux Version

Find: Settings->Apps->Apps & features->WLinux->Advanced Options->Version.

Same as above, I don't have WLinux, but I do have Fedora Remix: Version is 31.5.0.0

Insert here:

Windows Build

OS Name: Microsoft Windows 10 Pro OS Version: 10.0.19041 N/A Build 19041 OS Manufacturer: Microsoft Corporation OS Configuration: Member Workstation OS Build Type: Multiprocessor Free BIOS Version: Dell Inc. 2.15.0, 25.03.2020

crramirez commented 3 years ago

Hello,

In fact, you can't configure the network inside WSL2. The thing is, what do you want to do? What you mean with networking is not working out of the box?

Give me some examples of what you are trying to do with networking.

Regards, Carlos

Gaibhne commented 3 years ago

Thank you for the fast response, @crramirez. I would like to use services such as ping, wget, curl, ssh and various other tools that use or require networking, including in particular dnf, which I can't seem to be able to use offline. Since I have no IP in Fedora, I can currently do nothing network related at all.

crramirez commented 3 years ago

Everything that you mention works without problems with WSL2. So I will need more information, like if you are in a restricted corporate environment or if you worked with Hyper-V networking before.

You could try to restart wsl by issuing: wsl.exe --shutdown

Also, I found this track with many problems and their solutions with WSL2 and networking: https://github.com/microsoft/WSL/issues/4926

Gaibhne commented 3 years ago

I was not aware that the configuration of network interfaces was completely divorced from the WSL 'guest'. Thank you for the heads-up, it lead me in the right direction of fixing my network adapter setup in Windows. No wonder none of the normal Linux networking tools worked right 🤦