On 10/19/25 4:46 PM, Andy Smith wrote:
Hi,

On Sun, Oct 19, 2025 at 06:43:31PM +0300, Henrik Ahlgren wrote:
 From the information he has provided to me off-list, it is indeed the
case that the ethernet-over-USB device in question (essentially a 4G
router I believe) IS changing MACs on each power cycle, so the names
are not predictable, without some sort of udev configuration or other
tricks.

Why can Richard not post this simple thing to the list so we are all on
the same page?

It is not even clear why Richard can't use vnstat anyway, as there isn't
any indication that he does actually need to know the interface name,
there was only a vague implication that he was confused because he had
some documentation that didn't show interface names he recognised.

I think it's quite likely that if he just tried to use it, it would work
fine for logging the amount of monthly data through all interfaces.

So, Richard, can you just:

1) Show us the output of "ip link show" that shows two different names
    for "enx…" (i.e. do it at least twice, showing different name after
    you've re-plugged it or whatever), and;

richard@debian12:~$ ip link show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eno1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000
    link/ether 5c:26:0a:35:91:9f brd ff:ff:ff:ff:ff:ff
    altname enp0s25
3: wlp2s0b1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN mode DORMANT group default qlen 1000 link/ether 72:d0:44:d6:d9:12 brd ff:ff:ff:ff:ff:ff permaddr 5c:ac:4c:15:2a:30 9: enxf6c0d1541b3e: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN mode DEFAULT group default qlen 1000
    link/ether f6:c0:d1:54:1b:3e brd ff:ff:ff:ff:ff:ff
richard@debian12:

*POWER DEVICE OFF/ON*

richard@debian12:~$ ip link show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eno1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000
    link/ether 5c:26:0a:35:91:9f brd ff:ff:ff:ff:ff:ff
    altname enp0s25
3: wlp2s0b1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN mode DORMANT group default qlen 1000 link/ether 72:7c:84:41:d3:24 brd ff:ff:ff:ff:ff:ff permaddr 5c:ac:4c:15:2a:30 10: enx424c8f375f4c: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN mode DEFAULT group default qlen 1000
    link/ether 42:4c:8f:37:5f:4c brd ff:ff:ff:ff:ff:ff
richard@debian12:~$


2) tell us where you are stuck with vnstat?


Basically I don't know *what* "I don't know".
This morning I found a Debian aware tutorial for vnstat:
https://www.linuxbabe.com/monitoring/install-vnstat-debian-8ubuntu-16-04-server-monitor-network-traffic

I'll see if I can reproduce their examples.

We can indeed get into custom network device names with systemd .link
files but given how hard it's been to get these simple things answered,
that could be a very long road that perhaps we do not need to go down.

Thanks,
Andy



Reply via email to