It is possible to configure a vif-s interface, without a vif-c interface.
It is possible to configure a vif interface with the same VLAN ID as a vif-s inteface, that doesn't have a vif-c interface.
Like so:
ethernet eth1 { vif 100 { address 192.168.100.1/24 description "VLAN 100" } vif-s 100 { address 192.168.111.1/24 description "S-VLAN 100" } }
This will commit without problems.
From a configuration standpoint it is unclear what is going happen. From the code it is clear that vif-s will win and overwrite the configuration.
Also, what happens if we add a vif-c to the vif-s and a single tagged packet with VLAN 100 arrives to the interface? Should it be handled by vif or vif-s?
The code is clear on this, but the admin doesn't know from the config.
In my opinion, this is undesired.
There are several solutions to this:
- Always required vif-c with vif-s and disable ability to configure anything under vif-s
- Remove vif and only use vif-s/vif-c
- Allow configuration as it is, but trow an error if there is config for vif and vif-s with the same VLAN ID
I don't mind doing the coding for either option, but someone has to make a decision on the desired behaviour.