On 2024-05-21, Dale <rdalek1...@gmail.com> wrote:

>> Here's my udev rules file that defines my network interface names
>> for the machine I'm on at the moment:
>>
>> ------------------/etc/udev/rules.d/70-my-persistent-net.rules-----------------------
>> SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="2c:f0:5d:6f:10:af", 
>> NAME="net0"
>> SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="00:1b:21:b1:d1:e9", 
>> NAME="net1"
>> -------------------------------------------------------------------------------------
>
> Examples do help a lot.  I do use the enp* naming scheme.  My
> understanding, that is the "new" way.

The suffix for those enp* names comes from the PCI bus subsystem based
on bus number, slot number, etc.  [Yes, slot number apparently does
change based on what PCIe cards are present. No, that doesn't make
sense to me either]

> Based on your config, I would need to change the NAME= to enp* names
> and that would correct that.

I suppose you could, but I would not use enp* names. Those could
conflict with the autogenerated names.

> Where you have ATTR, is that a quote or did you edit to remove a
> number, MAC address, IP or something? 

What I posted is exactly what's in the file
(without the ----------- delimiters).

Here's more documentation:

https://wiki.gentoo.org/wiki/Udev
https://wiki.archlinux.org/title/udev
https://wiki.archlinux.org/title/Network_configuration#Change_interface_name

[The arch Wiki is always a good fallback if the Gentoo manual/Wiki
don't have what you're looking for.]

> If it is one of those, where do I find that info?  I checked
> ifconfig and didn't see a MAC address.  I also checked lspci -v. 
> I'm not sure where you get the needed info from.   BTW, right now,
> I'm on my main rig. 

The only thing you need to change from my example would be the mac
address(es) (e.g. 2c:f0:5d:6f:10:af) and the names (e.g. net0).

> I have the package net-misc/networkmanager installed.  Most likely
> pulled in by something else.  Could I use it to configure this? 

Possibly, I don't use networkmanager and don't know how it works on
Gentoo.  I use the default Gentoo netifrc scheme
https://wiki.gentoo.org/wiki/Netifrc.

> I also have KDE installed on the NAS box, it is also a backup rig in
> case my main rig dies.  It may have a GUI that I could use.  I'm not
> opposed to the command line way tho.  Biggest thing, copy and paste
> would be nice. 

I don't know much of anything about KDE.

--
Grant



Reply via email to