Skip to contentSkip to conversation

b43 AP does not work

DISCUSSION Nerijus Baliūnas 3 participants 15 messages May 2, 2015 – May 4, 2015

lore
Share & tools
lore
#0 lore raw

Hello,

lspci:
02:00.0 Network controller [0280]: Broadcom Corporation BCM4311 802.11a/b/g [14e4:4312] (rev 02)

AP worked on F21. On F22 kernels 4.0.0 and 4.0.1 it does not.

# hostapd -dB /etc/hostapd/hostapd.conf
random: Trying to read entropy from /dev/random
Configuration file: /etc/hostapd/hostapd.conf
ctrl_interface_group=10 (from group name 'wheel')
rfkill: initial event: idx=0 type=2 op=0 soft=1 hard=0
rfkill: initial event: idx=1 type=1 op=0 soft=0 hard=0
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: Using driver-based off-channel TX
nl80211: interface wlan0 in phy phy0
nl80211: Set mode ifindex 3 iftype 3 (AP)
nl80211: Failed to set interface 3 to mode 3: -16 (Device or resource busy)
nl80211: Try mode change after setting interface down
nl80211: Set mode ifindex 3 iftype 3 (AP)
nl80211: Mode change succeeded while interface is down
nl80211: Setup AP(wlan0) - device_ap_sme=0 use_monitor=0
nl80211: Subscribe to mgmt frames with AP handle 0x86c16f0
nl80211: Register frame type=0xb0 (WLAN_FC_STYPE_AUTH) nl_handle=0x86c16f0
match=
nl80211: Register frame type=0x0 (WLAN_FC_STYPE_ASSOC_REQ)
nl_handle=0x86c16f0 match=
nl80211: Register frame type=0x20 (WLAN_FC_STYPE_REASSOC_REQ)
nl_handle=0x86c16f0 match=
nl80211: Register frame type=0xa0 (WLAN_FC_STYPE_DISASSOC)
nl_handle=0x86c16f0 match=
nl80211: Register frame type=0xc0 (WLAN_FC_STYPE_DEAUTH) nl_handle=0x86c16f0
match=
nl80211: Register frame type=0xd0 (WLAN_FC_STYPE_ACTION) nl_handle=0x86c16f0
match=
nl80211: Register frame command failed (type=208): 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=3)
netlink: Operstate: ifindex=3 linkmode=0 (kernel-control), operstate=6
(IF_OPER_UP)
nl80211: Set mode ifindex 3 iftype 2 (STATION)
nl80211: Failed to set interface 3 to mode 2: -16 (Device or resource busy)
nl80211: Try mode change after setting interface down
nl80211: Set mode ifindex 3 iftype 2 (STATION)
nl80211: Mode change succeeded while interface is down
nl80211: Teardown AP(wlan0) - device_ap_sme=0 use_monitor=0
nl80211 driver initialization failed.
hostapd_interface_deinit_free(0x86bf2a0)
hostapd_interface_deinit_free: num_bss=1 conf->num_bss=1
hostapd_interface_deinit(0x86bf2a0)
hostapd_bss_deinit: deinit bss wlan0
hostapd_cleanup(hapd=0x86c0cd0 (wlan0))
hostapd_free_hapd_data: Interface wlan0 wasn't started
hostapd_interface_deinit_free: driver=(nil) drv_priv=(nil) -> hapd_deinit
hostapd_interface_free(0x86bf2a0)
hostapd_interface_free: free hapd 0x86c0cd0
hostapd_cleanup_iface(0x86bf2a0)
hostapd_cleanup_iface_partial(0x86bf2a0)
hostapd_cleanup_iface: free iface=0x86bf2a0

Regards,
Nerijus

#1 lore raw
Quoted 61 lines · Nerijus Baliūnas

Hello,

lspci:
02:00.0 Network controller [0280]: Broadcom Corporation BCM4311 802.11a/b/g [14e4:4312] (rev 02)

AP worked on F21. On F22 kernels 4.0.0 and 4.0.1 it does not.

