Commit Graph

14 Commits

Author SHA1 Message Date
d30f2d8965 Relax the LCP requirements - it is OK to have an address without an LCP 2022-04-03 09:04:11 +00:00
2415d30c0a Second part of a BVI refactor
The handling of BVI is awkward, with the autoderived interface name
"bviXX" based on the bridgedomain bd_id. Lots of special casing happens
on account of this decision, and to make matters worse there is poor
interaction (leading to VPP crashes) when BVIs and Loopbacks are used
at the same time: https://lists.fd.io/g/vpp-dev/message/21116

In this commit, I reintroduce the ability to set bridgedomain virtual
interfaces by means of the 'bvi' keyword. The 'bvi' must:
- be a Loopback interface
- must be used at most once (bvi_unique())

When pruning, I now need to prune bridgedomains before pruning
loopbacks, because any given loopback might be a BVI for a bridge. So,
I'll remove the loop/BVI from the bridge (by setting it to L3) and only
then removing the loopback from VPP.

In the reconciler, remove BVIs that have changed in prune_bridgedomains()
and set it in sync_bridgedomains().
2022-03-27 20:50:39 +00:00
850b982f2a First part of a BVI refactor
The handling of BVI is awkward, with the autoderived interface name
"bviXX" based on the bridgedomain bd_id. Lots of special casing happens
on account of this decision, and to make matters worse there is poor
interaction (leading to VPP crashes) when BVIs and Loopbacks are used
at the same time: https://lists.fd.io/g/vpp-dev/message/21116

This is step one of a refactor of the logic. In this commit, I'm
removing all of the BVI logic from the codebase, rendering bridgedomains
unable to have IP interfaces. In the next commit, I will introduce new
behavior in the schema, allowing for 'bvi' to be a loopback
interfacename which will be used as BVI for a bridgedomain, restoring
the ability to use bridgedomains with IP interfaces (using a loop).
2022-03-27 20:09:22 +00:00
78bd0c4f5a Assert BondEthernet devices also exist as interfaces. Assert MTU of members is equal to that of the BondEthernet interface 2022-03-27 12:29:57 +00:00
084094bb27 Add get_bvis() plus unittest 2022-03-26 22:45:52 +00:00
7bb9fa5ac8 Assert that a QinX cannot have higher MTU than its intermediate interface 2022-03-26 17:18:10 +00:00
660cccd14e Assert that bd0 is reserved 2022-03-26 11:25:13 +00:00
4666ba1611 Ensure bridgedomains exist in the YAML config before trying to look up BVIs in them 2022-03-24 21:57:39 +00:00
3a74a07ee6 Add get_by_bvi_name() and add a few hints on the difference between 'bridgename' (bd*) and 'bvi interfacename' (bvi*) 2022-03-24 21:38:13 +00:00
82bcb24d5e Add get_by_lcp_name() + tests 2022-03-24 20:38:28 +00:00
de9ed1730d Add get_by_lcp_name() plus tests. Correct behavior of sub-ints without explicit encap: they are exact-match 2022-03-24 20:14:06 +00:00
29a8bae899 Add get_bondethernets() 2022-03-24 16:34:45 +00:00
cfcbec239c Cosmetic rename instance of config/validator class 2022-03-24 15:05:15 +00:00
672dd65f11 Rename validator/ to config/ 2022-03-24 13:56:04 +00:00