Public bug reported: While configuring a system based on ubuntu 22.04 version , we found that a system-d udev rules assign a random mac address to one of the network interfaces .
Kernel version uname -a 5.15.0-25-generic #25-Ubuntu SMP Wed Mar 30 15:54:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux Ubunutu version root@maglev-master-10-106-0-137:~# lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 22.04.5 LTS Release: 22.04 Codename: jammy ip addr show output which shows the mac address has been changed ens192: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 1500 qdisc mq master management state UP group default qlen 1000 link/ether d2:29:6b:94:be:bd brd ff:ff:ff:ff:ff:ff permaddr 00:50:56:b8:ed:a0 altname enp11s0 d2:29:6b:94:be:bd is being randomly assigned while permanent address is 00:50:56:b8:ed:a0 root@maglev-master-10-106-0-137:~# ethtool -P ens192 Permanent address: 00:50:56:b8:ed:a0 PID: 1760 (snmpd) changed MAC to 00:00:00:00:00:00 PID: 1760 (snmpd) changed MAC to 00:00:00:00:00:00 PID: 15073 (systemd-udevd) changed MAC to d2:29:6b:94:be:bd PID: 15073 (systemd-udevd) changed MAC to d2:29:6b:94:be:bd PID: 15073 (systemd-udevd) changed MAC to d2:29:6b:94:be:bd PID: 15084 (ip) changed MAC to d2:29:6b:94:be:bd PID: 15084 (ip) changed MAC to d2:29:6b:94:be:bd bpftrace output Invoked kprobe:dev_set_mac_address_user with MAC d2:29:6b:94:be:bd Stack trace: dev_set_mac_address_user+1 rtnl_setlink+246 rtnetlink_rcv_msg+349 netlink_rcv_skb+83 rtnetlink_rcv+21 netlink_unicast+538 netlink_sendmsg+588 sock_sendmsg+98 __sys_sendto+275 __x64_sys_sendto+36 do_syscall_64+89 entry_SYSCALL_64_after_hwframe+68 systemd-udevd(7123) systemd-udevd(6656) Invoked kprobe:dev_set_mac_address with MAC d2:29:6b:94:be:bd Stack trace: dev_set_mac_address+1 do_setlink+2217 rtnl_setlink+246 rtnetlink_rcv_msg+349 netlink_rcv_skb+83 rtnetlink_rcv+21 netlink_unicast+538 netlink_sendmsg+588 sock_sendmsg+98 __sys_sendto+275 __x64_sys_sendto+36 do_syscall_64+89 entry_SYSCALL_64_after_hwframe+68 systemd-udevd(7123) systemd-udevd(6656) Invoked kprobe:bond_set_mac_address with MAC d2:29:6b:94:be:bd Stack trace: bond_set_mac_address+1 dev_set_mac_address_user+50 do_setlink+2217 rtnl_setlink+246 rtnetlink_rcv_msg+349 netlink_rcv_skb+83 rtnetlink_rcv+21 netlink_unicast+538 netlink_sendmsg+588 sock_sendmsg+98 __sys_sendto+275 __x64_sys_sendto+36 do_syscall_64+89 entry_SYSCALL_64_after_hwframe+68 ip(7137) sh(7135) python3(7013) twistd3(2045) web_install_ser(1959) Invoked kprobe:dev_set_mac_address with MAC d2:29:6b:94:be:bd Stack trace: dev_set_mac_address+1 do_set_master+146 do_setlink+684 __rtnl_newlink+1560 rtnl_newlink+73 rtnetlink_rcv_msg+349 netlink_rcv_skb+83 rtnetlink_rcv+21 netlink_unicast+538 netlink_sendmsg+588 sock_sendmsg+98 ____sys_sendmsg+590 ___sys_sendmsg+129 __sys_sendmsg+98 __x64_sys_sendmsg+29 do_syscall_64+89 entry_SYSCALL_64_after_hwframe+68 ip(7137) sh(7135) python3(7013) twistd3(2045) web_install_ser(1959) Invoked kprobe:vmxnet3_set_mac_addr with MAC d2:29:6b:94:be:bd Stack trace: vmxnet3_set_mac_addr+1 bond_enslave+1521 do_set_master+146 do_setlink+684 __rtnl_newlink+1560 rtnl_newlink+73 rtnetlink_rcv_msg+349 netlink_rcv_skb+83 rtnetlink_rcv+21 netlink_unicast+538 netlink_sendmsg+588 sock_sendmsg+98 ____sys_sendmsg+590 ___sys_sendmsg+129 __sys_sendmsg+98 __x64_sys_sendmsg+29 do_syscall_64+89 entry_SYSCALL_64_after_hwframe+68 Not able to understand why this systemd rule is triggering and assigning MAC address randomly while we have a permanent Mac configured for that network interface . ** Affects: systemd (Ubuntu) Importance: Undecided Status: New ** Description changed: While configuring a system based on ubuntu 22.04 version , we found that a system-d udev rules assign a random mac address to one of the network interfaces . - Kernel version uname -a 5.15.0-25-generic #25-Ubuntu SMP Wed Mar 30 15:54:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux + Ubunutu version - Ubunutu version - - root@maglev-master-10-106-0-137:~# lsb_release -a + root@maglev-master-10-106-0-137:~# lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 22.04.5 LTS Release: 22.04 Codename: jammy + ip addr show output which shows the mac address has been changed + ens192: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 1500 qdisc mq master management state UP group default qlen 1000 + link/ether d2:29:6b:94:be:bd brd ff:ff:ff:ff:ff:ff permaddr 00:50:56:b8:ed:a0 + altname enp11s0 - ip addr show output which shows the mac address has been changed - - ens192: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 1500 qdisc mq master management state UP group default qlen 1000 - link/ether d2:29:6b:94:be:bd brd ff:ff:ff:ff:ff:ff permaddr 00:50:56:b8:ed:a0 - altname enp11s0 - - - d2:29:6b:94:be:bd is being randomly assigned while permanent address is 00:50:56:b8:ed:a0 - + d2:29:6b:94:be:bd is being randomly assigned while permanent address is + 00:50:56:b8:ed:a0 root@maglev-master-10-106-0-137:~# ethtool -P ens192 Permanent address: 00:50:56:b8:ed:a0 - - PID: 1760 (snmpd) changed MAC to 00:00:00:00:00:00 PID: 1760 (snmpd) changed MAC to 00:00:00:00:00:00 PID: 15073 (systemd-udevd) changed MAC to d2:29:6b:94:be:bd PID: 15073 (systemd-udevd) changed MAC to d2:29:6b:94:be:bd PID: 15073 (systemd-udevd) changed MAC to d2:29:6b:94:be:bd PID: 15084 (ip) changed MAC to d2:29:6b:94:be:bd - PID: 15084 (ip) changed MAC to d2:29:6b:94:be:bd + PID: 15084 (ip) changed MAC to d2:29:6b:94:be:bd - - bpftrace output - + bpftrace output Invoked kprobe:dev_set_mac_address_user with MAC d2:29:6b:94:be:bd Stack trace: - dev_set_mac_address_user+1 - rtnl_setlink+246 - rtnetlink_rcv_msg+349 - netlink_rcv_skb+83 - rtnetlink_rcv+21 - netlink_unicast+538 - netlink_sendmsg+588 - sock_sendmsg+98 - __sys_sendto+275 - __x64_sys_sendto+36 - do_syscall_64+89 - entry_SYSCALL_64_after_hwframe+68 + dev_set_mac_address_user+1 + rtnl_setlink+246 + rtnetlink_rcv_msg+349 + netlink_rcv_skb+83 + rtnetlink_rcv+21 + netlink_unicast+538 + netlink_sendmsg+588 + sock_sendmsg+98 + __sys_sendto+275 + __x64_sys_sendto+36 + do_syscall_64+89 + entry_SYSCALL_64_after_hwframe+68 - systemd-udevd(7123) systemd-udevd(6656) + systemd-udevd(7123) systemd-udevd(6656) Invoked kprobe:dev_set_mac_address with MAC d2:29:6b:94:be:bd Stack trace: - dev_set_mac_address+1 - do_setlink+2217 - rtnl_setlink+246 - rtnetlink_rcv_msg+349 - netlink_rcv_skb+83 - rtnetlink_rcv+21 - netlink_unicast+538 - netlink_sendmsg+588 - sock_sendmsg+98 - __sys_sendto+275 - __x64_sys_sendto+36 - do_syscall_64+89 - entry_SYSCALL_64_after_hwframe+68 + dev_set_mac_address+1 + do_setlink+2217 + rtnl_setlink+246 + rtnetlink_rcv_msg+349 + netlink_rcv_skb+83 + rtnetlink_rcv+21 + netlink_unicast+538 + netlink_sendmsg+588 + sock_sendmsg+98 + __sys_sendto+275 + __x64_sys_sendto+36 + do_syscall_64+89 + entry_SYSCALL_64_after_hwframe+68 - systemd-udevd(7123) systemd-udevd(6656) + systemd-udevd(7123) systemd-udevd(6656) Invoked kprobe:bond_set_mac_address with MAC d2:29:6b:94:be:bd Stack trace: - bond_set_mac_address+1 - dev_set_mac_address_user+50 - do_setlink+2217 - rtnl_setlink+246 - rtnetlink_rcv_msg+349 - netlink_rcv_skb+83 - rtnetlink_rcv+21 - netlink_unicast+538 - netlink_sendmsg+588 - sock_sendmsg+98 - __sys_sendto+275 - __x64_sys_sendto+36 - do_syscall_64+89 - entry_SYSCALL_64_after_hwframe+68 + bond_set_mac_address+1 + dev_set_mac_address_user+50 + do_setlink+2217 + rtnl_setlink+246 + rtnetlink_rcv_msg+349 + netlink_rcv_skb+83 + rtnetlink_rcv+21 + netlink_unicast+538 + netlink_sendmsg+588 + sock_sendmsg+98 + __sys_sendto+275 + __x64_sys_sendto+36 + do_syscall_64+89 + entry_SYSCALL_64_after_hwframe+68 - ip(7137) sh(7135) python3(7013) twistd3(2045) web_install_ser(1959) + ip(7137) sh(7135) python3(7013) twistd3(2045) web_install_ser(1959) Invoked kprobe:dev_set_mac_address with MAC d2:29:6b:94:be:bd Stack trace: - dev_set_mac_address+1 - do_set_master+146 - do_setlink+684 - __rtnl_newlink+1560 - rtnl_newlink+73 - rtnetlink_rcv_msg+349 - netlink_rcv_skb+83 - rtnetlink_rcv+21 - netlink_unicast+538 - netlink_sendmsg+588 - sock_sendmsg+98 - ____sys_sendmsg+590 - ___sys_sendmsg+129 - __sys_sendmsg+98 - __x64_sys_sendmsg+29 - do_syscall_64+89 - entry_SYSCALL_64_after_hwframe+68 + dev_set_mac_address+1 + do_set_master+146 + do_setlink+684 + __rtnl_newlink+1560 + rtnl_newlink+73 + rtnetlink_rcv_msg+349 + netlink_rcv_skb+83 + rtnetlink_rcv+21 + netlink_unicast+538 + netlink_sendmsg+588 + sock_sendmsg+98 + ____sys_sendmsg+590 + ___sys_sendmsg+129 + __sys_sendmsg+98 + __x64_sys_sendmsg+29 + do_syscall_64+89 + entry_SYSCALL_64_after_hwframe+68 - ip(7137) sh(7135) python3(7013) twistd3(2045) web_install_ser(1959) + ip(7137) sh(7135) python3(7013) twistd3(2045) web_install_ser(1959) Invoked kprobe:vmxnet3_set_mac_addr with MAC d2:29:6b:94:be:bd Stack trace: - vmxnet3_set_mac_addr+1 - bond_enslave+1521 - do_set_master+146 - do_setlink+684 - __rtnl_newlink+1560 - rtnl_newlink+73 - rtnetlink_rcv_msg+349 - netlink_rcv_skb+83 - rtnetlink_rcv+21 - netlink_unicast+538 - netlink_sendmsg+588 - sock_sendmsg+98 - ____sys_sendmsg+590 - ___sys_sendmsg+129 - __sys_sendmsg+98 - __x64_sys_sendmsg+29 - do_syscall_64+89 - entry_SYSCALL_64_after_hwframe+68 - + vmxnet3_set_mac_addr+1 + bond_enslave+1521 + do_set_master+146 + do_setlink+684 + __rtnl_newlink+1560 + rtnl_newlink+73 + rtnetlink_rcv_msg+349 + netlink_rcv_skb+83 + rtnetlink_rcv+21 + netlink_unicast+538 + netlink_sendmsg+588 + sock_sendmsg+98 + ____sys_sendmsg+590 + ___sys_sendmsg+129 + __sys_sendmsg+98 + __x64_sys_sendmsg+29 + do_syscall_64+89 + entry_SYSCALL_64_after_hwframe+68 Not able to understand why this systemd rule is triggering and assigning MAC address randomly while we have a permanent Mac configured for that network interface . -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2104155 Title: systemd-udev interferes with MAC addresses of interfaces To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/2104155/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs