Impossibile aggiungere l'interfaccia wlan1


0

Sto cercando di creare un router WiFi dal dispositivo NanoPi M1 +. Avrà due modalità di lavoro che sono Eth & lt; - & gt; WiFi e WiFi & lt; - & gt; WiFi.

Sono in grado di eseguire perfettamente la prima modalità, ma la seconda modalità in cui il dispositivo deve funzionare come stazione e punto di accesso mi preoccupa.

Il dispositivo NanoPi ha un chipset WiFi integrato e sto utilizzando un adattatore WiFi aggiuntivo per un'altra modalità.

Il problema è che il dispositivo non è in grado di mostrare la seconda interfaccia WLAN. Aggiungendo manualmente un'interfaccia usando iw, si genera un errore.

Ho incluso l'output dei comandi nel seguito.

ifconfig:
eth0      Link encap:Ethernet  HWaddr 02:81:c7:86:31:ec
          inet addr:192.168.55.227  Bcast:192.168.55.255  Mask:255.255.255.0
          inet6 addr: fe80::7f3c:fbbd:4f8a:34b4/64 Scope:Link
          inet6 addr: fc00::74dd:b4f:9f39:8b36/64 Scope:Global
          inet6 addr: fc00::c1ed:d2fc:ae81:f2c0/64 Scope:Global
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4987 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2008 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:3871199 (3.8 MB)  TX bytes:160738 (160.7 KB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:614 errors:0 dropped:0 overruns:0 frame:0
          TX packets:614 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:64279 (64.2 KB)  TX bytes:64279 (64.2 KB)

wlan0     Link encap:Ethernet  HWaddr b0:f1:ec:2c:ea:c6
          inet6 addr: fe80::b2f1:ecff:fe2c:eac6/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:5 errors:0 dropped:1 overruns:0 frame:0
          TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:542 (542.0 B)  TX bytes:1130 (1.1 KB)

L'interfaccia wlan0 dovrebbe funzionare per la modalità Access Point e l'interfaccia wlan1 come una stazione.

/etc/network/interfaces:
# interfaces(5) file used by ifup(8) and ifdown(8)

# Please note that this file is written to be used with dhcpcd
# For static IP, consult /etc/dhcpcd.conf and 'man dhcpcd.conf'

# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback
auto eth0
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet static  
address 172.24.1.1
netmask 255.255.255.0
network 172.24.1.0
broadcast 172.24.1.255

allow-hotplug wlan1
iface wlan1 inet dhcp
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

iface default inet dhcp

file hostapd:

driver=nl80211
ctrl_interface=/var/run/hostapd
ctrl_interface_group=0
beacon_int=100
auth_algs=1
#wpa_key_mgmt=WPA-PSK
ssid=test02c00081c78631ec
channel=7
hw_mode=g
#wpa_passphrase=raspberry
interface=wlan0
#wpa=2
#wpa_pairwise=TKIP
country_code=IN

file dnsmasq.conf:

domain-needed
interface=wlan0
except-interface=lo
dhcp-range=192.168.41.10,192.168.41.150,255.255.255.0,12h
#address=/#/192.168.41.1
#server=/192.168.0.245/8.8.8.8
log-dhcp
log-queries
log-facility=/tmp/dnsmasq.log

Sopra lsusb , mostra la scheda di rete Realtek Semiconductor Corp. RTL8188EUS 802.11n Wireless Network Adapter

Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 020: ID 413c:2113 Dell Computer Corp.
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 002: ID 0bda:8179 Realtek Semiconductor Corp. RTL8188EUS 802.11n Wireless Network Adapter
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Facendo:

iw dev wlan0 interface add wlan1 type station flags none

genera un errore:

command failed: Operation not supported (-95)

Ho aggiunto wlan1 come interfaccia in /etc/udev/rules.d/70-persistent-net.rules file, ma ancora wlan1 non può essere riconosciuto.

SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="C0-25-E9-25-AB-14", NAME=="wlan1"
SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="b0:f1:ec:2c:ea:c6", NAME=="wlan0"

Per favore dimmi cosa mi manca e come posso aggiungere wlan1 come interfaccia?


2
Non sono un esperto di kernel e driver di Linux ma sospetto che non abbiate installato un driver per quel chipset Realtek.
Spiff

Come sopra In Debian o Raspbian è il firmware-realtek pacchetto, penso. Quale sistema operativo esegue il tuo NanoPi?
Kamil Maciorowski

Puoi pubblicare l'output di iw phy?
grawity

@ KamilMaciorowski suo amichevolecore-xenial 4,14
ron123456

@grawity è strano senza uscita di iw PHY né per la mia lista
ron123456
Utilizzando il nostro sito, riconosci di aver letto e compreso le nostre Informativa sui cookie e Informativa sulla privacy.
Licensed under cc by-sa 3.0 with attribution required.