The current QOS awaits the changes in Gated that were not tracked by the gated 3.5 kernel.
case old route new route action ---- --------- --------- ------------------------------------------- 1 (none) IDRP Advertise. 2 (none) non-idrp Preference; Advertise if non-zero 3 IDRP IDRP Advertise new. This will implicitly w/draw old. Keep old idrpRoute unless it was explicitly withdrawn. 4 non-idrp non-idrp Preference; Advertise new if non-zero. This will implicitly w/draw old. Trash old idrpRoute since it's just added on for our convenience. If preference is zero, we need to explicitly withdraw the route. 5 non-idrp IDRP Advertise new. This will implicitly w/draw old. Trash old idrpRoute since it's just added on for our convenience. 6 IDRP non-idrp Preference; Advertise new if non-zero. This will implicitly w/draw old. Keep old idrpRoute unless it was explicitly withdrawn. If preference is zero, we need to explicitly withdraw the route. 7 IDRP (none) Delete idrpRoute. Send explicit withdrawal. 8 non-idrp (none) Delete idrpRoute. Send explicit withdrawal. ========Static Gated Routes to QOS
case old route new route QOS action ---- --------- --------- ------------------------------------------- 1 (none) IDRP None (qos active and last active will find the same information) 2 (none) non-idrp if Ok to advertise; then create qos routes 3 IDRP IDRP None (qos active and last active will find the same information) 4 non-idrp non-idrp Preference; create qos if non-zero. 5 non-idrp IDRP none 6 IDRP non-idrp Preference; create qos new if non-zero. 7 IDRP (none) Delete idrpRoute. (none) 8 non-idrp (none) Delete all qos routes related to this route. If qos is active or the damped route, then you cannot remove the route If neither, simply delete. (idrp_qos_del_routes())
ph3_create_ext_route()
.
1) if the QOS route is non-active, 1.1)if the route is the damped route - flag the delete in the route and the (STATUS_QOS_DELETE) 1.2) if the route is not the damped route, - delete the route from the gated tables 2) if the QOS route is active 2.1) move the route to last active 2.2) set the status flags STATUS_QOS_LASTACTIVE & STATUS_QOS_CHG 2.3) set the delete flag in the QOS flags (STATUS_QOS_DELETE) 3) if the QOS route is the last active route 3.1) if there is an active route, a) if this route is damped route -> set STATUS_QOS_DELETE b) if not, delete this route and clear out the last_active in the header 3.2) No active route - 1) is this route damped? - if so set delete on the IDRP route and the STATUS_QOS_DELETE 2) if this route is not damped, delete this route ?? why is it last active with no active route if not delete?qos_chg_active
Walk all ribs
for each rib
walk all attributes in attribute list
for each attribute - walk all routes in route list
for each route
IDRP_STATUS_QOS_ACTIVE
1)&& IDRP_STATUS_QOS_ROUTE_NEW - ph3_qos_case1
2)&& IDRP_STATUS_QOS_CHG - ph3_qos_case2
IDRP_STATUS_QOS_LASTACTIVE
1) active: if lastactive = delete
del_qos_route
2) not active:
ph3_qos_case7 --> handes damping
end of route loop
end of attribute loop
end of rib loop
Status bits for Routes
The states that QOS routes have are:
- IDRP_STATUS_QOS_NOTACTIVE (00)
- IDRP_STATUS_QOS_ACTIVE (01)
- IDRP_STATUS_QOS_LASTACTIVE (02)
- IDRP_STATUS_QOS_CHG
- IDRP_STATUS_QOS_NEW
The status bits from normal routes are:
IDRP_STATUS_ADJ_RIB 0x1 /* idrp Route AdjRib */
IDRP_STATUS_BEST_EXT 0x2 /* best exterior route */
IDRP_STATUS_LOC_RIB 0x4 /* idrp loc_RIB */
IDRP_STATUS_EXT_INFO 0x8 /* route entry handles ext_info */
IDRP_STATUS_WITH 0x10 /* withdraw set on this route */
IDRP_STATUS_DEL_SEND 0x20 /* delete after send route to peer */
IDRP_STATUS_MIN_ADV_CHG 0x40 /* change during min advertisement*/
IDRP_STATUS_REPLACE 0x80 /* withdrawal/replace */
IDRP_STATUS_DELETE 0x100 /* delete this route */
IDRP_STATUS_RECONFIGURE 0x200 /* reconfigure this route */
IDRP_STATUS_LOCAL_DAMP_DEL 0x400 /* deleted local route awaiting undamping to delete */
IDRP_STATUS_LOCAL_NEW_ROUTE 0x1000 /* local new route */
IDRP_STATUS_LOCAL_PH3_NEW_ROUTE 0x2000 /* local new route */
IDRP_STATUS_WITH_EARLY_PROC 0x4000 /* early processing of withdraw nlri with others */
IDRP_STATUS_REPLACE_PROC 0x8000 /* early processing of REPLACE */
IDRP_STATUS_IGP 0x10000 /* route was learned from the IGP. Doesn't */
IDRP_STATUS_LOCAL_RD 0x20000 /* comes from local RD */
IDRP_STATUS_DELETED 0x40000 /* this would happen if it were the old damped route, */
IDRP_STATUS_MIN_ADV_CHG_RDS 0x80000 /* change during min advertisement*/
IDRP_STATUS_RDLOOP 0x100000 /* nlri from loop deleted route - not installed not advised */
IDRP_STATUS_RID_BAD 0x200000 /* nlri from loop deleted route - not installed not advised */
Status changes
1) IDRP_STATUS_QOS_NOTACTIVE (and nothing else)
1.1) IDRP_STATUS RIB bits (IDRP_STATUS_ADJ_RIB | IDRP_STATUS_BEST_EXT | IDRP_STATUS_LOC_RIB)
1) IDRP_STATUS_ADJ_RIB - illegal
2) IDRP_STATUS_LOC_RIB - illegal
3) IDRP_STATUS_BEST_EXT - ok if external peer
1.2) Deletion bits
(IDRP_STATUS_WITH | IDRP_STATUS_DEL_SEND | IDRP_STATUS_DELETE | IDRP_STATUS_REPLACE)
1) IDRP_STATUS_WITH
2) IDRP_STATUS_DEL_SEND
3) IDRP_STATUS_DELETE
4) IDRP_STATUS_REPLACE
1.3) Damping bits & damping pointers
1) IDRP_STATUS_MIN_ADV_CHG
2) IDRP_STATUS_MIN_ADV_CHG_RDS
3) p_idrp_rt->p_idrp_damping[rib_id]
4) IDRP_STATUS_LOCAL_DAMP_DEL
1.4) Reconfiguration bits
1) IDRP_STATUS_RECONFIGURE
2) IDRP_STATUS_LOCAL_NEW_ROUTE
3) IDRP_STATUS_LOCAL_PH3_NEW_ROUTE
1.5) Processing flags
1) IDRP_STATUS_REPLACE_PROC
1.6) Flags for source or route processing
1) IDRP_STATUS_EXT_INFO
2) IDRP_STATUS_IGP
3) IDRP_STATUS_RD_LOOP - rd loop in BISPDU received (ignore route)
4) IDRP_STATUS_RID_BAD - route id bad
2)
The route will be delete