This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 176270 - dhclient disallows default routers with octets of 255 in their IP address
dhclient disallows default routers with octets of 255 in their IP address
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: dhcp (Show other bugs)
4
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jason Vas Dias
:
: 176390 (view as bug list)
Depends On:
Blocks: 176285
  Show dependency treegraph
 
Reported: 2005-12-20 13:48 EST by Jason Vas Dias
Modified: 2007-11-30 17:11 EST (History)
2 users (show)

See Also:
Fixed In Version: dhclient-3.0.2-28.FC4
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-05-01 13:16:09 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Jason Vas Dias 2005-12-20 13:48:17 EST
Initially raised as an addendum to bug 149780:

Comment #24 From Panu Matilainen (pmatilai@laiskiainen.org) 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@laiskiainen.org) 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@laiskiainen.org) 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 13:50:28 EST
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 14:35:45 EST
Now fixed with dhcp-3.0.2-28.FC4 / dhcp-3.0.3-18 (FC5) .
Comment 3 Fedora Update System 2005-12-20 15:21:32 EST
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 16:08:06 EST
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-21 20:46:08 EST
*** Bug 176390 has been marked as a duplicate of this bug. ***
Comment 6 Fedora Update System 2006-01-09 13:58:35 EST
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.