Changeset 8eb4b13


Ignore:
Timestamp:
07/30/2006 03:11:25 AM (18 years ago)
Author:
Bruce Dubbs <bdubbs@…>
Branches:
6.2
Children:
8b64af6
Parents:
91ffc39
Message:

Update discussion of network driver rules

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/6.2/BOOK@7711 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

File:
1 edited

Legend:

Unmodified
Added
Removed
  • chapter07/network.xml

    r91ffc39 r8eb4b13  
    5050
    5151<screen role="nodump"><userinput>cat &gt; /etc/udev/rules.d/26-network.rules &lt;&lt; "EOF"
    52 <literal>ACTION=="add", SUBSYSTEM=="net", DRIVER=="?*", SYSFS{address}=="<replaceable>00:e0:4c:12:34:56</replaceable>", NAME="<replaceable>realtek</replaceable>"
    53 ACTION=="add", SUBSYSTEM=="net", DRIVER=="?*", SYSFS{address}=="<replaceable>00:a0:c9:78:9a:bc</replaceable>", NAME="<replaceable>intel</replaceable>"</literal>
     52<literal>ACTION=="add", SUBSYSTEM=="net", SYSFS{address}=="<replaceable>00:e0:4c:12:34:56</replaceable>", NAME="<replaceable>realtek</replaceable>"
     53ACTION=="add", SUBSYSTEM=="net", SYSFS{address}=="<replaceable>00:a0:c9:78:9a:bc</replaceable>", NAME="<replaceable>intel</replaceable>"</literal>
    5454EOF</userinput></screen>
    55 
    56     <para>The DRIVER=="?*" key prevents Udev from attempting to rename 8021Q
    57     VLAN interfaces (not available without the Vlan package from
    58     <ulink url="http://www.candelatech.com/~greear/vlan/"/>).
    59     This is necessary since VLANs have the same MAC address as
    60     the real network card.</para>
    6155
    6256<!-- Yes, I know that VLANs are beyond BLFS. This is not the reason to get them
     
    7973    of <quote>eth0</quote> in the network interface configuration files
    8074    below.</para>
     75
     76    <para>Note that the rules above don't work for every setup. For example,
     77    MAC-based rules break when bridges or VLANs are used, because bridges and
     78    VLANs have the same MAC address as the network card. One wants to rename
     79    only the network card interface, not the bridge or VLAN interface, but the
     80    example rule matches both. If you use such virtual interfaces, you have two
     81    potential solutions. One is to add the DRIVER=="?*" key after
     82    SUBSYSTEM=="net" in MAC-based rules which will stop matching the virtual
     83    interfaces.  This is known to fail with some older Ethernet cards because
     84    they don't have the DRIVER variable in the uevent and thus the rule does
     85    not match with such cards. Another solution is to switch to rules that use
     86    the bus position as a key.</para>
     87
     88    <para>The second known non-working case is with wireless cards using the
     89    MadWifi or HostAP drivers, because they create at least two interfaces
     90    with the same MAC address and bus position. For example, the Madwifi driver
     91    creates both an athX and a wifiX interface where X is a digit.  To
     92    disambiguate these cases, add SYSFS{type}=="zzz" after SUBSYSTEM=="net" for
     93    each interface that is handled by that driver, where zzz is the output of
     94    <userinput>cat /sys/class/net/&lt;interface_name&gt;/type</userinput>.</para>
     95
     96    <para>There may be other cases where the rules above don't work. Currently,
     97    bugs on this topic are still being reported to Linux distributions, and no
     98    solution that covers every case is available.</para>
    8199
    82100  </sect2>
Note: See TracChangeset for help on using the changeset viewer.