[Eisfair_dev] E1 - DHCPD Paket Fehler

Holger Bruenjes holgerbruenjes at gmx.net
So Apr 20 22:53:37 CEST 2014


Hallo Marcus

Am 2014-04-20 22:39, schrieb Marcus Roeckrath:

> Anderer Devicename aber beide male Devices ohne Netmask, beide male stolpert
> dann die gleiche Zeile in der inetlib.

Nein, so einfach ist das nicht ;-) , die Netmask ist auch immer
vorhanden, nur an einer anderen Stelle


Bei Stefan Welte

gibt eth0 und eth0:1


ip bindet das alles an eth0

eis2113:/ # ip -f inet addr show eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
state UP qlen 1000
    inet 192.168.2.221/24 brd 192.168.2.255 scope global eth0
    inet 192.168.2.222/16 brd 192.168.255.255 scope global eth0:1



ip -f inet addr show eth0 |  grep "inet[[:blank:]]" | tr -s ' ' |
cut -d ' ' -f3  | cut -d/ -f2
24
16

damit habe ich 2 Werte

das muss nun aufgesplittet werden

eis2113:/ # ip -f inet addr show eth0 |  grep "inet[[:blank:]]" |
grep eth0$ | tr -s ' ' | cut -d ' ' -f3  | cut -d/ -f2
24

eis2113:/ # ip -f inet addr show eth0 |  grep "inet[[:blank:]]" |
grep eth0:1$ | tr -s ' ' | cut -d ' ' -f3  | cut -d/ -f2
16

Dann klappt das.


Benjamin hat tun0

da haengt die Netmask am 2. Wert

 3: tun0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1400 qdisc
pfifo_fast state UNKNOWN qlen 100
    inet 10.10.10.1 peer 10.10.10.2/32 scope global tun0


Bei ifconfig hing die Netmask immer an Mask: , das ist bei ip nun
doch mehr anders als erwartet.

Holger




Mehr Informationen über die Mailingliste Eisfair_dev