Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ifconfig command not working #908

Closed
starship9 opened this issue Aug 16, 2016 · 8 comments
Closed

ifconfig command not working #908

starship9 opened this issue Aug 16, 2016 · 8 comments

Comments

@starship9
Copy link

The ifconfig command doesn't display certain networking details, for example, my system's IP.
Here's what happens -

starship9@RONIL-PC:/mnt/c/Users/Nishank/Desktop$ ifconfig
Command 'ifconfig' is available in '/sbin/ifconfig'
The command could not be located because '/sbin' is not included in the PATH environment variable.
This is most likely caused by the lack of administrative privileges associated with your user account.
ifconfig: command not found

Stack traces don't work, since it just says that the ifconfig command isn't defined.

@Adraesh
Copy link

Adraesh commented Aug 16, 2016

Run the command using sudo, but even with sudo it is still not working and it's a know issue : Warning: cannot open /proc/net/dev (No such file or directory). Limited output.

@russalex
Copy link
Contributor

Ifconfig (and some other network tools) are known not to work in the Anniversary Update. A couple of common questions are:

  1. Ping - requires to be run with Windows Admin privileges
  2. ifconfig (see Issues with ifconfig, sockets, nmap, ping, nslookup, dig and others not working #69) - Known issue with a User Voice page here. We are aware that this is a very useful tool and it is on the priority list. As always, I would recommend heading over to the user voice page and upvoting it.

@bmayen
Copy link

bmayen commented Nov 6, 2016

@russalex, can we get any visibility into the roadmap/priority for this feature? It's marked as "It's Planned" in User Voice but that's quite vague. Given the thousands of votes for this feature (isn't it the topmost requested feature at this point?) it would be very helpful/appreciated to have a little insight into when we might expect to see this. Lot's of devs are itching to move their builds and local servers over and this is a complete blocker for that.

As always, that's for all the hard work on this!

@russalex
Copy link
Contributor

russalex commented Nov 6, 2016

@bmayen, thanks for the inquiry.

You are correct that network enumeration is the top User Voice request at this time (was behind interop and inotify before we were able to deliver those). Ifconfig is also one of the first commands that people run when they install WSL as a sanity check, so it is very high on our priority list to get working.

To be transparent, we look at command like ifconfig and ip in two ways: the first is to query / view the network configuration data and the second is to modify the network on your machine. Breaking it down that way the query aspect is higher in priority for us that the configuration. We have someone working on getting the query functionality to work. That should unblock the majority of scenarios.

Hopefully that clears things up a bit. We have it marked as "It's Planned" simply because the commands cover a lot of ground. Just enumerating your connections would be better marked as "In progress".

@bmayen
Copy link

bmayen commented Nov 7, 2016

Many thanks for the feedback. Certainly enumeration is the big one we want. The User Voice page for enumeration links to this issue though so this is where I posted :)

This really helps clear things up and I'm happy to hear work on connection enumeration is still in progress. Looking forward to seeing this land and moving back to Windows!

@russalex russalex added the fixed label Nov 14, 2016
@russalex
Copy link
Contributor

@bmayen, check out last week's insider build. Ifconfig is now out in the wild.

@sunilmut
Copy link
Member

Closing this out since this is now fixed. If the issue persists, please reopen.

@bschwartz757
Copy link

Hello,
I came across this while looking for another issue - I can't seem to use Node having just installed it. Seems that the two are related however at least in my case - I decided to run ifconfig and got the same issue as above. Here's the output of both:

blake@DESKTOP-03V824V:~$ node -v
Command 'node' is available in '/usr/sbin/node'
The command could not be located because '/usr/sbin' is not included in the PATH environment variable.
This is most likely caused by the lack of administrative privileges associated with your user account.
node: command not found
blake@DESKTOP-03V824V:~$ cat /etc/environment
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"
blake@DESKTOP-03V824V:~$ ls -l /etc/environment
-rw-r--r-- 1 root root 96 Sep 13 13:41 /etc/environment
blake@DESKTOP-03V824V:~$ cat /etc/environment
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"
blake@DESKTOP-03V824V:~$ ifconfig
Command 'ifconfig' is available in '/sbin/ifconfig'
The command could not be located because '/sbin' is not included in the PATH environment variable.
This is most likely caused by the lack of administrative privileges associated with your user account.
ifconfig: command not found
blake@DESKTOP-03V824V:~$

I just re-installed WSL recently after getting my computer back from repairs. Hoping to find a way to fix this, I'm just not knowledgeable enough to troubleshoot on my own. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants
@bmayen @Adraesh @bschwartz757 @starship9 @sunilmut @russalex and others