# hostapd -dB /etc/hostapd/hostapd.conf
random: Trying to read entropy from /dev/random
Configuration file: /etc/hostapd/hostapd.conf
ctrl_interface_group=10 (from group name 'wheel')
rfkill: initial event: idx=0 type=2 op=0 soft=1 hard=0
rfkill: initial event: idx=1 type=1 op=0 soft=0 hard=0
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: Using driver-based off-channel TX
nl80211: interface wlan0 in phy phy0
nl80211: Set mode ifindex 3 iftype 3 (AP)
nl80211: Failed to set interface 3 to mode 3: -16 (Device or resource busy)
nl80211: Try mode change after setting interface down
nl80211: Set mode ifindex 3 iftype 3 (AP)
nl80211: Mode change succeeded while interface is down
nl80211: Setup AP(wlan0) - device_ap_sme=0 use_monitor=0
nl80211: Subscribe to mgmt frames with AP handle 0x86c16f0
nl80211: Register frame type=0xb0 (WLAN_FC_STYPE_AUTH) nl_handle=0x86c16f0
match=
nl80211: Register frame type=0x0 (WLAN_FC_STYPE_ASSOC_REQ)
nl_handle=0x86c16f0 match=
nl80211: Register frame type=0x20 (WLAN_FC_STYPE_REASSOC_REQ)
nl_handle=0x86c16f0 match=
nl80211: Register frame type=0xa0 (WLAN_FC_STYPE_DISASSOC)
nl_handle=0x86c16f0 match=
nl80211: Register frame type=0xc0 (WLAN_FC_STYPE_DEAUTH) nl_handle=0x86c16f0
match=
nl80211: Register frame type=0xd0 (WLAN_FC_STYPE_ACTION) nl_handle=0x86c16f0
match=
nl80211: Register frame command failed (type=208): 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=3)
netlink: Operstate: ifindex=3 linkmode=0 (kernel-control), operstate=6
(IF_OPER_UP)
nl80211: Set mode ifindex 3 iftype 2 (STATION)
nl80211: Failed to set interface 3 to mode 2: -16 (Device or resource busy)
nl80211: Try mode change after setting interface down
nl80211: Set mode ifindex 3 iftype 2 (STATION)
nl80211: Mode change succeeded while interface is down
nl80211: Teardown AP(wlan0) - device_ap_sme=0 use_monitor=0
nl80211 driver initialization failed.
hostapd_interface_deinit_free(0x86bf2a0)
hostapd_interface_deinit_free: num_bss=1 conf->num_bss=1
hostapd_interface_deinit(0x86bf2a0)
hostapd_bss_deinit: deinit bss wlan0
Quoted 8 lines
hostapd_cleanup(hapd=0x86c0cd0 (wlan0))
hostapd_free_hapd_data: Interface wlan0 wasn't started
hostapd_interface_deinit_free: driver=(nil) drv_priv=(nil) -> hapd_deinit
hostapd_interface_free(0x86bf2a0)
hostapd_interface_free: free hapd 0x86c0cd0
hostapd_cleanup_iface(0x86bf2a0)
hostapd_cleanup_iface_partial(0x86bf2a0)
hostapd_cleanup_iface: free iface=0x86bf2a0

A resource busy error from nl80211 usually means that NetworkManager is controlling the interface. Are you using NM? If so, have you tried setting up an AP using the "access point" mode of the NM applet. That is a lot easier than using hostapd, and has the additional advantage of being able to use wireless cards for both the WAN and LAN sides of the AP.

Larry

#2 lore raw
Quoted 2 lines · Larry Finger

A resource busy error from nl80211 usually means that NetworkManager is controlling the interface. Are you using NM? If so, have you tried setting

up an

Quoted 3 lines

AP using the "access point" mode of the NM applet. That is a lot easier than using hostapd, and has the additional advantage of being able to use wireless cards for both the WAN and LAN sides of the AP.

IIRC I used "access point" mode of the NM applet and it worked, but now I cannot find such option (at least in MATE). Is it somehow possible to still use hostapd manually?

Thanks,
Nerijus

#3 lore raw

TmVyaWp1cyBCYWxpxatuYXMgPG5lcmlqdXNALi4uPiB3cml0ZXM6Cgo+IElJUkMgSSB1c2VkICJhY2Nlc3MgcG9pbnQiIG1vZGUgb2YgdGhlIE5NIGFwcGxldCBhbmQgaXQgd29ya2VkLCBidXQgbm93IEkKPiBjYW5ub3QgZmluZCBzdWNoIG9wdGlvbiAoYXQgbGVhc3QgaW4gTUFURSkuIElzIGl0IHNvbWVob3cgcG9zc2libGUgdG8gc3RpbGwKPiB1c2UgaG9zdGFwZCBtYW51YWxseT8KCkp1c3QgRllJIC0gImFjY2VzcyBwb2ludCIgbW9kZSBvZiB0aGUgTk0gYXBwbGV0IHdvcmtzIChpbiBHbm9tZSkuIEJ1dCBpdAp3b3VsZCBzdGlsbCBiZSBuaWNlIHRvIGhhdmUgaG9zdGFwZCB3b3JraW5nLg==

#4 lore raw
Quoted 8 lines · Nerijus Baliūnas
Quoted 3 lines · Nerijus Baliūnas

IIRC I used "access point" mode of the NM applet and it worked, but now I cannot find such option (at least in MATE). Is it somehow possible to still use hostapd manually?

Just FYI - "access point" mode of the NM applet works (in Gnome). But it
would still be nice to have hostapd working.N�����r��y���b�X��ǧv�^�)޺{.n�+����{��*ޕ�,�{ay�ʇڙ�,j��f���h���z��w��� ���j:+v���w�j�m��������zZ+�����ݢj"��!tml=

Then turn off NM.

#5 lore raw
In reply to Nerijus Baliūnas
Quoted 8 lines · Nerijus Baliūnas
Quoted 3 lines · Nerijus Baliūnas

IIRC I used "access point" mode of the NM applet and it worked, but now I cannot find such option (at least in MATE). Is it somehow possible to still use hostapd manually?

Just FYI - "access point" mode of the NM applet works (in Gnome). But it would still be nice to have hostapd working.NrybXǧv^)޺{.n+{*ޕ,{ayʇڙ,jfhzw j:+vwjmzZ+ݢj"!

If you want to use hostapd on the card and the system is running NetworkManager, you can tell NM to ignore the device through the "unmanaged-devices" option in NetworkManager.conf. manpages have more details.

Dan

#6 lore raw
Quoted 7 lines · Dan Williams
Quoted 2 lines

Just FYI - "access point" mode of the NM applet works (in Gnome). But it would still be nice to have hostapd working.

If you want to use hostapd on the card and the system is running NetworkManager, you can tell NM to ignore the device through the "unmanaged-devices" option in NetworkManager.conf. manpages have more details.

But I don't want NM to ignore the device - I use the wifi card with NM as a client. But sometimes I'd like to use hostapd directly (as NM does not allow me to configure AP parameters - channel, wpa number, AP name and password). It was possible before, but not any more.

Thanks,
Nerijus

#7 lore raw
Quoted 10 lines · Nerijus Baliūnas
Quoted 7 lines · Dan Williams
Quoted 2 lines

Just FYI - "access point" mode of the NM applet works (in Gnome). But it would still be nice to have hostapd working.

If you want to use hostapd on the card and the system is running NetworkManager, you can tell NM to ignore the device through the "unmanaged-devices" option in NetworkManager.conf. manpages have more details.

Quoted 4 lines

But I don't want NM to ignore the device - I use the wifi card with NM as a client. But sometimes I'd like to use hostapd directly (as NM does not allow me to configure AP parameters - channel, wpa number, AP name and password). It was possible before, but not any more.

That is an applet problem. I use openSUSE 13.2 with a KDE desktop, and the Connection Manager lets me specify everything in your list but perhaps the WPA level, but why would you want to use anything less secure than WPA2?

You need to complain to your distro if they have a regression in the NM applet.

Larry

#8 lore raw
Quoted 7 lines · Larry Finger
Quoted 4 lines

But I don't want NM to ignore the device - I use the wifi card with NM as a client. But sometimes I'd like to use hostapd directly (as NM does not allow me to configure AP parameters - channel, wpa number, AP name and password). It was possible before, but not any more.

That is an applet problem. I use openSUSE 13.2 with a KDE desktop, and the Connection Manager lets me specify everything in your list but perhaps the

WPA

Quoted 3 lines

level, but why would you want to use anything less secure than WPA2?

You need to complain to your distro if they have a regression in the NM

applet.

It's Gnome, they don't let users to configure :( But thanks, next time I will know that KDE applet is better.
Does anyone know why it was possible before? Is it NM or hostapd regression?

#9 lore raw
In reply to Nerijus Baliūnas
Quoted 10 lines · Nerijus Baliūnas
Quoted 7 lines · Dan Williams
Quoted 2 lines

Just FYI - "access point" mode of the NM applet works (in Gnome). But it would still be nice to have hostapd working.

If you want to use hostapd on the card and the system is running NetworkManager, you can tell NM to ignore the device through the "unmanaged-devices" option in NetworkManager.conf. manpages have more details.

Quoted 4 lines

But I don't want NM to ignore the device - I use the wifi card with NM as a client. But sometimes I'd like to use hostapd directly (as NM does not allow me to configure AP parameters - channel, wpa number, AP name and password). It was possible before, but not any more.

NM actually does allow you to do that by editing the hotspot connection files directly. The various UIs (nm-applet, GNOME Shell, etc) may or may not expose specific knobs like these. We intend to add AP mode support to nm-connection-editor, but there are some complications around valid options in AP mode that need to be addressed in the editor UI first.

If you take a look into /etc/NetworkManager/system-connections/ you should see the config file, where you can edit stuff like 'channel', 'ssid', 'band', 'pairwise', 'group', 'proto', etc, stuff that's familiar to wpa_supplicant config too. See 'man nm-settings' for more details on all these key/value pairs.

Dan

#10 lore raw
Quoted 8 lines · Dan Williams

NM actually does allow you to do that by editing the hotspot connection files directly.

If you take a look into /etc/NetworkManager/system-connections/ you should see the config file, where you can edit stuff like 'channel', 'ssid', 'band', 'pairwise', 'group', 'proto', etc, stuff that's familiar to wpa_supplicant config too. See 'man nm-settings' for more details on all these key/value pairs.

I edited /etc/NetworkManager/system-connections/Hotspot, ran systemctl restart NetworkManager and ssid and password were changed. Then I added channel=10 to the file, restarted NM, but when I enable hotspot in Gnome, ssid is localhost.localdomain and password is random again. I was not able to have my edited ssid and password values back.

#11 lore raw
Quoted 11 lines · Nerijus Baliūnas
Quoted 8 lines · Dan Williams

NM actually does allow you to do that by editing the hotspot connection files directly.

If you take a look into /etc/NetworkManager/system-connections/ you should see the config file, where you can edit stuff like 'channel', 'ssid', 'band', 'pairwise', 'group', 'proto', etc, stuff that's familiar to wpa_supplicant config too. See 'man nm-settings' for more details on all these key/value pairs.

Quoted 5 lines

I edited /etc/NetworkManager/system-connections/Hotspot, ran systemctl restart NetworkManager and ssid and password were changed. Then I added channel=10 to the file, restarted NM, but when I enable hotspot in Gnome, ssid is localhost.localdomain and password is random again. I was not able to have my edited ssid and password values back.

You don't actually need to restart NM, you can simply run "nmcli con reload" to get NM to notice the changes. I don't recall how GNOME Shell handles the Hotspot button in its UI, but you should be able to test independently of GNOME Shell by doing:

nmcli con up <name of hotspot connection>

Dan

#12 lore raw
Quoted 6 lines · Dan Williams
Quoted 5 lines

I edited /etc/NetworkManager/system-connections/Hotspot, ran systemctl restart NetworkManager and ssid and password were changed. Then I added channel=10 to the file, restarted NM, but when I enable hotspot in Gnome, ssid is localhost.localdomain and password is random again. I was not able to have my edited ssid and password values back.

Quoted 6 lines

You don't actually need to restart NM, you can simply run "nmcli con reload" to get NM to notice the changes. I don't recall how GNOME Shell handles the Hotspot button in its UI, but you should be able to test independently of GNOME Shell by doing:

nmcli con up <name of hotspot connection>

I did
nmcli con reload
nmcli con up Hotspot

but it still used localhost.localdomain as ssid, although I have ssid=something in /etc/NetworkManager/system-connections/Hotspot

#13 lore raw
Quoted 13 lines · Nerijus Baliūnas
Quoted 11 lines · Dan Williams
Quoted 5 lines

I edited /etc/NetworkManager/system-connections/Hotspot, ran systemctl restart NetworkManager and ssid and password were changed. Then I added channel=10 to the file, restarted NM, but when I enable hotspot in Gnome, ssid is localhost.localdomain and password is random again. I was not able to have my edited ssid and password values back.

You don't actually need to restart NM, you can simply run "nmcli con reload" to get NM to notice the changes. I don't recall how GNOME Shell handles the Hotspot button in its UI, but you should be able to test independently of GNOME Shell by doing:

Quoted 8 lines
Quoted 1 line

nmcli con up <name of hotspot connection>

I did
nmcli con reload
nmcli con up Hotspot

but it still used localhost.localdomain as ssid, although I have ssid=something in /etc/NetworkManager/system-connections/Hotspot

If you run "nmcli con", is there more than one connection called "Hotspot"? If not, then run "nmcli con Hotspot" and lets see what it prints out.

Dan

#14 lore raw
Quoted 10 lines · Dan Williams
Quoted 6 lines

I did
nmcli con reload
nmcli con up Hotspot

but it still used localhost.localdomain as ssid, although I have ssid=something in /etc/NetworkManager/system-connections/Hotspot

If you run "nmcli con", is there more than one connection called "Hotspot"? If not, then run "nmcli con Hotspot" and lets see what it prints out.

Yes, there are 2 Hotspots. After I deleted one with nm-connection-editor the ssid is OK.