Bug 484384

Summary: Fedora 10 and SIS900 ethernet controllers - Can't we all just get along?
Product: [Fedora] Fedora Reporter: Dan McNaul <dmcnaul>
Component: NetworkManagerAssignee: Dan Williams <dcbw>
Status: CLOSED CANTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: rawhideCC: arxs, dcbw, wtogami
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-10-16 22:44:12 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 Dan McNaul 2009-02-06 15:07:37 UTC
Description of Problem:

This is a fresh install of Fedora 10.  

This problem is caused by the known issue of "Silicon Integrated Systems" Ethernet Controller and the sis900 driver.  See Bugzilla ID 10201.  

My SIS NIC has a Hardware Address of 00:00:00:00:00:00.  There is no BIOS capabilities to assign a valid MAC address.  Upon booting of Fedora 10 the NIC card is not initialized correctly even though I've made the appropriate changes to the /etc/sysconfig/network-scripts/ifcfg-eth0 file.  These changes detailed in ID 10201 (Fedora 8) are:

HWADDR=AA:00:00:00:00:AA   <- Where this fake MAC addr is not used elsewhere on the network
MACADDR=AA:00:00:00:00:AA  <- Where this matches what we made up for HWADDR

After some close study of the log messages and their sequence of display, I came to the conclusion that /etc/init.d/NetworkManager is not using the HWADDR and MACADDR settings in the config file.  This is why after boot up, if I logged in and "activated" the interface (from the menu click -> System-Administration-Network and use the Network Configuration dialog), the network would come up.  It appears that "Network Configuration" dialog uses the "/etc/sysconfig/network-scripts/ifup-eth" script.  This script makes use of the HWADDRD and MACADDR parameters.

So I added the command "ip link set dev eth0 address AA:00:00:00:00:AA" directly before execution of NetworkManager (in /etc/init.d/NetworkManager).  This sets a valid MAC address (non-zero) for the SIS NIC for NetworkManager to use.  I also had to add the parameter "NM_CONTROLLED=yes" to the /etc/sysconfig/network-scripts/ifcfg-eth0" file.

Now upon boot-up, Fedora 10 (really NetworkManager)is able to configure and bring up the network interface automatically on a reboot.

This bug is "medium" because:

1).  Honestly, how many of us have SIS ethernet controllers that assign all ZEROS to the MAC address.
2).  We have a work around I've stated above.

It would be nice if NetworkManager looked for HWADDR and MACADDR and make use of them auto-magically.

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

NetworkManager-glib-0.7.0-0.11.svn4229.fc10.i386

How reproducible:

Take a machine that has a SIS 900 ethernet controller built into the motherboard.  Install Fedora 10 and boot her up.  Watch as NetworkManager tries, but fails to init the NIC and start the network.

Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Dan Williams 2009-02-06 16:45:51 UTC
So how does the card normally get a MAC address?  Is it expected to get set manually using some file on the host?  Do you have to copy the MAC address down from a sticker on the back of the card and put that into a conf file somewhere when not using NetworkManager?

Comment 2 Dan McNaul 2009-02-07 14:47:05 UTC
Hi, Dan.

I think the sis900 ethernet controllers having a ZERO MAC address is suppose to be a "feature".  I have some old Sun boxes that have ZERO's too, but I am only running solaris on them.  I think it was suppose to give the Network Administrator some options in setting up and controlling his/her network.

On Linux (Fedora versions), I manually add the MACADDR= parameter (the HWADDR= parameter is usually already included and set to all ZEROs because that's what the card and sis900 driver return) to the /etc/sysconfig/network-scripts/ifcfg-eth0 file.  The ifup-eth script checks for and uses the MACADDR parameter to assign a new MACADDR to the controller (using the "ip link set" command) before trying to bring up and initialize the card.  I make up the MACADDR and HWADDR value by first checking my routers to make sure the value I concocted isn't already being used somewhere on the network.  All of this is truly, "do it once and never touch it again" until you refresh the box with a new release.  I've done it so many times, that I know it has to be done.  This time I was stymied because I had to update the NetworkManager daemon script and update the NM_CONTROLLED=yes parameter. 

This really isn't a "bug" for NetworkManager.  At least, I wouldn't categorize it as one.  This is more a "How-To" type of thing.  What probably makes more sense is to ask the sis900 driver developer (http://www.brownhat.org/sis900.html) to check the /etc/sysconfig/network-scripts/ifcfg-eth0 file for the MACADDR= (or HWADDR=) parameter and reset its MACADDR when the driver is loaded.  That way the card will look and report like "normal" NICs do.  If he doesn't like using a Fedora specific file, then the driver could have it's own config file somewhere that we'd go edit.

Thanks for your time and attention.

Dan McNaul

Comment 3 Dan Williams 2009-02-12 23:18:15 UTC
So one issue here is going to be positively identifying specific ethernet cards; say you've got two of these things in a machine, how do you know which one is supposed to get which MAC address you assign?  Traditionally we've been able to identify the card using the MAC address, which of course doesn't work here.  Kernel PCI bus scanning is not stable (has never been and there's no guarantee that it will be between kernel versions) and thus we cannot use the device name, so some other mechanism needs to exist to uniquely identify a specific card...

Comment 4 Niels Haase 2009-04-17 13:15:20 UTC
(In reply to comment #3)
> So one issue here is going to be positively identifying specific ethernet
> cards; say you've got two of these things in a machine, how do you know which
> one is supposed to get which MAC address you assign?  Traditionally we've been
> able to identify the card using the MAC address, which of course doesn't work
> here.  Kernel PCI bus scanning is not stable (has never been and there's no
> guarantee that it will be between kernel versions) and thus we cannot use the
> device name, so some other mechanism needs to exist to uniquely identify a
> specific card...  

With kernel 2.6.29 a change is done on sis900.c with now generate a random mac address for SIS900 NICs if the MAC address is invalid (like all zero). 

Reporter, can you please try rawhide (or the beta from f11) to test the behaviour again? Thank you.

-- 
Fedora Bugzappers volunteer triage team
https://fedoraproject.org/wiki/BugZappers

Comment 5 Dan McNaul 2009-04-17 22:00:13 UTC
Thank you, Niels.

The server is being used in a psuedo production environment.  I will do as you ask, but it may take me some time to arrange it.

Dan

Comment 6 Dan McNaul 2009-05-11 12:34:05 UTC
Niels,

I'm sorry to inform you that the Motherboard (an off brand PC Chips board) that contained the SIS900 ethernet chip malfunctioned (failed).  I had to replace it.  I replaced it with an Intel board.

What this means is that I won't be able to run the tests for you.

Dan

Comment 7 Dan Williams 2009-10-16 22:44:12 UTC
Ok, sorry.  I think in the future, the answer for cases where the NIC does not have a MAC address already is to set one using udev rules, at which point NetworkManager will Just Work with it as normal.