Bug 42559 - dhcpcd problem with kernel 2.4.2
dhcpcd problem with kernel 2.4.2
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: dhcpcd (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Elliot Lee
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-05-28 06:39 EDT by ben.de.rydt
Modified: 2008-05-01 11:38 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2001-10-11 18:51:07 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
bound a datagram socket to port 68 to prevent icmp-error (1.89 KB, patch)
2001-09-02 20:31 EDT, Olivier Baudron
no flags Details | Diff

  None (edit)
Description ben.de.rydt 2001-05-28 06:39:20 EDT
Description of Problem:

I find this in /var/log/messages of my dhcp-server (RedHat 6.2)

May 27 20:40:39 neb dhcpd: DHCPREQUEST for 192.168.1.3 from 
00:10:5a:71:6b:c4 via eth0
May 27 20:40:39 neb dhcpd: DHCPACK on 192.168.1.3 to 00:10:5a:71:6b:c4 
via eth0
May 27 20:40:39 neb dhcpd: fallback_discard: Connection refused

Running tcpdump on my dhcp-server:

192.168.1.1: tcpdump -i eth0 -n '(icmp or (udp port 67 or 68))'
===============================================================

20:40:39.104524 < 192.168.1.3.bootpc > 192.168.1.1.bootps: xid:0x7b520505 
secs:3 C:192.168.1.3 [|bootp]
20:40:39.106236 > 192.168.1.1.bootps > 192.168.1.3.bootpc: xid:0x7b520505 
secs:3 C:192.168.1.3 Y:192.168.1.3 S:192.168.1.1 ether 0:10:5a:71:6b:c4 
[|bootp]
20:40:39.106576 < 192.168.1.3 > 192.168.1.1: icmp: 192.168.1.3 udp port 
bootpc unreachable (DF) [tos 0xc0]

But when I run tcpdump on the client (RedHat 7.1, kernel 2.4.2-2):

192.168.1.3: tcpdump -i eth0 -n -p '(icmp or (udp port 67 or 68))'
===============================================================

20:28:48.453032 < 192.168.1.1.bootps > 192.168.1.3.bootpc: xid:0xdd351577 
secs:3 C:192.168.1.3 Y:192.168.1.3 S:192.168.1.1 ether 0:10:5a:71:6b:c4 
[|bootp]
20:28:48.453032 > 192.168.1.3 > 192.168.1.1: icmp: 192.168.1.3 udp port 
bootpc unreachable (DF) [tos 0xc0]
20:33:48.453032 < 192.168.1.1.bootps > 192.168.1.3.bootpc: xid:0x7b520505 
secs:3 C:192.168.1.3 Y:192.168.1.3 S:192.168.1.1 ether 0:10:5a:71:6b:c4 
[|bootp]
20:33:48.453032 > 192.168.1.3 > 192.168.1.1: icmp: 192.168.1.3 udp port 
bootpc unreachable (DF) [tos 0xc0]

[ 2 dhcp-transactions, second is the one corresponding to the   
192.168.1.1-tcpdump. The clocks are not syncronized. The client 
(192.168.1.3) never sees the first packet 192.168.1.3 -> 192.168.1.1 of 
the transaction, although it arrives at 192.168.1.1 (I don't know why).]

pump works, but doesn't understand some dhcp-options.
Comment 1 Olivier Baudron 2001-09-01 15:44:55 EDT
Can you try with a 2.4.9 kernel on the client side?
Comment 2 Olivier Baudron 2001-09-01 18:11:31 EDT
Btw, I was wondering if we could bind a datagram socket to the local udp port
68, in addition to the raw socket that is being used. Indeed, the problem with a
raw socket is that a copy of the datas also go through the udp/ip stack. And at
this point if no datagram socket is bound, the kernel considers that the udp
packet has no reachable destination, and may emit an icmp message error
(depending on the kernel version). So, adding a datagram socket would resolve
this issue. Can someone give me an advice?
Comment 3 ben.de.rydt 2001-09-02 12:05:03 EDT
I'm very sorry that I didn't close this bug:
the problem was a stray static route, on 192.168.1.3:
route net 192.186.1.0/24 gw 192.168.1.1

I only saw this after two weeks. I still do not understand why tcpdump didn't 
see all packets leaving, but the dhcpcd problem is over.
Comment 4 Olivier Baudron 2001-09-02 12:38:18 EDT
Can you tell me if you still see icmp port unreachable messages or not?
Comment 5 ben.de.rydt 2001-09-02 16:23:38 EDT
No, no icmp-errors anymore.
Comment 6 Olivier Baudron 2001-09-02 16:34:47 EDT
Well... if I disable iptables rules, I can see these icmp on my linux box
(dhcpcd-1.3.18pl8-10 + kernel 2.4.9). So???
Comment 7 ben.de.rydt 2001-09-02 17:18:30 EDT
You're right, I was still running pump. Time to go to sleep I guess.

The icmp-errors reappear the moment I switch to dhcpcd. FYI, I'm running 
kernel 2.4.9-ac5 and dhcpcd 1.3.20pl0 at the moment (I've been compiling 
various dhcpcd's). The dhpc-server is Debian stable, with the stock Debian 
dhcpd.
Comment 8 Olivier Baudron 2001-09-02 17:26:57 EDT
Indeed, pump uses a datagram socket strategy, so the icmp-error problem is not
present. But pump has much more bug^H^H^Hissues elsewhere ;)
Comment 9 Olivier Baudron 2001-09-02 20:31:20 EDT
Created attachment 30634 [details]
bound a datagram socket to port 68 to prevent icmp-error
Comment 10 Olivier Baudron 2001-09-02 20:36:02 EDT
The above patch is against dhcpcd-1.3.20-pl0.
Can you give it a try?
Comment 11 ben.de.rydt 2001-09-03 06:59:20 EDT
The patch works.

Comment 12 Olivier Baudron 2001-10-11 18:51:02 EDT
Now included in dhcpcd-1.3.20pl1.
Comment 13 Elliot Lee 2001-12-28 13:55:38 EST
I have put dhcpcd-1.3.21pl0 into rawhide. This should make everyone happy.

Note You need to log in before you can comment on or make changes to this bug.