Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 11474

Summary: ifconfig add can trash ordinary address
Product: [Retired] Red Hat Linux Reporter: rjb
Component: net-toolsAssignee: Crutcher Dunnavant <crutcher>
Status: CLOSED WONTFIX QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2000-05-17 13:59:48 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description rjb 2000-05-17 13:59:48 UTC
Attemping to add an IPv6 addres on an interface when the tools dont support
it can trash the main address without giving any warning to the user that
this is what has happened.

# ifconfig eth0:2 192.168.5.5 netmask 255.255.255.0
# ifconfig eth0:2
eth0:2    Link encap:Ethernet  HWaddr 00:60:08:0B:C5:44
          inet addr:192.168.5.5  Bcast:192.168.5.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          Interrupt:10 Base address:0xff00
# ifconfig eth0:2 add 2001:618:1000::1/64
2001:618:1000::1: Unknown host
Usage: ...
#  ifconfig eth0:2
eth0:2    Link encap:Ethernet  HWaddr 00:60:08:0B:C5:44
          inet addr:157.59.20.46  Bcast:157.59.255.255  Mask:0.0.0.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          Interrupt:10 Base address:0xff00

Even though the user is given an unknown host message and a usage message,
behind the scenes ifconfig has gone ahead and trashed the IPv4 addresss
on the interface. (note the changing IPv4 address in the above cut and
paste)

This is with kernel 2.2.12-20 and net-tools-1.53-1