hostpad failed when station active

Bob bobnlinux at gmail.com
Sun Jul 3 00:25:53 PDT 2016



On Saturday 25 June 2016 09:13 AM, Bob wrote:
>
> On Friday 24 June 2016 03:16 PM, Jouni Malinen wrote:
>> On Thu, Jun 23, 2016 at 03:10:59PM +0000, Bob wrote:
>>> No issue to start the AP alone with the minimal hostapd configuration
>>> channel=6
>>> hw_mode=g
>>> but failed when virtual station is already up.
>> Which channel is the station interface using here? The driver is
>> unlikely to support multiple different channels, so that could be
>> behind the issue.
>>
>>> Then hostapd gives following errors
>>>
>>> ~~~
>>> nl80211: send_mlme - da= ff:ff:ff:ff:ff:ff noack=0 freq=0 no_cck=0
>>> offchanok=0 wait_time=0 fc=0xc0 (WLAN_FC_STYPE_DEAUTH) nlmode=3
>>> nl80211: send_mlme -> send_frame
>>> nl80211: send_frame - Use bss->freq=2412
>>> nl80211: send_frame -> send_frame_cmd
>>> nl80211: Frame command failed: ret=-16 (Device or resource busy)
>>> (freq=2412 wait=0)
>>> ~~~~
>> That's not a real issue, i.e., that's fine to ignore. The real issue
>> would likely show up in the log either before or after this message.
>>
>
>
> Hello Jouni,
>
> Thanks for the response. Good news is, everything is working after I 
> upgraded the system yesterday. Don't know, which software has fixed 
> it, but the hostapd version and configuration are still same. Only 
> issue, hostapd fails to run after ram hibernation. It shows
>
> ~~~
> nl80211: Register frame command failed (type=176): ret=-114 (Operation 
> already in progress)
> nl80211: Register frame match - hexdump(len=0): [NULL]
> nl80211: Could not configure driver mode
> nl80211: Remove monitor interface: refcount=0
> nl80211: Remove beacon (ifindex=13)
> ~~~~
>
> further checking shows a hostapd process is already exist at 
> background. Killing the same fixed the issue.
> What can be done to handle this during hibernation ?
>
> regards,
> Bob

Hello Jouni & list,

I have come back again with the same issue "nl80211: Beacon set failed: 
-16 (Device or resource busy)"
Sometime the AP works out off the box. But sometime it fails ( even 
after reboot).

When fails it shows nothing in log but "hostapd -d" shows below. What 
might be the reason ?

~~~
random: Trying to read entropy from /dev/random
Configuration file: /etc/hostapd.conf
rfkill: initial event: idx=0 type=1 op=0 soft=0 hard=0
rfkill: initial event: idx=1 type=2 op=0 soft=0 hard=0
rfkill: initial event: idx=2 type=2 op=0 soft=0 hard=0
nl80211: TDLS supported
nl80211: TDLS external setup
nl80211: Supported cipher 00-0f-ac:1
nl80211: Supported cipher 00-0f-ac:5
nl80211: Supported cipher 00-0f-ac:2
nl80211: Supported cipher 00-0f-ac:4
nl80211: Supported cipher 00-0f-ac:10
nl80211: Supported cipher 00-0f-ac:8
nl80211: Supported cipher 00-0f-ac:9
nl80211: Supported cipher 00-0f-ac:6
nl80211: Supported cipher 00-0f-ac:13
nl80211: Supported cipher 00-0f-ac:11
nl80211: Supported cipher 00-0f-ac:12
nl80211: Using driver-based off-channel TX
nl80211: Use separate P2P group interface (driver advertised support)
nl80211: interface sw_ap in phy phy0
nl80211: Set mode ifindex 13 iftype 3 (AP)
nl80211: Setup AP(sw_ap) - device_ap_sme=0 use_monitor=0
nl80211: Subscribe to mgmt frames with AP handle 0x55de0fb26d80
nl80211: Register frame type=0xb0 (WLAN_FC_STYPE_AUTH) 
nl_handle=0x55de0fb26d80 match=
nl80211: Register frame type=0x0 (WLAN_FC_STYPE_ASSOC_REQ) 
nl_handle=0x55de0fb26d80 match=
nl80211: Register frame type=0x20 (WLAN_FC_STYPE_REASSOC_REQ) 
nl_handle=0x55de0fb26d80 match=
nl80211: Register frame type=0xa0 (WLAN_FC_STYPE_DISASSOC) 
nl_handle=0x55de0fb26d80 match=
nl80211: Register frame type=0xc0 (WLAN_FC_STYPE_DEAUTH) 
nl_handle=0x55de0fb26d80 match=
nl80211: Register frame type=0xd0 (WLAN_FC_STYPE_ACTION) 
nl_handle=0x55de0fb26d80 match=
nl80211: Register frame type=0x40 (WLAN_FC_STYPE_PROBE_REQ) 
nl_handle=0x55de0fb26d80 match=
nl80211: Add own interface ifindex 13
nl80211: if_indices[16]: 13
phy: phy0
BSS count 1, BSSID mask 00:00:00:00:00:00 (0 bits)
nl80211: Regulatory information - country=00
nl80211: 2402-2472 @ 40 MHz 20 mBm
nl80211: 2457-2482 @ 40 MHz 20 mBm (no IR)
nl80211: 2474-2494 @ 20 MHz 20 mBm (no OFDM) (no IR)
nl80211: 5170-5250 @ 80 MHz 20 mBm (no IR)
nl80211: 5250-5330 @ 80 MHz 20 mBm (DFS) (no IR)
nl80211: 5490-5730 @ 160 MHz 20 mBm (DFS) (no IR)
nl80211: 5735-5835 @ 80 MHz 20 mBm (no IR)
nl80211: 57240-63720 @ 2160 MHz 0 mBm
nl80211: Added 802.11b mode based on 802.11g information
Completing interface initialization
Mode: IEEE 802.11g  Channel: 1  Frequency: 2412 MHz
DFS 0 channels required radar detection
nl80211: Set freq 2412 (ht_enabled=0, vht_enabled=0, bandwidth=20 MHz, 
cf1=2412 MHz, cf2=0 MHz)
RATE[0] rate=10 flags=0x1
RATE[1] rate=20 flags=0x1
RATE[2] rate=55 flags=0x1
RATE[3] rate=110 flags=0x1
RATE[4] rate=60 flags=0x0
RATE[5] rate=90 flags=0x0
RATE[6] rate=120 flags=0x0
RATE[7] rate=180 flags=0x0
RATE[8] rate=240 flags=0x0
RATE[9] rate=360 flags=0x0
RATE[10] rate=480 flags=0x0
RATE[11] rate=540 flags=0x0
hostapd_setup_bss(hapd=0x55de0fb276f0 (sw_ap), first=1)
sw_ap: Flushing old station entries
nl80211: flush -> DEL_STATION sw_ap (all)
sw_ap: Deauthenticate all stations
nl80211: send_mlme - da= ff:ff:ff:ff:ff:ff noack=0 freq=0 no_cck=0 
offchanok=0 wait_time=0 fc=0xc0 (WLAN_FC_STYPE_DEAUTH) nlmode=3
nl80211: send_mlme -> send_frame
nl80211: send_frame - Use bss->freq=2412
nl80211: send_frame -> send_frame_cmd
nl80211: Frame command failed: ret=-16 (Device or resource busy) 
(freq=2412 wait=0)
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=0 set_tx=0 seq_len=0 key_len=0
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=1 set_tx=0 seq_len=0 key_len=0
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=2 set_tx=0 seq_len=0 key_len=0
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=3 set_tx=0 seq_len=0 key_len=0
Using interface sw_ap with hwaddr 1e:e7:c2:33:4a:48 and ssid "XXXX"
Deriving WPA PSK based on passphrase
SSID - hexdump_ascii(len=4):
      58 58 58 58                                       myap
PSK (ASCII passphrase) - hexdump_ascii(len=8): [REMOVED]
PSK (from passphrase) - hexdump(len=32): [REMOVED]
random: Got 20/20 bytes from /dev/random
GMK - hexdump(len=32): [REMOVED]
Key Counter - hexdump(len=32): [REMOVED]
WPA: Delay group state machine start until Beacon frames have been 
configured
nl80211: Set beacon (beacon_set=0)
nl80211: Beacon head - hexdump(len=55): 80 00 00 00 ff ff ff ff ff ff 1e 
e7 c2 33 4a 48 1e e7 c2 33 4a 48 00 00 00 00 00 00 00 00 00 00 64 00 11 
04 00 04 58 58 58 58 01 08 82 84 8b 96 0c 12 18 24 03 01 01
nl80211: Beacon tail - hexdump(len=65): 2a 01 04 32 04 30 48 60 6c 30 14 
01 00 00 0f ac 02 01 00 00 0f ac 04 01 00 00 0f ac 02 00 00 dd 16 00 50 
f2 01 01 00 00 50 f2 02 01 00 00 50 f2 02 01 00 00 50 f2 02 7f 08 00 00 
00 02 00 00 00 40
nl80211: ifindex=13
nl80211: beacon_int=100
nl80211: dtim_period=2
nl80211: ssid - hexdump_ascii(len=4):
      58 58 58 58                                       myap
