bandwhich
bandwhich copied to clipboard
Failed to listen on network interface: Address family not supported by protocol (os error 97) on Ubuntu (WSL)
Platform details:
OS: Ubuntu 18.04.1 LTS (Windows Subsystem Linux) Rust version: 1.40.0
Steps to reproduce:
- Run
cargo build
. - After the compilation is done, run
cargo run
.
Does this also happen when running as root?
Looks like https://github.com/imsnif/what/issues/31
@imsnif Yes. And I ran the shell as an administrator in all cases.
@sbmthakur - it might be #31 as @Grishy mentions. This means that one of the network cards in the subsystem is virtual (or "problematic" in a different way) and what is trying to pick it up and fail (@Grishy is working on a fix for this so such a situation won't fail the entire run and would just ignore that card). If you use the -i flag with one of the interfaces, does it work for you?
Another sadder option might be that we're having issues with linux-in-windows (that's what you're running, right?) so I'd be very interested to know if the -i option solved your problem.
@imsnif Thanks for pointing out. I am getting the same error even with the -i flag. There is some reading available about network interfaces in WSL here which might be helpful.
Interesting. I'm going to take a look at this and would generally be interested in investigating further.
What seems to be happening is that we're failing to read the frames coming from any of your network interfaces. For this we're using the pnet
crate, which is cross platform - but it might have some kinks or special requirements in regards to this specific setup.
Would it be okay for you to help debug this by running some code I'll whip up to pin-point the issue?
@imsnif Sure. I am always happy to help.
Hi all. I'm currently cleaning up old issues. Can you please check if this issue still persists on the latest release? Thank you.
@cyqsimon works fine for me now on 0.21.0 👍
In which case I will close this issue as completed. Please reopen if it's still problematic, thanks.