Step-5: undo step-1.0
Example configurations and preparation for maintenance-mode:
5.1. Grouping the interfaces at the given node based on their single-homing or multihoming capabilities #
In order to group interfaces having the same connectivity characteristics - single-homed or multihomed it's recommended to use the groups concept available in Junos
For example, the following groups for interfaces can be defined:
set groups GROUP-IF-CFG interfaces <*> disable
set groups GROUP-STAT-IF interfaces xe-0/0/8 apply-groups GROUP-IF-CFG
<…>
set groups GROUP-STRG-IF interfaces xe-0/0/13 apply-groups GROUP-IF-CFG
<…>
set groups GROUP-LACP-IF interfaces xe-0/0/21 apply-groups GROUP-IF-CFG
<…>
Make sure the interfaces and member LAG interfaces are enabled with the hold-time up.
Example:
set interfaces xe-0/0/13 hold-time up 120000 down 0
5.2. Enabling globally the policy statement to drain traffic from leaf:
set protocols bgp group IPFAB-OVERLAY vpn-apply-export
set policy-options policy-statement REJECT then reject
set policy-options policy-statement REJECT-T1 term term1 from family evpn
set policy-options policy-statement REJECT-T1 term term1 from nlri-route-type 1
set policy-options policy-statement REJECT-T1 term term1 then reject
set policy-options policy-statement REJECT-T1 then accept
commit comment "Preparation"
5.3. Drain for leaf when LAG/Bonding interface is used (ESI-LAG multihoming)
set protocols bgp group IPFAB-OVERLAY export REJECT-T1
commit comment "BGP export REJECT-T1"
set interfaces apply-groups GROUP-STRG-IF
set interfaces apply-groups GROUP-LACP-IF
commit comment "LACP interfaces down"
5.4. Bringing down the VTEP
delete protocols bgp group IPFAB-OVERLAY export
set protocols bgp group IPFAB-OVERLAY export REJECT
commit comment "BGP export REJECT"
5.5. Save rescue configs
run request system configuration rescue delete
run request system configuration rescue save
run show system commit
Then perform the operation on the given node ##
5.6. Undrain for the fabric leaf
delete protocols bgp group IPFAB-OVERLAY export
commit comment "BGP export"
# forerunner
set interfaces <forerunner interface> apply-groups-except GROUP-STAT-IF
commit comment "First Static Interface Up"
# bond STRG Up: before proceeding verify that remote vtep are up
delete interfaces apply-groups GROUP-STRG-IF
commit comment "bond Storage Up"
# bond LACP Up
delete interfaces apply-groups GROUP-LACP-IF
commit comment "LACP interfaces up"
# bond STATIC Up
delete interfaces apply-groups GROUP-STAT-IF
commit comment "Static Interface Up”
# Clean-up
delete interfaces <forerunner interface> apply-groups-except GROUP-STAT-IF
commit comment "Clean-up Undrain completed"