nl80211: hidden SSID not in use
nl80211: privacy=1
nl80211: auth_algs=0x1
nl80211: wpa_version=0x3
nl80211: key_mgmt_suites=0x2
nl80211: pairwise_ciphers=0x18
nl80211: group_cipher=0x8
nl80211: beacon_ies - hexdump(len=10): 7f 08 00 00 00 02 00 00 00 40
nl80211: proberesp_ies - hexdump(len=10): 7f 08 00 00 00 02 00 00 00 40
nl80211: assocresp_ies - hexdump(len=10): 7f 08 00 00 00 02 00 00 00 40
nl80211: Beacon set failed: -16 (Device or resource busy)
Failed to set beacon parameters
sw_ap: Flushing old station entries
nl80211: flush -> DEL_STATION sw_ap (all)
sw_ap: Deauthenticate all stations
nl80211: send_mlme - da= ff:ff:ff:ff:ff:ff noack=0 freq=0 no_cck=0 
offchanok=0 wait_time=0 fc=0xc0 (WLAN_FC_STYPE_DEAUTH) nlmode=3
nl80211: send_mlme -> send_frame
nl80211: send_frame - Use bss->freq=2412
nl80211: send_frame -> send_frame_cmd
nl80211: Frame command failed: ret=-16 (Device or resource busy) 
(freq=2412 wait=0)
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=0 set_tx=0 seq_len=0 key_len=0
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=1 set_tx=0 seq_len=0 key_len=0
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=2 set_tx=0 seq_len=0 key_len=0
wpa_driver_nl80211_set_key: ifindex=13 (sw_ap) alg=0 addr=(nil) 
key_idx=3 set_tx=0 seq_len=0 key_len=0
hostapd_free_hapd_data(sw_ap)
Interface initialization failed
sw_ap: interface state UNINITIALIZED->DISABLED
sw_ap: AP-DISABLED
sw_ap: Unable to setup interface.
hostapd_interface_deinit_free(0x55de0fb263c0)
hostapd_interface_deinit_free: num_bss=1 conf->num_bss=1
hostapd_interface_deinit(0x55de0fb263c0)
hostapd_bss_deinit: deinit bss sw_ap
sw_ap: Deauthenticate all stations
nl80211: send_mlme - da= ff:ff:ff:ff:ff:ff noack=0 freq=0 no_cck=0 
offchanok=0 wait_time=0 fc=0xc0 (WLAN_FC_STYPE_DEAUTH) nlmode=3
nl80211: send_mlme -> send_frame
nl80211: send_frame - Use bss->freq=2412
nl80211: send_frame -> send_frame_cmd
nl80211: Frame command failed: ret=-16 (Device or resource busy) 
(freq=2412 wait=0)
hostapd_cleanup(hapd=0x55de0fb276f0 (sw_ap))
hostapd_free_hapd_data: Interface sw_ap wasn't started
hostapd_interface_deinit_free: driver=0x55de0e2459e0 
drv_priv=0x55de0fb285a0 -> hapd_deinit
nl80211: Remove monitor interface: refcount=0
nl80211: Remove beacon (ifindex=13)
netlink: Operstate: ifindex=13 linkmode=0 (kernel-control), operstate=6 
(IF_OPER_UP)
nl80211: Unsubscribe mgmt frames handle 0x8888dd56873ae509 (deinit)
hostapd_interface_free(0x55de0fb263c0)
hostapd_interface_free: free hapd 0x55de0fb276f0
hostapd_cleanup_iface(0x55de0fb263c0)
hostapd_cleanup_iface_partial(0x55de0fb263c0)
hostapd_cleanup_iface: free iface=0x55de0fb263c0




More information about the Hostap mailing list