IP is not provided with Macvlan network in some images

I have some issues when launching these distributions so far in macvlan network type, is not assigning any IP (Attached Picture)

  • images:rockylinux/9
  • images:centos/7/arm64
  • images:centos/9-Stream/arm64
  • images:centos/9-Stream/cloud/arm64
incus launch images:rockylinux/9 rockylinux --network macvlan0

Is there any additional configuration I need to perform?

What does ip -4 a show inside those instances?

I don’t think this is an Incus issue so much as all of the listed instances where you’re not getting an address are those which use NetworkManager.

NetworkManager has had some issues getting addresses on macvlan devices before so that may be what’s going on here.

Hi Stéphane, thanks for your answer.

This is what I got when I run ip -4 a

I also have the same problem with busybox and almalinux 9

what would you recommend to use instead of NetworkManagerr?

Not sure why busybox isn’t happy but that one may be because it just doesn’t do network config out of the box.

Alma, CentOS, Rocky, … all will have the same issue as they all use NetworkManager.

Most of our working images use systemd-networkd so that may be a good alternative here even if the only fully supported option on those distros would normally be NetworkManager.

Is there any workaround for getting Alma/Rocky 9 working in a container using macvlan? There is a workaround in Macvlan Not Working for LXC centos/8 Container - #14 by stevenspencer but that uses the network-scripts package that does not exist anymore in EL9.

Hi @Viability,
You can install netplan package and convert NetworkManager rules to systemd-networkd can be used, it may be useful.
Regards.

Excuse my unawareness but neither netplan nor systemd-networkd are available in EL9, as far as dnf shows me in a search. Also i have been unable to find any articles online about how netplan might aid in converting NetworkManager rules to systemd-networkd

Hi,
You can use “epel” to install netplan package and the rest, something like this, dnf install epel-release
Regards.

1 Like