Cannot start hostapd with usb wifi on ubuntu server 16.04.3 - addendum: iw list

Dexter Filmore Dexter.Filmore at gmx.de
Wed Jan 10 14:02:33 PST 2018


Addendum: iw list for D-Link device

I don't see "AP" in the capabilities list - another unsuitable wifi device?

# iw list
Wiphy phy0
	max # scan SSIDs: 4
	max scan IEs length: 2257 bytes
	Retry short limit: 7
	Retry long limit: 4
	Coverage class: 0 (up to 0m)
	Supported Ciphers:
		* WEP40 (00-0f-ac:1)
		* WEP104 (00-0f-ac:5)
		* TKIP (00-0f-ac:2)
		* CCMP (00-0f-ac:4)
		* 00-0f-ac:10
		* GCMP (00-0f-ac:8)
		* 00-0f-ac:9
	Available Antennas: TX 0 RX 0
	Supported interface modes:
		 * managed
		 * monitor
	Band 1:
		Capabilities: 0x17e
			HT20/HT40
			SM Power Save disabled
			RX Greenfield
			RX HT20 SGI
			RX HT40 SGI
			RX STBC 1-stream
			Max AMSDU length: 3839 bytes
			No DSSS/CCK HT40
		Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
		Minimum RX AMPDU time spacing: 2 usec (0x04)
		HT TX/RX MCS rate indexes supported: 0-7, 32
		Bitrates (non-HT):
			* 1.0 Mbps (short preamble supported)
			* 2.0 Mbps (short preamble supported)
			* 5.5 Mbps (short preamble supported)
			* 11.0 Mbps (short preamble supported)
			* 6.0 Mbps
			* 9.0 Mbps
			* 12.0 Mbps
			* 18.0 Mbps
			* 24.0 Mbps
			* 36.0 Mbps
			* 48.0 Mbps
			* 54.0 Mbps
		Frequencies:
			* 2412 MHz [1] (20.0 dBm)
			* 2417 MHz [2] (20.0 dBm)
			* 2422 MHz [3] (20.0 dBm)
			* 2427 MHz [4] (20.0 dBm)
			* 2432 MHz [5] (20.0 dBm)
			* 2437 MHz [6] (20.0 dBm)
			* 2442 MHz [7] (20.0 dBm)
			* 2447 MHz [8] (20.0 dBm)
			* 2452 MHz [9] (20.0 dBm)
			* 2457 MHz [10] (20.0 dBm)
			* 2462 MHz [11] (20.0 dBm)
			* 2467 MHz [12] (20.0 dBm) (no IR)
			* 2472 MHz [13] (20.0 dBm) (no IR)
	Supported commands:
		 * new_interface
		 * set_interface
		 * new_key
		 * start_ap
		 * new_station
		 * new_mpath
		 * set_mesh_config
		 * set_bss
		 * authenticate
		 * associate
		 * deauthenticate
		 * disassociate
		 * join_ibss
		 * join_mesh
		 * set_tx_bitrate_mask
		 * frame
		 * frame_wait_cancel
		 * set_wiphy_netns
		 * set_channel
		 * set_wds_peer
		 * probe_client
		 * set_noack_map
		 * register_beacons
		 * start_p2p_device
		 * set_mcast_rate
		 * connect
		 * disconnect
		 * Unknown command (104)
	Supported TX frame types:
		 * IBSS: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 
0xd0 0xe0 0xf0
		 * managed: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 
0xd0 0xe0 0xf0
		 * AP: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 0xd0 
0xe0 0xf0
		 * AP/VLAN: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 
0xd0 0xe0 0xf0
		 * mesh point: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 
0xc0 0xd0 0xe0 0xf0
		 * P2P-client: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 
0xc0 0xd0 0xe0 0xf0
		 * P2P-GO: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 0xc0 
0xd0 0xe0 0xf0
		 * P2P-device: 0x00 0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80 0x90 0xa0 0xb0 
0xc0 0xd0 0xe0 0xf0
	Supported RX frame types:
		 * IBSS: 0x40 0xb0 0xc0 0xd0
		 * managed: 0x40 0xd0
		 * AP: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
		 * AP/VLAN: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
		 * mesh point: 0xb0 0xc0 0xd0
		 * P2P-client: 0x40 0xd0
		 * P2P-GO: 0x00 0x20 0x40 0xa0 0xb0 0xc0 0xd0
		 * P2P-device: 0x40 0xd0
	software interface modes (can always be added):
		 * monitor
	interface combinations are not supported
	HT Capability overrides:
		 * MCS: ff ff ff ff ff ff ff ff ff ff
		 * maximum A-MSDU length
		 * supported channel width
		 * short GI for 40 MHz
		 * max A-MPDU length exponent
		 * min MPDU start spacing
	Device supports TX status socket option.
	Device supports HT-IBSS.
	Device supports SAE with AUTHENTICATE command
	Device supports low priority scan.
	Device supports scan flush.
	Device supports AP scan.
	Device supports per-vif TX power setting
	Driver supports full state transitions for AP/GO clients
	Driver supports a userspace MPM
	Device supports active monitor (which will ACK incoming frames)




On Wednesday 10 January 2018 22:59:33 Dexter Filmore wrote:
> Hi all,
>
> installed minimal ubuntu server 16.04.3 LTS, started off with some Realtek
> 8192 device which I then learned was not too good anyway, so today switched
> it for a
> D-Link DWA-127 v2 , USB ID 2001:3d04
>
> with module:
>
> # lsmod | grep 802
> mac80211              782336  1 mt7601u
> cfg80211              602112  2 mac80211,mt7601u
>
> and hostapd 2.4 from the ubuntu repos.
>
> I modified a sample conf following howtos to this:
>
> ==hostapd.conf===============================
> interface=wlxc8d3a304236d
> driver=nl80211
> ssid=glotzklotz
> channel=1
> ignore_broadcast_ssid=0
> country_code=DE
> ieee80211d=1
> hw_mode=g
> ieee80211n=1
> ht_capab=[HT40+][SHORT-GI-40][DSSS_CCK-40]
> beacon_int=100
> dtim_period=2
> macaddr_acl=0
> max_num_sta=20
> rts_threshold=2347
> fragm_threshold=2346
> logger_syslog=-1
> logger_syslog_level=0
> logger_stdout=-1
> logger_stdout_level=0
> dump_file=/tmp/hostapd.dump
> ctrl_interface=/var/run/hostapd
> ctrl_interface_group=0
> auth_algs=3
> wmm_enabled=1
> wpa=2
> rsn_preauth=1
> rsn_preauth_interfaces=wlan0
> wpa_key_mgmt=WPA-PSK
> rsn_pairwise=CCMP
> wpa_group_rekey=600
> wpa_ptk_rekey=600
> wpa_gmk_rekey=86400
> wpa_passphrase= [...]
> ==/hostapd.conf===============================
>
> and called ifup for this /etc/network/interfaces :
>
> #dlink dwa-127 v2
> iface wlxc8d3a304236d inet static
> address 192.168.1.1
> netmask 255.255.255.0
>
> (no wpasupplicant installed, I was told that's only needed when acting as a
> client. correct?)
>
> When I call hostapd, I get:
>
> # hostapd -dd /etc/hostapd.conf
> random: Trying to read entropy from /dev/random
> Configuration file: /etc/hostapd.conf
> Line 50: DEPRECATED: 'dump_file' configuration variable is not used anymore
> ctrl_interface_group=0
> rfkill: initial event: idx=0 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 wlxc8d3a304236d in phy phy0
> nl80211: Set mode ifindex 3 iftype 3 (AP)
> nl80211: Failed to set interface 3 to mode 3: -95 (Operation not supported)
> nl80211: Try mode change after setting interface down
> nl80211: Set mode ifindex 3 iftype 3 (AP)
> nl80211: Failed to set interface 3 to mode 3: -95 (Operation not supported)
> nl80211: Interface mode change to 3 from 0 failed
> nl80211: Could not configure driver mode
> nl80211: deinit ifname=wlxc8d3a304236d disabled_11b_rates=0
> nl80211: Remove monitor interface: refcount=0
> netlink: Operstate: ifindex=3 linkmode=0 (kernel-control), operstate=6
> (IF_OPER_UP)
> nl80211: Set mode ifindex 3 iftype 2 (STATION)
> nl80211 driver initialization failed.
> hostapd_interface_deinit_free(0x564406a01710)
> hostapd_interface_deinit_free: num_bss=1 conf->num_bss=1
> hostapd_interface_deinit(0x564406a01710)
> wlxc8d3a304236d: interface state UNINITIALIZED->DISABLED
> hostapd_bss_deinit: deinit bss wlxc8d3a304236d
> wlxc8d3a304236d: AP-DISABLED
> hostapd_cleanup(hapd=0x564406a02900 (wlxc8d3a304236d))
> hostapd_free_hapd_data: Interface wlxc8d3a304236d wasn't started
> hostapd_interface_deinit_free: driver=(nil) drv_priv=(nil) -> hapd_deinit
> hostapd_interface_free(0x564406a01710)
> hostapd_interface_free: free hapd 0x564406a02900
> hostapd_cleanup_iface(0x564406a01710)
> hostapd_cleanup_iface_partial(0x564406a01710)
> hostapd_cleanup_iface: free iface=0x564406a01710
>
> AP/routing is not a field I roam a lot so expect me to have made newbie
> mistakes.
> Pointers appreciated.


-- 
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GCS d--(+)@ s-:+ a C++++ UL++ P+>++ L+++>++++ E-- W++ N o? K-
w--(---) !O M+ V- PS+ PE Y++ PGP t++(---)@ 5 X+(++) R+(++) tv--(+)@ 
b++(+++) DI+++ D- G++ e* h>++ r* y?
------END GEEK CODE BLOCK------



More information about the Hostap mailing list