Aircrack-ng forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Aircrack-ng 1.7 release

Sorry Guest, you are banned from posting and sending personal messages on this forum.
This ban is not set to expire.
Pages: [1]   Go Down

Author Topic: Either "network is down" or "device or resource busy" [SOLVED]  (Read 24676 times)

b13bs

  • Newbie
  • *
  • Offline Offline
  • Posts: 4

Hi there,

I have problems with my WiFi hardware. I am on Debian Linux 3.16 on a host (not a virtual machine) and my external WiFi card is Alfa AWUS036H.

The problem is the following:
Code: [Select]
# aireplay-ng --deauth 0 -a $BSSID mon0
10:40:37  Waiting for beacon frame (BSSID: 98:FC:11:45:9B:B2) on channel 1
NB: this attack is more effective when targeting
a connected wireless client (-c <client's mac>).
10:40:38  Sending DeAuth to broadcast -- BSSID: [98:FC:11:45:9B:B2]
write failed: Network is down
wi_write(): Network is down
 
# airodump-ng --bssid $BSSID --channel 1 --write OutputWifi mon0
read failed: Network is down
Interface mon0:
ioctl(SIOCGIFINDEX) failed: No such device
Can't reopen mon0

I always had problem with my setup so this I was I will ask about it in general. First of all, the main question that I have is. Do I have to enable the physical interface that I create a virtual monitor one on?

Here are multiple ouputs of my configuration. Do you find something weird about it?

When I plugged in my antenna:
Code: [Select]
$ dmesg -w
[ 2706.758269] usb 1-2: new high-speed USB device number 6 using xhci_hcd
[ 2706.897023] usb 1-2: New USB device found, idVendor=0bda, idProduct=8187
[ 2706.897026] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 2706.897027] usb 1-2: Product: RTL8187_Wireless
[ 2706.897028] usb 1-2: Manufacturer: Manufacturer_Realtek_RTL8187_
[ 2706.897029] usb 1-2: SerialNumber: 00C0CA75797F
[ 2707.041298] ieee80211 phy1: Selected rate control algorithm 'minstrel_ht'
[ 2707.041452] ieee80211 phy1: hwaddr 00:c0:ca:75:79:7f, RTL8187vB (default) V1 + rtl8225z2, rfkill mask 2
[ 2707.050864] rtl8187: Customer ID is 0xFF
[ 2707.051211] rtl8187: wireless switch is on
[ 2707.051233] usbcore: registered new interface driver rtl8187
 
 
$ lsmod | grep -i rtl
rtl8187                63553  0
eeprom_93cx6           12625  1 rtl8187
mac80211              474201  2 rtl8187,iwlmvm
cfg80211              405538  4 iwlwifi,mac80211,rtl8187,iwlmvm
compat                 12441  5 cfg80211,iwlwifi,mac80211,rtl8187,iwlmvm
usbcore               195340  7 btusb,uvcvideo,rtl8187,ehci_hcd,ehci_pci,usbhid,xhci_hcd

After I plugged in, it is up. Here are the configs of this interface:
Code: [Select]
# ifconfig -a
[...]
wlan1     Link encap:Ethernet  HWaddr 00:c0:ca:75:79:7f 
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
 
# iwconfig
[...]
wlan1     IEEE 802.11bg  ESSID:off/any 
          Mode:Managed  Access Point: Not-Associated   Tx-Power=0 dBm 
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:on


I have seen some people enable "wlan1" interface before creating "mon0". I did both with and without putting up the interface  and I have problems both.

If I enable the "wlan1" before creating mon0, I get the following error:
Code: [Select]
# ifconfig wlan1 up

# airmon-ng start wlan1
 
Found 4 processes that could cause trouble.
If airodump-ng, aireplay-ng or airtun-ng stops working after
a short period of time, you may want to kill (some of) them!
 
PID     Name
798     avahi-daemon
814     avahi-daemon
9319    wpa_supplicant
9354    dhclient
Process with PID 9319 (wpa_supplicant) is running on interface wlan0
Process with PID 9354 (dhclient) is running on interface wlan0
 
 
Interface       Chipset         Driver
 
