:: Re: [DNG] Predictable Network Inter…
Top Pagina
Delete this message
Reply to this message
Auteur: Steve Litt
Datum:  
Aan: dng
Nieuwe Onderwerpen: [DNG] ifconfig etc (was: Predictable Network Interface Names - Stupid or good idea?)
Onderwerp: Re: [DNG] Predictable Network Interface Names - Stupid or good idea?
On Sat, 9 Jan 2016 12:41:27 +0100
Anto <aryanto@???> wrote:

[snip]

> It turned out that the eth0 interface was changed to ens3, due to the
> implementation of Predictable Network Interface Names
> (http://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames).
> I can change everything which contain eth0 into ens3, but I prefer to
> keep the old interface naming. So my temporary solution is to add
> net.ifnames=0 into the kernel command line.
>
> I have been indoctrinated myself that everything come from systemd
> gang are stupid and bad. After reading the above link and some other
> pages from systemd supporters, I think I might have to change my mind
> about that Predictable Network Interface Names idea. But I am not
> entirely sure yet. What do you guys think about that?


I believe that the new naming scheme is stupid and bad. Here, let me
plug my little white USB wifi dongle into my USB hub...

wlp0s22f0u1u2u1

Very nice!

Wait, let me move the dongle to a different port on the USB hub...

wlp0s22f0u1u4

Wow, not even the same number of digits. Very "predictable"!

Now I'll plug it into one of the computer's front USB ports:

wlp0s19f2u1

So, if you're one of the unfortunate people having a laptop with a
Linux-unusable built in wifi, you now get a device name that depends on
which USB port you happen to plug your dongle into. Let's all give the
Freedesktop folks a hand for their contribution to predictability.

Freedesktop's "predictable network interface names" is NOT a good idea.

All the preceding notwithstanding, I pick my battles, and this is a
battle I won't be fighting. I have been and will continue to work with
the new device naming scheme.

First of all, some of the most anti-systemd distros, like Void and
Gentoo and Funtoo, use the new naming convention. Second, once you
really know the new ip command (and forget the old ifconfig stuff), you
can pretty much figure everything out. For instance, let's say you're
an unlucky soul who has an unfathomable broadcom wifi in his laptop,
and rather than becoming the king of blacklisting and exotic drivers,
you use a dongle. You could run this command very early in your boot,
so that you always know the device name of the dongle and can put it
into your shellscripts:

ip link | grep -v "^\s" | \
sed -e"s/[^:]*:\s*"// -e"s/:.*//" | \
grep"^wl" | grep -v $BUILTINWIFI > ~/dongle_wifi.dev

From then on, your dongle device name is available with a simple `echo
~/dongle_wifi.dev`.

Crude but effective. If systemd could be worked around this easily, I'd
be dancing in the streets, singing the praises of Debian.

Seriously, now is the time for everybody to learn the ip command. It's
ugly. It's poorly documented. But it's very, very powerful, and enables
you do do just about anything in networking.

SteveT

Steve Litt
January 2016 featured book: Twenty Eight Tales of Troubleshooting
http://www.troubleshooters.com/28