Bug 86210 - ifconfig in network-functions-ipv6 does not set static ipv6 address
ifconfig in network-functions-ipv6 does not set static ipv6 address
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: initscripts (Show other bugs)
7.3
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Bill Nottingham
Brock Organ
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-03-17 05:15 EST by Marcel de Boer
Modified: 2014-03-16 22:35 EDT (History)
3 users (show)

See Also:
Fixed In Version: 7.30-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-08-15 16:26:27 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Marcel de Boer 2003-03-17 05:15:52 EST
Description of problem:
When I try to configure an 802.11b PCMCIA network card (Orinoco compatible) 
with an IPv6 site-local address, FEC0::1/64, the address is not assigned to the 
interface. After some experimentation, it turns out that the call to ifconfig 
to set the address (in /etc/sysconfig/network-scripts/network-functions-ipv6) 
fails with ifconfig giving returncode 1 and the networking scripts exiting on 
this error.

When I execute the *exact* same ifconfig line by hand after this failure, 
everything works fine.


Version-Release number of selected component (if applicable):
6.67-1

How reproducible:
Every time on insertion of network card

Steps to Reproduce:
1. Configure the network as described below, and add hermes.conf in /etc/pcmcia 
to add support for orinoco_cs.o
2. Restart PCMCIA subsystem and insert WLAN card
    
Actual results:
#ifconfig eth1
eth1  Link encap:Ethernet  HWaddr 00:02:2D:5E:FA:BD
      inet addr:10.0.1.1  Bcast:10.0.1.255  Mask:255.255.255.0
      inet6 addr: fe80::202:2dff:fe5e:fabd/10 Scope:Link
      UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

Expected results:
#ifconfig eth1
eth1  Link encap:Ethernet  HWaddr 00:02:2D:5E:FA:BD
      inet addr:10.0.1.1  Bcast:10.0.1.255  Mask:255.255.255.0
----> inet6 addr: fec0::1/64 Scope:Site <----
      inet6 addr: fe80::202:2dff:fe5e:fabd/10 Scope:Link
      UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

Additional info:
Laptop configuration: Compaq Armada 1700, PII-350, 128MB
eth0: 3Com 3CCE589ET 10 Mb/s ethernet card
eth1: ARtem ComCard 1.0 (rebadged Orinoco card)
Comment 1 Marcel de Boer 2003-03-17 10:25:19 EST
Configuration (sorry to have missed that):

/etc/sysconfig/network
NETWORKING=yes
NETWORKING_IPV6=yes
HOSTNAME=peugeot.ip6
IPV6FORWARDING=no
IPV6_AUTOCONF=no
IPV6_ROUTER=no

/etc/sysconfig/network-scripts/ifcfg-eth1
DEVICE=eth1
ONBOOT=no
IPADDR=10.0.1.1
NETMASK=255.255.255.0
NETWORK=10.0.1.0
BROADCAST=10.0.1.255
NAME=wlan
IPV6INIT=yes
IPV6ADDR=FEC0::1/64
Comment 2 Pekka Savola 2003-07-22 07:10:56 EDT
FWIW, the problem is with some interactions with hotplug: if I do /sbin/ifup
ethX it works fine, but though hotplug, it doesn't.
Comment 3 Bill Nottingham 2003-07-22 12:16:37 EDT
Perhaps due to having no stdin/stdout?
Comment 4 Daniel Roesen 2003-08-02 06:57:08 EDT
Hm, I'm having problems assigning static IPv6 address to eth0
as well... but this is a fixed NIC. The address just doesn't get
configured to the interface. Config is basically the same like the
original reporter has.
Comment 5 Daniel Roesen 2003-08-02 14:34:44 EDT
Pls ignore last comment. The reason was that I edited
/etc/sysconfig/network-scripts/ifcfg-eth0
to add the IPv6 stuff, but the ipup-ipv6 script uses only
/etc/sysconfig/networking/profiles/default/ifcfg-eth0
(which exists on some of my machines... on others, there is only the
/etc/sysconfig/network-scripts/ifcfg-eth0 one... hm.).
Comment 6 Pekka Savola 2003-08-13 05:06:30 EDT
Quoting from rhl-devel list..
========
[...]
--8<--
ipv6_exec_ifconfig() {
        local options=$*
                                                                               
                                         
        LC_ALL=C /sbin/ifconfig $options 2>&1
                                                                               
                                         
        return $?
}
                                                                               
                                         
ipv6_exec_ifconfig $device inet6 add $address || return 3
--8<--
                                                                               
                                         
1) works if you remove "2>&1", or
                                                                               
                                         
2) works if you change the command to like:
"ipv6_exec_ifconfig $device inet6 add $address > /dev/null || return 3"
                                                                               
                                         
I.e. it seems as if "2>&1" does not work with hotplug's "unspecified"
stdout/stderr fd's.
                                                                               
                                         
So..
                                                                               
                                         
- Is there a bug in hotplug's handling of stdout/stderr ?
- Is there a bug in bash's handling of "2>&1" when 1 is implicitly /dev/null?
- Is there something I'm missing? :-)

==========

so, based on current understanding, we're working around this issue by avoiding
the use of "2>&1", but I fear this may only be a work-around at some other
problem.  Thoughts?
Comment 7 Bill Nottingham 2003-08-13 11:19:46 EDT
My thoughts would be 'a) that's weird b) I haven't had time to look at it deeper
yet'.
Comment 8 Pekka Savola 2003-08-14 13:03:11 EDT
When I looked at hotplug to see if there are any obvious issues there, I can across this 
Debian bug report of a possibly similar issue:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=145484

could be related.
Comment 9 Bill Nottingham 2003-08-15 16:26:27 EDT
Patch added in 7.30-1.

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