wlan0           Intel AC        iwlwifi - [phy0]
wlan1           Realtek RTL8187L        rtl8187 - [phy2]


# iwconfig mon0
mon0      IEEE 802.11bg  Mode:Monitor  Tx-Power=20 dBm 
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Power Management:on
 
# ifconfig mon0
mon0      Link encap:UNSPEC  HWaddr 00-C0-CA-75-79-7F-B0-44-00-00-00-00-00-00-00-00 
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:19359 errors:0 dropped:19359 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1731894 (1.6 MiB)  TX bytes:0 (0.0 B)

# iwconfig wlan1 channel 1
Error for wireless request "Set Frequency" (8B04) :
    SET failed on device wlan1 ; Device or resource busy.
# iwconfig mon0 channel 1
Error for wireless request "Set Frequency" (8B04) :
    SET failed on device mon0 ; Device or resource busy.

This behaviour is strange and undesirable. I know that when I create "mon0" I can assign the channel but this solution is not great.

If I don't enable the "wlan1" before creating mon0, I get the following error when recording a client from deauth:
Code: [Select]
# aireplay-ng --deauth 0 -a $BSSID mon0
10:40:37  Waiting for beacon frame (BSSID: 98:FC:11:45:9B:B2) on channel 1
NB: this attack is more effective when targeting
a connected wireless client (-c <client's mac>).
10:40:38  Sending DeAuth to broadcast -- BSSID: [98:FC:11:45:9B:B2]
write failed: Network is down
wi_write(): Network is down
 
# airodump-ng --bssid $BSSID --channel 1 --write OutputWifi mon0
read failed: Network is down
Interface mon0:
ioctl(SIOCGIFINDEX) failed: No such device
Can't reopen mon0

I tried to the following command:
Code: [Select]
# iwconfig wlan1 mode monitor

tl;dr: Do I ifup wlan1 before creating mon0? Anything wrong with my outputs?

Thanks a lot !
« Last Edit: May 07, 2015, 03:02:02 pm by b13bs »
Logged

misterx

  • Aircrack-ng Author
  • Administrator
  • Hero Member
  • *****
  • Offline Offline
  • Posts: 1955
  • Aircrack-ng Author
    • Aircrack-ng
Re: Either "network is down" or "device or resource busy"
« Reply #1 on: May 02, 2015, 12:38:33 am »

KILL THOSE NETWORK MANAGERS!
Logged

b13bs

  • Newbie
  • *
  • Offline Offline
  • Posts: 4
Re: Either "network is down" or "device or resource busy"
« Reply #2 on: May 06, 2015, 02:32:29 am »

Those could not be more dead. Here's what I did.

Code: [Select]
# airmon-ng check
Found 4 processes that could cause trouble.
If airodump-ng, aireplay-ng or airtun-ng stops working after
a short period of time, you may want to kill (some of) them!

PID Name
798 avahi-daemon
812 avahi-daemon
6917 wpa_supplicant
6966 dhclient
Process with PID 6917 (wpa_supplicant) is running on interface wlan0
Process with PID 6966 (dhclient) is running on interface wlan0

# service wicd stop
# airmon-ng check kill
# airmon-ng start wlan1

I still get errors:
Code: [Select]
write failed: Network is down
wi_write(): Network is down

Any other ideas? Those process were running on wlan0 which is my Internet interface and not wlan1, my wifi testing interface.
Logged

b13bs

  • Newbie
  • *
  • Offline Offline
  • Posts: 4
Re: Either "network is down" or "device or resource busy"
« Reply #3 on: May 07, 2015, 03:01:33 pm »

Holy guacamole, I fixed the problem. I saw this solution on a few thread and I never thought that would be it .

I changed the cable between the external card and the computer. With a different cable USB to Mini-USB, I got everything to work.

yay!
Logged
Pages: [1]   Go Up