Autor: tito Data: A: dng Assumpte: Re: [DNG] My Qemu LAN-peer documentation is now in its first draft
On Thu, 4 Mar 2021 11:02:08 +0100
Didier Kryn <kryn@???> wrote:
> Le 04/03/2021 à 07:46, tito via Dng a écrit :
> > How Linux assigns network interface names
> > The default name for Ethernet interfaces is based upon how Linux
> > initializes them during device discovery. As Linux finds the network
> > devices it will start numbering them starting with 0 and increasing
> > sequentially.
>
> But what if, say, eth0 is renamed by the hotplugger before the
> kernel discovers the second ethernet device? I guess the kernel
> restarts with 0 which is the smallest free number. Because eth0 may
> well have been renamed eth1 by the hotplugger. I didn't dig in the
> kernel code to verify.
>
> -- Didier
>
>
> hi,
I bet the counter is increased until a free number is found for the law
of laziness and least effort.