====== WLAN einrichten ====== Pakete installieren apt-get install rfkill apt-get install wireless-tools apt-get install wpasupplicant ===== rfkill ===== Mit ''rfkill'' kann man softwareseitig Wireless-Device ein und ausschalten. # rfkill list 0: hci0: Bluetooth Soft blocked: no Hard blocked: no 1: phy0: Wireless LAN Soft blocked: no Hard blocked: no 2: tpacpi_bluetooth_sw: Bluetooth Soft blocked: no Hard blocked: no 3: tpacpi_wwan_sw: Wireless WAN Soft blocked: no Hard blocked: no rfkill block wlan rfkill block bluetooth rfkill block wwan ===== wireless-tools ===== Enthält programme zur wireless Einrichtung ==== iwconfig ==== # iwconfig lo no wireless extensions. usb0 no wireless extensions. wlan0 IEEE 802.11abgn ESSID:"WLAN-BD6B04" Mode:Managed Frequency:2.432 GHz Access Point: 7C:4F:B5:BD:6B:29 Bit Rate=180 Mb/s Tx-Power=15 dBm Retry long limit:7 RTS thr:off Fragment thr:off Encryption key:off Power Management:off Link Quality=70/70 Signal level=-36 dBm Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0 Tx excessive retries:0 Invalid misc:8 Missed beacon:0 eth0 no wireless extensions. Erst das Interface up nehmem ifconfig wlan0 up ip link set wlan0 up ip a -> alle Interfaces anzeigen ==== iwlist ==== WLAN-Netz abscannen. iwlist wlan0 scan ===== wpasupplicant ===== Sind tools zum Verbindungsaufbau mit WPA/WPA2 Verschlüsselung. Zum Verbindungsaufbau mit WLAN sollte das physikalische NIC down gesetzt werden: ifdown eth0 wpa_passphrase > /root/wpa.conf wpa_supplicant -B -i wlan0 -c /root/wpa.conf Eine IP-Adresse über dhcp beziehen: dhclient -v wlan0 ===== WLAN in /etc/network/interfaces ===== In /etc/network/interfaces kann auch das WLAN-NIC konfiguriert werden. Dazu sollte ein key generiert werden wpa_passphrase network={ ssid="Router-SSID" #psk="password" psk=key } iface wlan0 inet static address netmask network broadcast gateway dns-nameservers dns-search wpa-ssid wpa-psk Da in /etc/network/interfaces der key enthalten ist: chmod 600 /etc/network/interfaces === Mehrere WLAN-Netze === Wenn man zwischen verschiedenen WLAN-Netzen wechseln will, dann alle in /etc/network/interfaces mit einem alias eintragen: iface wlan0-home inet dhcp wpa-ssid wpa-psk home-key iface wlan0-work inet dhcp wpa-ssid wpa-psk work-key Verbindung aufbauen: ifup wlan0=wlan0-home ifup wlan0=wlan0-WORK