Hi there,
In an attempt to expose my container with a public floating IP from OVH, I successfully managed to make it work with macvlan nic type but failed with ipvlan type. This is new to me, maybe what I am just plain wrong. The IP is assigned to the correct interface but the MAC address I use on creation is not honored, with a random generated address instead.
Desired MAC address, xx:00:00:21:xx:0d
:
lxc config device add \
au-test-1 \
eth0 nic \
name=eth0 \
mode=l2 \
nictype=ipvlan \
parent=ens5f0 \
hwaddr=xx:00:00:21:xx:0d \
ipv4.address=xx.187.xx.170/32 \
ipv4.gateway=xx.178.xx.254
Created MAC address is different, xx:a9:fc:43:xx:b2
:
lxc exec au-test-1 -- ip addr show eth0
324: eth0@if2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN group default qlen 1000
link/ether xx:a9:fc:43:xx:b2 brd ff:ff:ff:ff:ff:ff
inet xx.187.xx.170/32 scope global eth0
valid_lft forever preferred_lft forever
inet6 xx::b4a9:fc00:xx:a4b2/64 scope link
valid_lft forever preferred_lft forever
I tried both l2
and l3s
modes with similar results. Attempting to unset and set the eth0
hwaddr
property from the container device has no effect.