Re: Doch nicht Gelöst:Dhcp-Probleme
Am Dienstag, 15. November 2011 schrieb Siegfrid Brandstätter:
> Hallo,
>
> Am Dienstag, 15. November 2011 schrieb Rainer Altvater:
> > Guten Morgen ;)
> >
> > Siegfrid Brandstätter <garafrut@web.de> wrote:
> > >> Es ist etwas erstaunlich, dass dhclient bei dir so kurz nach
> > >> einem DHCPACK schon wieder mit DHCPDISCOVER anfängt...bei der
> > >> eingestellten Lease-Time solltest du da länger Ruhe haben.
> > >> Schau mal bitte unter /var/lib/dhcp nach der aktuellen
> > >> dhclient.lease (es dürfte mehrere in dem Verzeichnis geben, du
> > >> musst aufs Datum schauen). Und dann poste doch mal, was darin
> > >> steht...
> > >
> > > lease {
> > >
> > > interface "eth0";
> > > fixed-address 192.168.1.35;
> > > option subnet-mask 255.255.255.0;
> > > option dhcp-lease-time 259200;
> > > option routers 192.168.1.1;
> > > option dhcp-message-type 5;
> > > option dhcp-server-identifier 192.168.1.1;
> > > option domain-name-servers 80.58.61.250,80.58.61.254;
> > > option dhcp-renewal-time 129600;
> > > option dhcp-rebinding-time 226800;
> > > option host-name "dhcppc2";
> > > renew 1 2011/11/14 06:58:30;
> > > rebind 2 2011/11/15 16:16:30;
> > > expire 3 2011/11/16 01:16:30;
> > >
> > > }
> > > lease {
> > >
> > > interface "eth0";
> > > fixed-address 192.168.1.34;
> > > option subnet-mask 255.255.255.0;
> > > option dhcp-lease-time 259200;
> > > option routers 192.168.1.1;
> > > option dhcp-message-type 5;
> > > option dhcp-server-identifier 192.168.1.1;
> > > option domain-name-servers 80.58.61.250,80.58.61.254;
> > > option dhcp-renewal-time 129600;
> > > option dhcp-rebinding-time 226800;
> > > option host-name "dhcppc1";
> > > renew 0 2011/11/13 02:16:56;
> > > rebind 1 2011/11/14 09:02:46;
> > > expire 1 2011/11/14 18:02:46;
> > >
> > > }
> > > lease {
> > >
> > > interface "eth0";
> > > fixed-address 192.168.1.33;
> > > option subnet-mask 255.255.255.0;
> > > option routers 192.168.1.1;
> > > option dhcp-lease-time 259200;
> > > option dhcp-message-type 5;
> > > option domain-name-servers 80.58.61.250,80.58.61.254;
> > > option dhcp-server-identifier 192.168.1.1;
> > > option dhcp-renewal-time 129600;
> > > option dhcp-rebinding-time 226800;
> > > option host-name "dhcppc0";
> > > renew 2 2011/11/15 20:15:05;
> > > rebind 4 2011/11/17 04:03:39;
> > > expire 4 2011/11/17 13:03:39;
> > >
> > > }
> > > lease {
> > >
> > > interface "eth0";
> > > fixed-address 192.168.1.33;
> > > option subnet-mask 255.255.255.0;
> > > option dhcp-lease-time 259200;
> > > option routers 192.168.1.1;
> > > option dhcp-message-type 5;
> > > option dhcp-server-identifier 192.168.1.1;
> > > option domain-name-servers 80.58.61.250,80.58.61.254;
> > > option dhcp-renewal-time 129600;
> > > option dhcp-rebinding-time 226800;
> > > option host-name "dhcppc0";
> > > renew 2 2011/11/15 20:08:19;
> > > rebind 4 2011/11/17 04:11:38;
> > > expire 4 2011/11/17 13:11:38;
> > >
> > > }
> >
> > Das sind alles gültige Einträge...der dhclient verarbeitet die
> > Antworten des Servers also richtig. Das der Client trotz gültiger
> > Lease direkt wieder mit DHCPDISCOVER beginnt, ist
> > unverständlich...normalerweise sollte er das erst tun, wenn seine
> > Lease abgelaufen ist und er seine IP-Information verworfen hat. Und
> > selbst dann fragt er beim ersten neuen Discover seine letzte
> > gültige IP an. Solange die Lease noch gültig ist, solltest du in
> > den Logs nur DHCPREQUEST sehen.
> >
> > >> Kannst du auf deinem Router (oder was auch immer deinen
> > >> DHCP-Server zur Verfügung stellt) in den Logs auch etwas sehen?
> > >
> > > Wo könnte ich die finden, unter /var/log ist nichts.
> >
> > Nun, ich weiß ja nicht, was für einen Router du hast...bei mir kann
> > ich da per Weboberfläche nachschauen.
>
> ZyXEL-P660HW-D1
>
> > Evtl. musst du das Logging
> > auch erst einschalten. Du kannst auch mal versuchen, als root per
> > tcpdump Infos zu bekommen, indem du mal ein "tcpdump -v portrange
> > 67-68 | tee dhcp.log" laufen lässt. Damit bekommst du alle Anfragen
> > an und die entsprechenden Antworten des DHCP-Servers. So häufig,
> > wie das bei dir auftritt, solltest du das nur wenige Minuten
> > laufen lassen müssen, um erste Ergebnisse zu sehen.
>
> Also heute läuft es mal ohne Probleme daher findet es auch nichts,
> ist ca. 20Minuten gelaufen.
>
> # tcpdump -v portrange 67-68 | tee
> tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size
> 65535 bytes
> ^C0 packets captured
> 0 packets received by filter
> 0 packets dropped by kernel
>
Heute hat es geklappt, nach dem 4. PC starten, keine Internet
Verbindung. Aufruf von : # tcpdump -v portrange 67-68 | tee
danach "dhclien eth0" und es begann aufzuzeichnen.
Aber die Verbindung ist diesmal nicht abgebrochen, wie sonst wenn sie
manuell aufgerufen wurde.
# tcpdump -v portrange 67-68 | tee
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size
65535 bytes
12:22:37.968556 IP (tos 0x10, ttl 128, id 0, offset 0, flags [none],
proto UDP (17), length 328)
0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from
aa:00:04:00:0a:04 (oui Unknown), length 300, xid 0x80fcb34e, Flags
[none]
Client-Ethernet-Address aa:00:04:00:0a:04 (oui Unknown)
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Request
Requested-IP Option 50, length 4: testing.local
Parameter-Request Option 55, length 13:
Subnet-Mask, BR, Time-Zone, Default-Gateway
Domain-Name, Domain-Name-Server, Option 119, Hostname
Netbios-Name-Server, Netbios-Scope, MTU, Classless-Static-
Route
NTP
12:22:37.969915 IP (tos 0x0, ttl 255, id 367, offset 0, flags [none],
proto UDP (17), length 328)
192.168.1.1.bootps > testing.local.bootpc: BOOTP/DHCP, Reply, length
300, xid 0x80fcb34e, Flags [none]
Your-IP testing.local
Server-IP 192.168.1.1
Client-Ethernet-Address aa:00:04:00:0a:04 (oui Unknown)
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: ACK
Subnet-Mask Option 1, length 4: 255.255.255.0
Default-Gateway Option 3, length 4: 192.168.1.1
Domain-Name-Server Option 6, length 8:
250.Red-80-58-61.staticIP.rima-tde.net,254.Red-80-58-61.staticIP.rima-
tde.net
Hostname Option 12, length 7: "dhcppc0"
RN Option 58, length 4: 129600
RB Option 59, length 4: 226800
Lease-Time Option 51, length 4: 259200
Server-ID Option 54, length 4: 192.168.1.1
12:24:10.041958 IP (tos 0x10, ttl 128, id 0, offset 0, flags [none],
proto UDP (17), length 328)
0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from
00:25:22:ca:45:f1 (oui Unknown), length 300, xid 0xd222a067, Flags
[none]
Client-Ethernet-Address 00:25:22:ca:45:f1 (oui Unknown)
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Discover
Parameter-Request Option 55, length 13:
Subnet-Mask, BR, Time-Zone, Default-Gateway
Domain-Name, Domain-Name-Server, Option 119, Hostname
Netbios-Name-Server, Netbios-Scope, MTU, Classless-Static-
Route
NTP
12:24:10.043330 IP (tos 0x0, ttl 255, id 381, offset 0, flags [none],
proto UDP (17), length 328)
192.168.1.1.bootps > testing.local.bootpc: BOOTP/DHCP, Reply, length
300, xid 0xd222a067, Flags [none]
Your-IP testing.local
Server-IP 192.168.1.1
Client-Ethernet-Address 00:25:22:ca:45:f1 (oui Unknown)
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Offer
Subnet-Mask Option 1, length 4: 255.255.255.0
Default-Gateway Option 3, length 4: 192.168.1.1
Domain-Name-Server Option 6, length 8:
250.Red-80-58-61.staticIP.rima-tde.net,254.Red-80-58-61.staticIP.rima-
tde.net
Hostname Option 12, length 7: "dhcppc1"
RN Option 58, length 4: 129600
RB Option 59, length 4: 226800
Lease-Time Option 51, length 4: 259200
Server-ID Option 54, length 4: 192.168.1.1
12:24:10.043415 IP (tos 0x10, ttl 128, id 0, offset 0, flags [none],
proto UDP (17), length 328)
0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from
00:25:22:ca:45:f1 (oui Unknown), length 300, xid 0xd222a067, Flags
[none]
Client-Ethernet-Address 00:25:22:ca:45:f1 (oui Unknown)
Vendor-rfc1048 Extensions
Magic Cookie 0x63825363
DHCP-Message Option 53, length 1: Request
Server-ID Option 54, length 4: 192.168.1.1
Requested-IP Option 50, length 4: testing.local
Parameter-Request Option 55, length 13:
Subnet-Mask, BR, Time-Zone, Default-Gateway
Domain-Name, Domain-Name-Server, Option 119, Hostname
Netbios-Name-Server, Netbios-Scope, MTU, Classless-Static-
Route
NTP
12:24:10.047822 IP (tos 0x0, ttl 255, id 382, offset 0, flags [none],
proto UDP (17), length 328)
192.168.1.1.bootps > testing.local.bootpc: BOOTP/DHCP, Reply, length
300, xid 0xd222a067, Flags [none]
Your-IP testing.local
Server-IP 192.168.1.1
Client-Ethernet-Address 00:25:22:ca:45:f1 (oui^C9 packets
captured
9 packets received by filter
0 packets dropped by kernel
> > >> Wenn ja, wäre
> > >> das auch mal interessant. Eigentlich sollte der Server auf das
> > >> erneute Discover des Clients ja wieder mit einem Offer
> > >> antworten. Womöglich tut er das auch, aber beim Client kommts
> > >> nicht an. Hast du iptables aktiv?
> > >
> > > Keine Ahnung, wie finde ich dass raus?
> >
> > "iptables -L" als root ausführen.
>
> # iptables -L
> Chain INPUT (policy ACCEPT)
> target prot opt source destination
>
> Chain FORWARD (policy ACCEPT)
> target prot opt source destination
>
> Chain OUTPUT (policy ACCEPT)
> target prot opt source destination
>
>
> Danke nochmal für die Hilfe, vielleicht finden wir ja doch noch was
> da los ist :-)
--
Einen Schönen Gruß,
Sigi
Reply to: