Bug 126058 - Host unreachable after network restart
Summary: Host unreachable after network restart
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dhcp
Version: rawhide
Hardware: athlon
OS: Linux
medium
high
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-06-15 17:01 UTC by Ivan Gyurdiev
Modified: 2007-11-30 22:10 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-06-24 21:13:28 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2004:566 0 normal SHIPPED_LIVE Updated dhcp and dhclient packages 2005-05-26 04:00:00 UTC

Description Ivan Gyurdiev 2004-06-15 17:01:32 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6)
Gecko/20040518 Firefox/0.8

Description of problem:
Ok, I don't know what the problem is. It might not even be a dhcp bug.
However, since dhcp has changed in recent rawhide releases, I suspect
it might be.

Here's the situation - I lose network connectivity after reboot.
I am connected over Ethernet to a Dlink dI-514 wireless router, which
is connected to the Internet via a cable modem. I use static DHCP, and
I assign this computer address 192.168.0.2. After reboot, I can ping
the router, but I can't ping anything else on the Internet. 

When I disable static DHCP on the router, and make it dynamic (and
restart network scripts), my workstation is assigned a different
address and Internet functions properly. Then when I restart again.
it's no longer able to connect. I must switch back to static and it
works until I restart the network card. 

I don't think the problem has to do with static vs dynamic - it seems
to be that it has to do with different addresses. Whenever I obtain a
new address (by enabling or disabling static DHCP), I can connect
until I restart the network again. Then it stops working until I get a
new address by changing DHCP settings in the router.

I realize this isn't very specific. If you tell me how to provide more
info I'd be glad to do so. I typically don't use dhcp directly - only
through the network scripts, but I can test whatever you tell me to.

Version-Release number of selected component (if applicable):
dhcp-3.0.1rc13-1

How reproducible:
Always

Steps to Reproduce:
1. See summary

Additional info:

Comment 1 Daniel Walsh 2004-06-15 17:16:54 UTC
Could you get the previous version and install it and see if the
problem goes away.

The following is the latest patch that was applied.

--- dhcp-3.0.1rc12/client/scripts/linux.inherit-leases	2004-06-10
13:08:54.816030416 -0400
+++ dhcp-3.0.1rc12/client/scripts/linux	2004-06-10 13:18:39.232185656
-0400
@@ -123,16 +123,18 @@
     # Bring down alias interface. Its routes will disappear too.
     ifconfig $interface:0- inet 0
   fi
-  if [ $relmajor -lt 2 ] || ( [ $relmajor -eq 2 ] && [ $relminor -eq
0 ] )
-   then
+  if [ x$keep_old_ip == xyes ]; then
+    ifconfig $interface up
+  elif [ $relmajor -lt 2 ] || ( [ $relmajor -eq 2 ] && [ $relminor
-eq 0 ] )   then
     ifconfig $interface inet 0.0.0.0 netmask 0.0.0.0 \
 		broadcast 255.255.255.255 up
-    # Add route to make broadcast work. Do not omit netmask.
-    route add default dev $interface netmask 0.0.0.0
   else
     ifconfig $interface 0 up
   fi
 
+  # Add route to make broadcast work. Do not omit netmask.
+  route add default dev $interface netmask 0.0.0.0
+
   # We need to give the kernel some time to get the interface up.
   sleep 1
 
--- dhcp-3.0.1rc12/client/dhclient.c.inherit-leases	2004-06-10
13:08:54.709046680 -0400
+++ dhcp-3.0.1rc12/client/dhclient.c	2004-06-10 13:08:54.891019016 -0400
@@ -387,6 +387,16 @@
 				continue;
 			script_init (ip -> client,
 				     "PREINIT", (struct string_list *)0);
+			if (/* Has an active lease */
+			    ip -> client -> active &&
+			    !ip -> client -> active -> is_bootp &&
+			    ip -> client -> active -> expiry > cur_time &&
+			    /* Which is same as current ip */
+			    ip -> primary_address.s_addr != 0 &&
+			    ip -> client -> active -> address.len == 4 &&
+			    memcmp (ip -> client -> active -> address.iabuf,
+				    &ip->primary_address, 4) == 0)
+				client_envadd (ip -> client, "", "keep_old_ip", "%s", "yes");
 			if (ip -> client -> alias)
 				script_write_params (ip -> client, "alias_",
 						     ip -> client -> alias);


Comment 2 Ivan Gyurdiev 2004-06-15 17:41:18 UTC
Yes, I backed out this patch from the specfile and rebuilt.
Without it, network works upon restart. Reinstalled new rpms,
restarted network, stopped working again. 



Comment 3 Sammy 2004-06-15 19:03:02 UTC
I can confirm the same problem! 

Comment 4 Daniel Walsh 2004-06-15 19:06:29 UTC
The problem is we have two patches here, Do either of you know which
patch is causing the problem.  IE can either of you check if you move
these lines back to where they used to be,  does it work properly?

+  # Add route to make broadcast work. Do not omit netmask.
+  route add default dev $interface netmask 0.0.0.0

Comment 5 Ivan Gyurdiev 2004-06-15 19:53:42 UTC
Can you send me a patch.
Source RPMS are horrible to work with.
Isn't it convenient how you can --short-circuit 
for bi and bc, but not bb....



Comment 6 Ivan Gyurdiev 2004-06-24 21:13:16 UTC
Fixed in -rc14

Comment 7 John Flanagan 2004-12-21 19:41:55 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2004-566.html



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