When configuring an interface with the disable keyword and a saved config it is expected that the interface will stay admin down even after a reboot.
This is not the case, after a reboot the interface is admin up, besides the fact that the CLI tells us it is admin down.
To reproduce:
set interfaces ethernet eth2 vif 15 address 192.0.2.1/24 set interfaces ethernet eth2 vif 15 disable commit save
vyos@vyos:~$ show interfaces | match eth2.15 eth2.15 192.0.2.1/24 A/D vyos@vyos# run reboot now
After a reboot
vyos@vyos:~$ show interfaces | match eth2.15 eth2.15 192.0.2.1/24 u/D
Reproduce on crux
set interfaces ethernet eth1 vif 20 disable set interfaces ethernet eth1 disable commit
delete interfaces ethernet eth1 disable commit
This will automatically enable the sub interface
7: eth1.20@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000 link/ether 00:50:56:b3:09:07 brd ff:ff:ff:ff:ff:ff inet6 fe80::250:56ff:feb3:907/64 scope link valid_lft forever preferred_lft forever
Reproduce with iproute2
Using simple iproute2 commands:
ip link add link eth1 name eth1.20 type vlan id 20 ip link set dev eth1.20 down ip link set dev eth1 down ip link set dev eth1 up
98: eth1.20@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN group default qlen 1000 link/ether 00:50:56:bf:ef:aa brd ff:ff:ff:ff:ff:ff
Summary
The down state of an interface is not honored by iproute2 when the lower interface trnasitions from down -> up all subinterfaces (vlans) will be placed in admin-up state as well!