Netzwerk Wireless (Raspbian): Unterschied zwischen den Versionen

Aus Tutorials
Zur Navigation springen Zur Suche springen
Zeile 42: Zeile 42:


== Debian 12 (Bookworm) ==
== Debian 12 (Bookworm) ==
<pre>
sudo nmcli -p connection show
</pre>
<pre>
======================================
  NetworkManager connection profiles
======================================
NAME                UUID                                  TYPE      DEVICE
------------------------------------------------------------------------------------------------------------------
Wired connection 1  77fd4154-01ba-34f6-8cdd-8c41861be1b5  ethernet  eth0
lo                  7b859bf0-ea5e-41b0-81b6-26e784212883  loopback  lo
preconfigured      c62a713f-df8d-43b3-8a22-20f08064775e  wifi      wlan0
</pre>


<pre>
<pre>

Version vom 8. März 2024, 02:26 Uhr

Mehrere Netzwerke einrichten

/etc/dhcpcd.conf

sudo vi /etc/dhcpcd.conf
interface wlan0
arping 10.0.0.1
arping 10.3.0.1

profile 10.0.0.1
static ip_address=10.0.0.180/24
static routers=10.0.0.1
static domain_name_servers=8.8.8.8 8.8.4.4

profile 10.3.0.1
static ip_address=10.3.0.180/24
static routers=10.3.0.1
static domain_name_servers=8.8.8.8 8.8.4.4

/etc/wpa_supplicant/wpa_supplicant.conf

sudo vi /etc/wpa_supplicant/wpa_supplicant.conf
network={
        ssid="<ssid 1>"
        psk="<password>"
}

network={
        ssid="<ssid 2>"
        psk="<password>"
}

Debian 12 (Bookworm)

sudo nmcli -p connection show
======================================
  NetworkManager connection profiles
======================================
NAME                UUID                                  TYPE      DEVICE
------------------------------------------------------------------------------------------------------------------
Wired connection 1  77fd4154-01ba-34f6-8cdd-8c41861be1b5  ethernet  eth0
lo                  7b859bf0-ea5e-41b0-81b6-26e784212883  loopback  lo
preconfigured       c62a713f-df8d-43b3-8a22-20f08064775e  wifi      wlan0
sudo nmcli c mod "preconfigured" ipv4.addresses 10.0.0.173/24 ipv4.method manual
sudo nmcli con mod "preconfigured" ipv4.gateway 10.0.0.1
sudo nmcli con mod "preconfigured" ipv4.dns 10.0.0.156,10.0.0.157

https://www.abelectronics.co.uk/kb/article/31/set-a-static-ip-address-on-raspberry-pi-os-bookworm

Debian 9 (Stretch)

In der Datei /etc/dhcpcd.conf

sudo vi /etc/dhcpcd.conf

folgende Zeilen einkommentieren und anpassen:

interface wlan0
static ip_address=10.2.0.99/24
static routers=10.2.0.138
static domain_name_servers=10.2.0.138 8.8.8.8

Debian 8 (Jessie)

Nur interfaces-Datei

In der Datei /etc/network/interfaces folgende Zeilen hinzufügen / anpassen:

auto wlan0
allow-hotplug wlan0
iface wlan0 inet static
address <static ip>
netmask 255.255.255.0
gateway <gateway ip>
dns-nameservers <nameserver ip>

wpa-ap-scan 1
wpa-scan-ssid 1

wpa-ssid "<ssid>"
wpa-psk "<password>"

Dateien interfaces und wpa_supplicant.conf

Datei /etc/wpa_supplicant/wpa_supplicant.conf:

country=AT
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1

network={
        ssid="<ssid>"
        psk="<password>"
}

Datei /etc/network/interfaces:

source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback

# WLAN
auto  wlan0
allow-hotplug wlan0
iface wlan0 inet manual
        wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

bzw. mit statischer IP-Addresse:

source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback

iface eth0 inet manual

allow-hotplug wlan0
iface wlan0 inet static
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
    address 10.0.0.98
    netmask 255.255.255.0
    gateway 10.0.0.138
    dns-nameservers 10.0.0.138

2 Wifi-Verbindungen konfigurieren

Mehrere Wifi-Verbindungen konfigurieren

Programme

Firefox => Iceweasel

Energiesparmodus deaktivieren

Edimax EW-7811un

Datei 8192cu.conf anlegen:

sudo nano /etc/modprobe.d/8192cu.conf

Folgenden Inhalt einfügen:

options 8192cu rtw_power_mgnt=0 rtw_enusbss=0

Cronjob anlegen

sudo nano /etc/crontab
*/1 * * * * ping -c 1 10.0.0.138

Links

http://linux.die.net/man/5/wpa_supplicant.conf

http://www.freebsd.org/cgi/man.cgi?wpa_supplicant.conf%285%29

https://developer-blog.net/raspberry-pi-problem-mit-wlan-stick-edimax-ew-7811un/


Zurück zu Raspbian