Changing the server motherboard

Hi,
I replaced the motherboard of a running server, now the two NIC cards have a new name:

  1. enp01 became enpos25, that’s where the lxdbr0 is based
  2. enp2s0 became enp4s0, it’s a static ip

now do a : sudo lxc start email-internal
got:error: Missing parent ‘enp2s0’ for nic ‘eth1’

surprisingly, it did not complain about missing enpos25 which is where eth0 is based, how to change this? Thanks

If the device is directly tied to the container, use lxc config edit CONTAINER-NAME.
If the device is inherited from a profile, then use lxc profile edit PROFILE-NAME.

In either case, you should see a “nic” device with the “parent” property pointing at that host device name. Update that to match the new name and you should be good to go.

1 Like