sebastien35 Posted January 1, 2016 Posted January 1, 2016 Hello , I have setup a banana pi with armbian: Linux bananapi 4.3.3-sunxi #3 SMP Mon Dec 28 11:27:16 CET 2015 armv7l GNU/Linux I wuld like to setup a wifi access point from a rtl wifi dongle. Realtek Semiconductor Corp. RTL8192CU 802.11n WLAN Adapter First, I have tried with bananian and it was working perfectly. But I have also a tv adapter not working with bananian, kernel 3.4 seems not support it. With armbian vanilla, the tv adapter is supported but it seems to have an issue with the wifi dongle driver. When I start hostapd-rt, I have the following errors: drv->ifindex=5 l2_sock_recv==l2_sock_xmit=0x0x766b0 ioctl[SIOCSIWMODE]: Invalid argument Could not set interface to mode(3)! Could not set interface to master mode! rtl871xdrv driver initialization failed. wlan0: interface state UNINITIALIZED->DISABLED wlan0: AP-DISABLED hostapd_free_hapd_data: Interface wlan0 wasn't started Do you have already ssen this issue? I have seen that it is possible to build a driver provided by realtek. Do you think it culd solve it? I could try it but I need help how to do it. I supose I need to follow this page: http://www.armbian.com/using-armbian-tools/and include the realtek driver? Thank you
Igor Posted January 1, 2016 Posted January 1, 2016 Have you try to use a normal hostapd ? (non realtek version) You don't need to compile kernel if you are asking that ...
sebastien35 Posted January 1, 2016 Author Posted January 1, 2016 I have also errors: hostapd: root@bananapi:~# hostapd /etc/hostapd/hostapd.conf Configuration file: /etc/hostapd/hostapd.conf drv->ifindex=5 l2_sock_recv==l2_sock_xmit=0x0x62638 ioctl[SIOCSIWMODE]: Invalid argument Could not set interface to mode(3)! Could not set interface to master mode! rtl871xdrv driver initialization failed. hostapd-rt: root@bananapi:~# hostapd-rt /etc/hostapd/hostapd.conf Configuration file: /etc/hostapd/hostapd.conf drv->ifindex=5 l2_sock_recv==l2_sock_xmit=0x0x766b0 ioctl[SIOCSIWMODE]: Invalid argument Could not set interface to mode(3)! Could not set interface to master mode! rtl871xdrv driver initialization failed. wlan0: interface state UNINITIALIZED->DISABLED wlan0: AP-DISABLED hostapd_free_hapd_data: Interface wlan0 wasn't started
Igor Posted January 1, 2016 Posted January 1, 2016 http://www.armbian.com/documentation/ How to set wireless access point?
sebastien35 Posted January 2, 2016 Author Posted January 2, 2016 I confirm I have same issue if I follow the doc http://www.armbian.com/documentation/
Igor Posted January 2, 2016 Posted January 2, 2016 OK. If you tried both options, than the the problem could be in wifi driver. This chipset is know to be troublesome ... I have no information which driver is working well in kernel 4.3.3 ... I assume you use the driver supplied with kernel. Blacklist the one from kernel and try those two: https://github.com/dz0ny/rt8192cu https://github.com/pvaret/rtl8192cu-fixes
sebastien35 Posted January 3, 2016 Author Posted January 3, 2016 Ok, for this step, think I ned your help I have an error when I try to compile https://github.com/dz0ny/rt8192cu. root@bananapi:~/rt8192cu# make make ARCH=arm CROSS_COMPILE= -C /lib/modules/4.3.3-sunxi/build M=/root/rt8192cu modules make[1]: Entering directory '/usr/src/linux-headers-4.3.3-sunxi' CC [M] /root/rt8192cu/core/rtw_cmd.o /bin/sh: 1: scripts/basic/fixdep: not found scripts/Makefile.build:258: recipe for target '/root/rt8192cu/core/rtw_cmd.o' failed make[2]: *** [/root/rt8192cu/core/rtw_cmd.o] Error 127 Makefile:1378: recipe for target '_module_/root/rt8192cu' failed make[1]: *** [_module_/root/rt8192cu] Error 2 make[1]: Leaving directory '/usr/src/linux-headers-4.3.3-sunxi' Makefile:584: recipe for target 'modules' failed
Igor Posted January 3, 2016 Posted January 3, 2016 cd /usr/src/linux-headers-4.3.3-sunxi make scripts Than repeat the compilation.
sebastien35 Posted January 3, 2016 Author Posted January 3, 2016 Now hostapd succed to start but it is not possible to connect on the access point. I have the folowing logs, if you have an idea: drv->ifindex=5 l2_sock_recv==l2_sock_xmit=0x0x766b0 +rtl871x_sta_deauth_ops, ff:ff:ff:ff:ff:ff is deauth, reason=2 rtl871x_set_key_ops rtl871x_set_key_ops rtl871x_set_key_ops rtl871x_set_key_ops Using interface wlan0 with hwaddr 10:fe:ed:17:28:2d and ssid "sgillard" rtl871x_set_wps_assoc_resp_ie rtl871x_set_wps_beacon_ie rtl871x_set_wps_probe_resp_ie random: Only 17/20 bytes of strong random data available from /dev/random random: Not enough entropy pool available for secure operations WPA: Not enough entropy in random pool for secure operations - update keys later when the first station connects rtl871x_set_beacon_ops rtl871x_set_hidden_ssid_ops ioctl[RTL_IOCTL_HOSTAPD]: Invalid argument rtl871x_set_key_ops wlan0: interface state UNINITIALIZED->ENABLED wlan0: AP-ENABLED +rtl871x_get_sta_wpaie, d0:e7:82:49:32:af is sta's address wlan0: STA d0:e7:82:49:32:af IEEE 802.11: associated rtl871x_set_key_ops rtl871x_set_key_ops rtl871x_set_key_ops +rtl871x_send_eapol +rtl871x_send_eapol wlan0: STA d0:e7:82:49:32:af WPA: received EAPOL-Key msg 2/4 in invalid state (10) - dropped +rtl871x_send_eapol wlan0: STA d0:e7:82:49:32:af WPA: received EAPOL-Key msg 2/4 in invalid state (10) - dropped +rtl871x_send_eapol wlan0: STA d0:e7:82:49:32:af WPA: received EAPOL-Key msg 2/4 in invalid state (10) - dropped +rtl871x_send_eapol wlan0: STA d0:e7:82:49:32:af IEEE 802.11: disassociated rtl871x_set_key_ops rtl871x_set_key_ops +rtl871x_sta_remove_ops, d0:e7:82:49:32:af is sta address removed +rtl871x_get_sta_wpaie, d0:e7:82:49:32:af is sta's address wlan0: STA d0:e7:82:49:32:af IEEE 802.11: associated
Igor Posted January 3, 2016 Posted January 3, 2016 Those drivers are buggy ... try setting up without WPA and make sure you use this config for interfaces: https://github.com/igorpecovnik/lib/blob/master/config/interfaces.hostapd Bridge mode is default, so your clients gets an IP from your router.
sebastien35 Posted January 3, 2016 Author Posted January 3, 2016 I have tried with bridge mode and without authentication. My android fail to connect and I have no traces in syslog or hostapd output. Does exist a way to try with a kernel 3.18 for example?
Igor Posted January 3, 2016 Posted January 3, 2016 Try to shape hostap config and perhaps try other instructions/options/hostapd: https://bogeskov.dk/UsbAccessPoint.html https://www.google.si/search?q=rtl8192cu+raspberry+pi+access+point&oq=rtl8192cu+raspberry+pi Hostapd itself also have a lot of options and this latest might simply not working with this device. 1
sebastien35 Posted January 3, 2016 Author Posted January 3, 2016 Ok I will try but same hostapd.conf with same dongle works with bananian and on a raspberry/raspbian
Igor Posted January 3, 2016 Posted January 3, 2016 Try different hostapd version since driver is most likely the same (one from the kernel and the one you compiled).
Recommended Posts