Bug 104494 - changing a network interface from static to dhcp leaves artefacts in the config file => it does not work
Summary: changing a network interface from static to dhcp leaves artefacts in the conf...
Status: RESOLVED DUPLICATE of bug 73739
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: YaST2 (show other bugs)
Version: Beta 1
Hardware: Other All
: P5 - None : Major
Target Milestone: ---
Assignee: Martin Vidner
QA Contact: Klaus Kämpf
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 97395
  Show dependency treegraph
 
Reported: 2005-08-12 20:20 UTC by Forgotten User ZhJd0F0L3x
Modified: 2006-08-23 15:26 UTC (History)
1 user (show)

See Also:
Found By: Component Test
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Forgotten User ZhJd0F0L3x 2005-08-12 20:20:12 UTC
once i had my interface configured statically, then i changed to dhcp. This is
how my ifcfg-eth-id-XX:XX:XX:XX:XX:XX now looks like:

BOOTPROTO='dhcp'
BROADCAST='10.10.255.255'
IPADDR='10.10.129.126'
MTU=''
NAME='Sony 82562ET/EZ/GT/GZ - PRO/100 VE (LOM) Ethernet Controller Mobile'
NETMASK='255.255.0.0'
NETWORK='10.10.0.0'
REMOTE_IPADDR=''
STARTMODE='ifplugd'
UNIQUE='JNkJ.UymknSERMbD'
USERCONTROL='yes'
_nm_name='bus-pci-0000:06:08.0'
PREFIXLEN=''
IFPLUGD_PRIORITY='20'

if i plug it in at home (192.168.200/24 network, dhcp) i get the following route:

strolchi:/tmp/kpowersave # route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.200.0   0.0.0.0         255.255.255.0   U     0      0        0 wire
10.10.0.0       0.0.0.0         255.255.0.0     U     0      0        0 wire
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0 lo
0.0.0.0         192.168.200.1   0.0.0.0         UG    0      0        0 wire

which of course successfully kills every try to connect to the suse network via
my router :-)
Comment 1 Christian Zoz 2005-08-13 11:51:07 UTC
You have to remove the static adresses from the ifcfg file. 

When switching from static to dhcp YaST must not leave them there. Also remove
the old static route.

It is a feature fromifup to setup both dhcp and static if configured; some
people use that. Now if there is also a static route configured this from dhcp
will be overwritten (also a feture).
Comment 2 Lukas Ocilka 2005-08-14 21:28:07 UTC
So, please, Christian, is it all bug or feature :)?
Comment 3 Christian Zoz 2005-08-15 08:11:06 UTC
Features:
- ifup sets static adresses even if BOOTPROTO=dhcp
- ifup sets static routes even if BOOTPROTO=dhcp

Bug:
YaST leaves static address and static route in configuration, when user switches
from static to dhcp. In this case the user wants only dhcp without the old
static settings.

Fix:
YaST has to remove the static ip and route when the user switches to dhcp.

Note:
If a user wants static settings beside dhcp he has to configure it explicitely
(manually). There are not much users of that feature and these are mostly experts.

BTW:
This is a duplicate of bug 73739
Comment 4 Martin Vidner 2005-08-15 16:09:24 UTC
I have fixed it in yast2-network-2.12.10.  
Comment 5 Martin Vidner 2005-08-15 16:13:47 UTC
Uh, not really. I only fixed the address part, not static routes. 
Comment 6 Martin Vidner 2005-08-15 16:14:42 UTC
Anyway, it is a duplicate as Christian has pointed out. 

*** This bug has been marked as a duplicate of 73739 ***
Comment 7 K.R. Foley 2006-08-23 15:20:03 UTC
I have also experienced the issue of both the static and dynamic IP being used. Since I don't have access to the bug #73739 that this was marked as a duplicate of, could someone please update the resolution information on this bug?
Comment 8 Martin Vidner 2006-08-23 15:26:45 UTC
That one is public now.