Break into three sections

This commit is contained in:
Pim van Pelt
2022-03-23 17:16:29 +00:00
parent bcc4c8ff05
commit f37b80c012

View File

@ -112,9 +112,22 @@ Fields:
## Reconsiling ## Reconsiling
The second important task of this utility is to take the wellformed (validated) configuration and The second important task of this utility is to take the wellformed (validated) configuration and
apply it to the VPP dataplane. The overall flow is this: apply it to the VPP dataplane. The overall flow consists of three phases:
1. Prune phase (things in VPP that are not in the config), the order is: 1. Prune phase (things in VPP that are not in the config), the order is:
1. Create phase (things in the config that are not in VPP), the order is:
1. Sync phase, for each interface in the configuration
When removing things, care has to be taken to remove inner-most objects first. For example,
QinQ/QinAD sub-interfaces should be removed before before their intermediary Dot1Q/Dot1AD. Another
example, MTU of parents should raise before their children, while children should shrink before their
parent. Order matters, so first the tool will ensure all items do not have config which they should
not, then it will ensure that all items that are not yet present, get created in the right order,
and finally for all interfaces, they are synchronized with the configuratino (IP addresses, MTU etc).
### Pruning
1. Retrieve all LCP interfaces from VPP 1. Retrieve all LCP interfaces from VPP
* Starting with QinQ/QinAD, then Dot1Q/Dot1AD, then (BondEthernets, Tunnels, PHYs) * Starting with QinQ/QinAD, then Dot1Q/Dot1AD, then (BondEthernets, Tunnels, PHYs)
* Remove those that do not exist in the config * Remove those that do not exist in the config
@ -147,7 +160,9 @@ apply it to the VPP dataplane. The overall flow is this:
* And finally, for each PHY: * And finally, for each PHY:
* Remove all IP addresses that are not in the config * Remove all IP addresses that are not in the config
* If not in the config, return to default (L3 mode, MTU 9000, admin-state down) * If not in the config, return to default (L3 mode, MTU 9000, admin-state down)
1. Create phase (things in the config that are not in VPP), the order is:
### Creating
1. Loopbacks and BVIs 1. Loopbacks and BVIs
1. Bridge Domains 1. Bridge Domains
1. BondEthernets 1. BondEthernets
@ -155,7 +170,9 @@ apply it to the VPP dataplane. The overall flow is this:
1. Dot1Q and Dot1AD sub-interfaces 1. Dot1Q and Dot1AD sub-interfaces
1. Qin1Q and Qin1AD sub-interfaces 1. Qin1Q and Qin1AD sub-interfaces
1. LCP pairs 1. LCP pairs
1. Sync phase, for each interface in the configuration
### Syncing
1. For BondEthernets: 1. For BondEthernets:
* Set MTU of member interfaces * Set MTU of member interfaces
* Add them as slaves, lexicographically sorted by name * Add them as slaves, lexicographically sorted by name