In duplex-direct mode, the ifupdown VLAN configuration tries to
disable DAD using pre-up command 'sysctl -wq net.ipv6.conf.%s.accept_dad=0'
where %s is the vlan device and fails because the VLAN is not created yet.
This happens because Debian's ifupdown tool runs pre-up commands from
/etc/network/interface.d/ before running /etc/network/if-pre-up/vlan
script that creates the VLAN.
Moving the sysctl command to up or post-up won't avoid DAD to run.
The solution found is to add a VLAN creation command in pre-up before
the sysctl command.
Some bonding configuration was also being added to VLANs. Although it
was not causing any issues, it was fixed to be added only to the
bonding interfaces.
Test Plan:
PASS: Run new VLAN unit test for duplex-direct mode
PASS: Install duplex-direct system
Reviewed: https:/ /review. opendev. org/c/starlingx /config/ +/861205 /opendev. org/starlingx/ config/ commit/ a13a27c76707077 0b17bf4f9eb3739 43f54c3ced
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit a13a27c76707077 0b17bf4f9eb3739 43f54c3ced
Author: Caio Bruchert <email address hidden>
Date: Thu Oct 13 13:30:10 2022 -0300
Debian: fix VLAN creation in duplex-direct mode
In duplex-direct mode, the ifupdown VLAN configuration tries to conf.%s. accept_ dad=0'
disable DAD using pre-up command 'sysctl -wq net.ipv6.
where %s is the vlan device and fails because the VLAN is not created yet.
This happens because Debian's ifupdown tool runs pre-up commands from network/ interface. d/ before running /etc/network/ if-pre- up/vlan
/etc/
script that creates the VLAN.
Moving the sysctl command to up or post-up won't avoid DAD to run.
The solution found is to add a VLAN creation command in pre-up before
the sysctl command.
Some bonding configuration was also being added to VLANs. Although it
was not causing any issues, it was fixed to be added only to the
bonding interfaces.
Test Plan:
PASS: Run new VLAN unit test for duplex-direct mode
PASS: Install duplex-direct system
Closes-Bug: 1992832
Signed-off-by: Caio Bruchert <email address hidden> 84959039e85f2df a078ec0eb2c
Change-Id: Icbdd113e6051d5