canonical / lxd

Powerful system container and virtual machine manager
https://canonical.com/lxd
GNU Affero General Public License v3.0
4.38k stars 931 forks source link

Container on VLAN looses nic if another container on same vlan is shutdown #6416

Closed rudiservo closed 5 years ago

rudiservo commented 5 years ago

Issue description

on a trunk port with vlan config on profile, two containers are on profile, if I shutdown one container, the other one looses the nic interface remaining only the lo:

Steps to reproduce

  1. create a profile and edit devices i.e. devices: eth0: name: eth0 nictype: macvlan parent: enp3s0 type: nic vlan: "20"

  2. create two or more containers with that profile

  3. when both are up and have ip's, shutdown just one container and the other one will lose connection and the device

stgraber commented 5 years ago

Confirmed, though it looks like this only happens if you shutdown the first container first.

rudiservo commented 5 years ago

Fantastic, thank you ;)