I recently bought a new laptop for pentesting purposes, to mess around with stuff on my home network, and my intentions were to install virtualbox (oracle) and download a kali image to do stuff with. Here's some specs:

Host OS: windows 10

Host machine: Thinkpad t420

Virtual machine interface: Virtualbox

Wireless card: Alfa awus036h

Kali version: Latest possible

So basically, my virtual machine is working alright -nothing is directly wrong with it. I was messing around with my network card (alfa) which is connected via USB passthrough. And when networkmanager service is stopped, I am able to scan for networks. When it's on, I get no results.

When running iw wlan0 scan while networkmanager service is stopped: Snap

As you can see, there are multiple networks that are visible to my card.

Now this is what happens when I scan again, but this time with networkmanager started: snip

no results

This is very frustrating, so If you have any insight as to what could be the problem, please let me know.

PS What is the difference between the service network-manager and NetworkManager?


EDIT: The purpose is to connect to a wifi network. I used iw wlan0 scan as an example. When the service is active, my computer doesn't see any networks to connect to, therefor "disabling" the wifi on my machine.


The point is that you either have a AP/IP connectivity on an wifi interface, or you have it scanning/in monitor mode.

A wifi device cannot do both actions at the same time.

If you need Internet connectivity while in monitor mode, either you need another wifi stick, or use the default wifi of the machine, or using the ethernet interface.

| improve this answer | |
  • I'm sorry I'm not exactly sure what you mean, My card was not in monitor mode. I simple want to use the card as a normal card, and connect to a network to get wifi. – Peter_Browning Sep 12 '17 at 20:24
  • Me too. It appears there are a lot of issues with Alfa and Kali when running through VirtualBox – Brain2000 Nov 28 '17 at 6:55

When NetworkManager is running, it's already scanning for networks periodically, and its scans can interrupt your manual scan. That's why you don't get results when NetworkManager is running.

That's actually one of the problems NetworkManager is supposed to solve: there should be one central point of coordination for interrogating and configuring network settings, so that applications and commands don't step on each others' toes.

When NetworkManager is running, you should ask it for WiFi scan results instead of sending conflicting commands to the WiFi adapter: nmcli dev wifi list should give you the current list of SSIDs, and basic information on them.

If you need the deep technical details available only in the iw <interface> scan output, just use iw <interface> scan dump to get the existing results of the most recent scan: that works even with NetworkManager running. If you use iw <interface> scan, that will explicitly request the WiFi adapter to stop what it's doing and run a rescan right now, and that's what causes a conflict with NetworkManager.

If you must trigger a rescan at some particular time and NetworkManager is running, you can use nmcli dev wifi rescan for that.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.