Bug 75506 - network-functions: is_available should re-check device after modprobe
network-functions: is_available should re-check device after modprobe
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: initscripts (Show other bugs)
8.0
i386 Linux
medium Severity low
: ---
: ---
Assigned To: Bill Nottingham
Brock Organ
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-10-09 05:21 EDT by Aleksey Nogin
Modified: 2014-03-16 22:31 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-01-14 00:23:39 EST
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 Aleksey Nogin 2002-10-09 05:21:20 EDT
Description of Problem:

In /etc/sysconfig/network-scripts/network-functions, the is_available function
assumes that if modprobe succeeded, then the device must be available. When this
assumption is wrong, ifup keeps trying to bring up non-existing device which
takes time and prints lots of irrelevant error messages.

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

initscripts-6.95-1

How Reproducible:

100%

Steps to Reproduce:
1. For my laptop, I have two eth interfaces that both use the same driver
(3c59x) - one built-in and on in a docking station. 
2. I have in the modules.conf:
alias eth0 3c59x
alias eth1 3c59x
3. When I am *not* plugged into docking station (and eth0 in present, but eth1
is not), I run "ifup eth1"

Actual Results: 

It takes several seconds to complete and prints a lot of ugly error messages. 

Expected Results:

Quickly figures device is just not there.

Additional Information:
	
The problem is that the is_available function in network-functions assumes that
if an alias in present in modules.conf and the modprobe succeeded, the device
must be present. As this example shows, in case of several devices using the
same module this is an incorrect assumption. Instead is_available should check
"ip -o link" again after the modprobe.
Comment 1 Jon DeSena 2002-11-04 11:14:19 EST
See attached patch to bug #77267 for a solution to this.
Comment 2 Bill Nottingham 2003-01-14 00:23:39 EST
Check after loading the module done in 7.03-1.
Comment 3 Aleksey Nogin 2003-01-14 21:05:34 EST
Indeed, seems to work correctly with  7.03-1.

Minor issue, though - if I have two devices (eth0 and eth1) aliased to the same
module (3c59x), then on "ifup eth1" I get a message telling "3c59x device does
not seem to be present, delaying eth1 initialization". The messages is
inaccuratre - there is a 3c59x device present (eth0), it's just that there is
only one of them...
Comment 4 Bill Nottingham 2003-01-15 00:36:23 EST
message reworded in CVS.

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