lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 7 Jul 2010 16:15:55 -0700
From:	Steve Fink <sphink@...il.com>
To:	Michael Di Domenico <mdidomenico4@...il.com>
Cc:	linux-net@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: nic enumeration

On Wed, Jul 7, 2010 at 3:25 PM, Michael Di Domenico
<mdidomenico4@...il.com> wrote:
> What I'm curious about is how/why Linux actually decides Nic1 should be Eth0?
>
> My theory is it starts on the lowest MAC address and works up,
> depending partly on driver load order.

I may be spewing misinformation here, but my understanding of how this
works is that the specific ordering is pretty much random. It's rather
unlikely to be based on MAC address value, except accidentally; it's
probably just whatever comes up first when it enumerates the
interfaces, which could easily be timing-dependent. (From personal
experience, two identical but physically separate NICs will come up in
a different order on every boot. Your case may be more consistent.)

The first time it does this, though, it records the MAC address into
the appropriate ifcfg-* script. From then on, at boot time it checks
the MAC address of each interface as it comes up. If it mismatches
with what is recorded in the ifcfg-* script, then it skips that name
and tries using the next.

In other words, all you should have to do is set HWADDR appropriately
in the the ifcfg-* scripts and it should do the right thing.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