Bug 176270 - dhclient disallows default routers with octets of 255 in their IP address
Summary: dhclient disallows default routers with octets of 255 in their IP address
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: dhcp
Version: 4
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jason Vas Dias
QA Contact:
URL:
Whiteboard:
: 176390 (view as bug list)
Depends On:
Blocks: 176285
TreeView+ depends on / blocked
 
Reported: 2005-12-20 18:48 UTC by Jason Vas Dias
Modified: 2007-11-30 22:11 UTC (History)
2 users (show)

Fixed In Version: dhclient-3.0.2-28.FC4
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-05-01 17:16:09 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Jason Vas Dias 2005-12-20 18:48:17 UTC
Initially raised as an addendum to bug 149780:

Comment #24 From Panu Matilainen (pmatilai) 2005-12-20 11:27 EST

Hmph, after updating to dhclient-3.0.2-26.FC4 I no longer get a default route
with FC4 either unless I manually add GATEWAY=<ip> to the configuration, same as
FC5test1 in comment #22 :(

Comment #26 From Panu Matilainen (pmatilai) 2005-12-20 12:34 EST
[root@weasel ~]# cat /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=localhost.localdomain
[root@weasel ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
BOOTPROTO=dhcp
HWADDR=00:11:D8:8D:C4:53
ONBOOT=yes
TYPE=Ethernet
-> no gateway settings

[root@weasel ~]# grep unreachable /var/log/messages*
-> nothing there

[root@weasel ~]# /sbin/ip route
192.168.255.0/24 dev eth0  proto kernel  scope link  src 192.168.255.3
169.254.0.0/16 dev eth0  scope link
-> no default route

[root@weasel ~]# cat /var/lib/dhcp/dhclient-eth0.leases
lease {
  interface "eth0";
  fixed-address 192.168.255.3;
  server-name "";
  option subnet-mask 255.255.255.0;
  option routers 192.168.255.1;
  option dhcp-lease-time 259200;
  option dhcp-message-type 5;
  option domain-name-servers 192.168.255.1;
  option dhcp-server-identifier 192.168.255.1;
  option dhcp-renewal-time 129600;
  option dhcp-rebinding-time 226800;
  option host-name "dhcppc1";
  renew 4 2005/12/22 04:00:09;
  rebind 5 2005/12/23 08:33:18;
  expire 5 2005/12/23 17:33:18;
}
lease {
  interface "eth0";
  fixed-address 192.168.255.3;
  server-name "";
  option subnet-mask 255.255.255.0;
  option dhcp-lease-time 259200;
  option routers 192.168.255.1;
  option dhcp-message-type 5;
  option dhcp-server-identifier 192.168.255.1;
  option domain-name-servers 192.168.255.1;
  option dhcp-renewal-time 129600;
  option dhcp-rebinding-time 226800;
  option host-name "dhcppc1";
  renew 3 2005/12/21 22:15:30;
  rebind 5 2005/12/23 08:34:27;
  expire 5 2005/12/23 17:34:27;
}
[root@weasel ~]#

-> seems ok to me. In any case that used to work just fine with dhclient prior
to this update. 

Like I said, I need to *add* the supposedly forbidden GATEWAY entry to make it
work again:
[root@weasel ~]# echo GATEWAY=192.168.255.1 >> /etc/sysconfig/network
[root@weasel ~]# /sbin/ifdown eth0
[root@weasel ~]# /sbin/ifup eth0

Determining IP information for eth0... done.
[root@weasel ~]# /sbin/ip route
192.168.255.0/24 dev eth0  proto kernel  scope link  src 192.168.255.3
169.254.0.0/16 dev eth0  scope link
default via 192.168.255.1 dev eth0


Comment #27 From Panu Matilainen (pmatilai) 2005-12-20 12:41 EST

Oh, in case you wonder about the "weasel" hostname: I had that as hostname set
in /etc/sysconfig/network when booting but removed it to see if it (being
unresolvable outside /etc/hosts) made any difference - it didn't.

Comment 1 Jason Vas Dias 2005-12-20 18:50:28 UTC
Aha! I see the problem now.  
Your router is on the broadcast subnet '192.168.255', and the dhclient-script
was rather crudely testing for this, @ line 278:
		for router in $new_routers; do
		    if [ -z "$router" ] || [ `IFS=. ip2num $router` -le 0 ] || [[ $router =
*255* ]] || [[ "${default_routers[@]}" == *"$router"* ]]; then
			continue;
		    fi;

I was trying to weed out routers that might be set to broadcast addresses; 
linux does not like having a broadcast address as the default router.

I see the above is a bit too draconian a way of doing this.

I'm now fixing this with dhcp-3.0.2-28.FC4 / dhcp-3.0.3-18 .




Comment 2 Jason Vas Dias 2005-12-20 19:35:45 UTC
Now fixed with dhcp-3.0.2-28.FC4 / dhcp-3.0.3-18 (FC5) .

Comment 3 Fedora Update System 2005-12-20 20:21:32 UTC
From User-Agent: XML-RPC

dhcp-3.0.2-28.FC4 has been pushed for FC4, which should resolve this issue.  If these problems are still present in this version, then please make note of it in this bug report.

Comment 4 Panu Matilainen 2005-12-20 21:08:06 UTC
Confirmed, with dhclient-3.0.2-28.FC4 the default route is back without any
GATEWAY-settings. Thanks for the very fast fix :)

Comment 5 Jason Vas Dias 2005-12-22 01:46:08 UTC
*** Bug 176390 has been marked as a duplicate of this bug. ***

Comment 6 Fedora Update System 2006-01-09 18:58:35 UTC
From User-Agent: XML-RPC

dhcp-3.0.2-28.FC4 has been pushed for FC4, which should resolve this issue.  If these problems are still present in this version, then please make note of it in this bug report.


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