
Estou tentando compartilhar minha rede wireless ( wlan0
) e sigo este tutorial:https://linuxalfi.wordpress.com/2011/11/08/connectify-for-linux-with-single-wireless-interface/
O problema é: se o hostapd foi iniciado, não poderei me conectar à rede usando wpa_supplicant. Por outro lado, se eu estiver conectado à rede, não consigo iniciar o hostapd. Esses dois hostapd e wpa_supplicant não podem ser iniciados completamente.
Aqui estão os erros quando tento iniciar o hostapd:
root@me:~# hostapd /etc/hostapd.conf Configuration file: /etc/hostapd.conf Using interface new1 with hwaddr 84:4b:f5:4c:89:ab and ssid "Linux-Hotspot" Failed to set beacon parameters new1: Unable to setup interface.
Se o hostapd foi iniciado, esses erros serão gerados se eu usar o wpa_supplicant:
Successfully initialized wpa_supplicant new0: CTRL-EVENT-SCAN-STARTED new0: SME: Trying to authenticate with ac:86:74:26:54:72 (SSID='Ktx My Dinh' freq=2432 MHz) new0: SME: Authentication request to the driver failed new0: CTRL-EVENT-SCAN-STARTED
E aqui estáiw list
root@me:~$ sudo 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) Device supports RSN-IBSS. Device supports AP-side u-APSD. Device supports T-DLS. Supported Ciphers: * WEP40 (00-0f-ac:1) * WEP104 (00-0f-ac:5) * TKIP (00-0f-ac:2) * CCMP (00-0f-ac:4) * CMAC (00-0f-ac:6) Available Antennas: TX 0x1 RX 0x3 Configured Antennas: TX 0x1 RX 0x3 Supported interface modes: * IBSS * managed * AP * AP/VLAN * WDS * monitor * mesh point * P2P-client * P2P-GO
O que posso fazer para corrigir isso? Desde já, obrigado.
Responder1
Verifique a parte inferior da saída da lista iw para algo assim:
valid interface combinations:
* #{ managed } <= 1, #{ P2P-device } <= 1, #{ P2P-client, P2P-GO } <= 1,
total <= 3, #channels <= 2
* #{ managed } <= 1, #{ AP } <= 1, #{ P2P-client } <= 1, #{ P2P-device } <= 1,
total <= 4, #channels <= 1
(Isso é o que meu Raspberry Pi 3 mostra para wlan0.) Observe que o dispositivo suporta apenas um único canal entre as duas interfaces (gerenciada e AP).
Tente alterar seu hostapd.conf para que o canal especificado corresponda ao da rede na qual você está tentando ingressar.