Netzwerk

IP Adressen festlegen & dynamisch beziehen

in der Datei /etc/network/interfaces

# File for ifup, ifdown

auto lo
iface lo inet loopback

allow-hotplug eth0
iface eth0 inet dhcp

allow-hotplug eth1
iface eth1 inet static
    address 192.168.0.2
    netmask 255.255.255.0
    network 192.168.0.0
    broadcast 192.168.0.255
    gateway 192.168.0.1
    dns-nameservers 192.168.0.1

allow-hotplug & auto in der /etc/network/interfaces

Lines beginning with the word "auto" are used to identify the physical interfaces to be brought up 
when ifup is run with the -a option. (This option is used by the system boot scripts.) 
Physical interface names should follow the word "auto" on the same line. 
There can be multiple "auto" stanzas. ifup brings the named interfaces up in the order listed.

Lines beginning with "allow-" are used to identify interfaces that should be brought up automatically 
by various subsytems. This may be done using a command such as "ifup --allow=hotplug eth0 eth1", 
which will only bring up eth0 or eth1 if it is listed in an "allow-hotplug" line. Note that "allow-auto" 
and "auto" are synonyms.

SMB Freigaben im Netzwerk auf der Konsole anzeigen

smbclient --list 192.168.0.x -U username -P password

Netzwerkkonfiguration für Interface einstellen

Interface eth0 IP Adresse vergeben:

ifconfig eth0 192.168.0.2 netmask 255.255.255.0 broadcast 192.168.0.255 up

Standardroute setzen:

route add default gw 192.168.0.1

Nameserver in /etc/resolv.conf:

nameserver 192.168.0.1

Traffic Shaping

Unter “traffic shaping“ versteht man die Begrenzung bzw. das Einteilen vorhandener Kapazitäten zur Qualitätssicherung (siehe auch QoS).

Mit wondershaper hängt man der Datei /etc/network/interfaces (Befehl sudo pico /etc/network/interfaces) beim gewünschten Interface (hier eth0) die beiden Zeilen

up /sbin/wondershaper eth0 3000 350
down /sbin/wondershaper clear eth0

an. 

3000 ist hier die Downloadgeschwindigkeit (in Kbit/s) und 350 die Upload-Geschwindigkeit.

Cookie Consent mit Real Cookie Banner