Bug 879049 - When running start_udev, if a network device is already present, it will try to add it again.
Summary: When running start_udev, if a network device is already present, it will try ...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: initscripts
Version: 6.3
Hardware: All
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: Lukáš Nykrýn
QA Contact: qe-baseos-daemons
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-11-21 22:52 UTC by David Hill
Modified: 2016-11-25 13:03 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-05-21 14:29:48 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description David Hill 2012-11-21 22:52:23 UTC
Description of problem:
When running start_udev, if a network device is already present, it will try to add it again.
The bug lies in : "/etc/sysconfig/network-scripts/net.hotplug"

add|register)

    case $INTERFACE in
        # interfaces that are brought up as a part of configuration
        ppp*|ippp*|isdn*|plip*|lo*|irda*|dummy*|ipsec*|tun*|tap*)
            exit 0
            ;;
        # interfaces that are registered then brought up
        *)
            export IN_HOTPLUG=1
            if [ -x /sbin/ifup ]; then
                addr=$(get_hwaddr ${INTERFACE})
                if [ -n "$addr" ]; then
                        nconfig=$(get_config_by_hwaddr ${addr})
                        [ -n "$nconfig" ] && INTERFACE=$nconfig
                fi
                exec /sbin/ifup $INTERFACE
            fi
            ;;
    esac
    ;;

and the udev policy :
ACTION=="add", SUBSYSTEM=="net", DEVPATH=="/devices/virtual/net/lo", RUN+="/sbin/ifup $env{INTERFACE}"
ACTION=="add", SUBSYSTEM=="net", PROGRAM="/lib/udev/rename_device", RESULT=="?*", ENV{INTERFACE_NAME}="$result"
SUBSYSTEM=="net", RUN+="/etc/sysconfig/network-scripts/net.hotplug"


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


How reproducible:
Everytime

Steps to Reproduce:
1. Run start_udev
2. It will try to add the interface that is already present
3.
  
Actual results:
Crash the network if you have bonding

Expected results:
Do not add an interface that is already present.

Additional info:

Comment 2 Lukáš Nykrýn 2012-11-28 15:41:36 UTC
wrt to this article https://access.redhat.com/knowledge/solutions/154183 you should not call start_udev by yourself.

Comment 3 David Hill 2012-11-28 16:03:25 UTC
"Hello,

As the "max_sectors_kb" values can be changed on the fly. running start_udev for changing it should be fine.

let us know in case of any questions.

Thank you
Nitin"


That'w what I've been told by your support...  is the udevadm present on all versions of redhat?   I still have to support rhel3, rhel4, rhel5 and rhel6 with this...  start_udev is available on all rhels so it was easier to manage.

Comment 4 Lukáš Nykrýn 2012-11-29 09:21:52 UTC
But does udevadm method work in your case (on rhel6)?

Comment 5 David Hill 2012-11-29 15:13:32 UTC
I'll have to try it for RHEL6... find the equivalent for RHEL5, RHEL4 and RHEL3...  I think we don't have any fiberchannel on RHEL3 so I may skip that one but it will take some time to do this.

Comment 7 Lukáš Nykrýn 2013-04-02 15:23:52 UTC
Did you have some time to test calling udevadm on rhel6?

Comment 8 David Hill 2013-04-04 10:43:08 UTC
No didn't have time to test it but I'm pretty sure it will do the trick ... I still think that start_udev should look after a running udev and run udevadm instead but that's your call!

You can close this ticket if nothing will be fixed on your side.

Thank you very much!


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