Bug 75506 - network-functions: is_available should re-check device after modprobe
Summary: network-functions: is_available should re-check device after modprobe
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: initscripts   
(Show other bugs)
Version: 8.0
Hardware: i386 Linux
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Brock Organ
Depends On:
TreeView+ depends on / blocked
Reported: 2002-10-09 09:21 UTC by Aleksey Nogin
Modified: 2014-03-17 02:31 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2003-01-14 05:23:39 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Aleksey Nogin 2002-10-09 09:21:20 UTC
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):


How Reproducible:


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 16:14:19 UTC
See attached patch to bug #77267 for a solution to this.

Comment 2 Bill Nottingham 2003-01-14 05:23:39 UTC
Check after loading the module done in 7.03-1.

Comment 3 Aleksey Nogin 2003-01-15 02:05:34 UTC
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 05:36:23 UTC
message reworded in CVS.

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