2024-11-03 Cat9000V GIR 機能検証
Nexus で採用され Catalyst 9000 から実装された GIR について、機能検証を実施しました。
このページにラボシナリオとして、コンフィグや確認コマンド、疎通確認のポイントなどをまとめています。
検証対象として Catalyst 9000V Q200 を使用していますが、実機の Catalyst 9000 シリーズでも同様の動作をするはずです。
目的
GIR の動作について理解を深められること。
通信要件
GIR : BGP / OSPF / HSRP
- GIR を開始したホストを経路迂回すること
- GIR を停止したホストに経路復旧すること
- 断時間がそこまで長くないこと
所感
メリット
- L3 プロトコルのどこを止めてルートを迂回させて・・・などと考えて切り離しのコンフィグを組む必要がない
- 断時間は非常に短く切り替えできた
- メンテナンスするプロトコルの順番を入れ替えられる
- 環境にもよると思われるが、基本的に上位プロトコルから実施したほうが良さそう
- 切り戻し (Insert) は切り替えの逆順で実施してくれる
考慮点
- GIR 導入後にコンフィグを変更した際、GIR にも変更が必要になるケースがあるので、変更を忘れないようにする
- HSRP で新 Group を追加した、など
- いったんメンテナンスを開始 (Remove) すると、手を出すことができない
- 新規導入時に動作検証を実施し、挙動を確認したほうが良い
- メンテナンス中はコンフィグ変更が可能
- 切り戻せないコンフィグにした場合、stop maintenance しても切り戻りと判定してくれないため注意が必要
- 基本的には OS Verup などコンフィグ変更しないメンテナンスを対象に GIR を使うのが良さそう
- メンテナンス停止 (Insert) 中は、コンフィグを変更できない
- failsafe は今回挙動を確認できなかった
- snapshot 機能は今回の Version に実装されていない模様
検証結果概要
プロトコル別の挙動
ピア・ネイバー・ステート | ルート | メトリック | 備考 | |
---|---|---|---|---|
BGP | 保持される | 広報が停止される | - | BGP はアトリビュートが非常に多いため、ルートの広報をやめる実装になっていると思われる。
今回のユースケースでは断時間は非常に短かったため、問題にはなりにくいと考えられる。 |
OSPF | 保持される | 広報する | 65536 になる | ネイバーが保持され、ルートも削除されない。
ルートのメトリックは最低値になるため、優先度を低下する実装となっている。 OSPF で学習する Loopback を telnet 用アドレスとして管理する環境も多いため、好ましい実装と言える。 |
HSRP | Resign メッセージを送信する
Active -> Init になる Hello も送信しなくなる |
- | - | HSRP Active から降格する際、Resign メッセージを送信しているため、Standby が素早く Active へ昇格することが可能。
断時間を短く切り替えが可能となっている。 |
その他
- start maintenance 中の再起動 : stop maintenance 状態で起動する
検証環境
Cisco Catalyst 9000V Q200 : IOS-XE 17.12.1 x6
構成図
- Catalyst 3850 : PE01 , CE01 , CE02 , CORE01 , CORE02 , CPE01
PE01 を WAN の機器、CE01 , CE02 , CORE01 , CORE02 , CPE を LAN の機器とする。
IP アドレッシング
文書用例示アドレス (8.8.8.8 を除く) | ||||||
---|---|---|---|---|---|---|
大種別 | 小種別 | ネットワーク アドレス | ホスト | インターフェース | ホスト アドレス | 備考 |
グローバルアドレス | WAN グローバルアドレス | 203.0.113.128/30 | PE01 | Gi1/0/1 | 203.0.113.129/30 | BGP でデフォルトルートを広報 |
CE01 | Gi1/0/23 | 203.0.113.130/30 | PE ルータからデフォルトルートを受信 | |||
203.0.113.132/30 | PE01 | Gi1/0/1 | 203.0.113.133/30 | BGP でデフォルトルートを広報 | ||
CE02 | Gi1/0/23 | 203.0.113.134/30 | PE ルータからデフォルトルートを受信 | |||
198.51.100.0/24 | PE01 | Lo0 | 198.51.100.1/32 | 上り方向 ping の宛先 | ||
LAN グローバル アドレス | CE01 | Lo0 | 198.51.100.11/32 | iBGP ピア用 | ||
CE02 | Lo0 | 198.51.100.12/32 | iBGP ピア用 | |||
CORE01 | Lo0 | 198.51.100.21/32 | ||||
CORE02 | Lo0 | 198.51.100.22/32 | ||||
203.0.113.128/25 | CE01 | Po21 | 203.0.113.137/30 | CE01 <-> CE02 間わたり OSPF P2P リンク
迂回経路用 | ||
CE02 | Po21 | 203.0.113.138/30 | ||||
CE01 | Gi1/0/1 | 203.0.113.141/30 | CE01 <-> CORE01 間 OSPF P2P リンク | |||
CORE01 | Gi1/0/23 | 203.0.113.142/30 | ||||
CE02 | Gi1/0/2 | 203.0.113.145/30 | CE02 <-> CORE02 間 OSPF P2P リンク | |||
CORE02 | Gi1/0/24 | 203.0.113.146/30 | ||||
CE01 | Po21 | 203.0.113.149/30 | CORE01 <-> CORE02 間 OSPF P2P リンク
迂回経路用 | |||
CE02 | Po21 | 203.0.113.150/30 | ||||
203.0.113.0/25 | CE01 | Vlan1 | 203.0.113.2/25
HSRP .1 |
CPE 収容 SVI | ||
CE02 | Vlan1 | 203.0.113.3/25
HSRP .1 |
CPE 収容 SVI | |||
CPE | Vlan1 | 203.0.113.101/25 | CPE01 用ホストアドレス | |||
プライベートアドレス | LAN プライベート アドレス | なし |
コンフィギュレーション
ここではプロトコル・ホスト別にコンフィギュレーションを簡単に解説します。
自分でコンフィグを組んでみたい人向けに、デフォルトでは表示しません。
PE01
プロトコル | PE01 コンフィグ | 解説 |
---|---|---|
eBGP |
PE01#show run | s back0|net1/0/[1-2]$|router bgp|ip route 0 interface Loopback0 ip address 198.51.100.1 255.255.255.255 interface GigabitEthernet1/0/1 description CE01_Gi1/0/23 no switchport ip address 203.0.113.129 255.255.255.252 interface GigabitEthernet1/0/2 description CE02_Gi1/0/23 no switchport ip address 203.0.113.133 255.255.255.252 router bgp 64496 bgp router-id 198.51.100.1 bgp log-neighbor-changes bgp deterministic-med timers bgp 10 30 neighbor 203.0.113.130 remote-as 64512 neighbor 203.0.113.130 description CE01 neighbor 203.0.113.130 default-originate neighbor 203.0.113.130 soft-reconfiguration inbound neighbor 203.0.113.134 remote-as 64512 neighbor 203.0.113.134 description CE02 neighbor 203.0.113.134 default-originate neighbor 203.0.113.134 soft-reconfiguration inbound ip route 0.0.0.0 0.0.0.0 Null0 254 |
CE01 , 02 と eBGP ピアを張るための設定 |
CE01 , 02
プロトコル | CE01 コンフィグ | CE02 コンフィグ | 解説 |
---|---|---|---|
eBGP |
CE01#show run | s back0|net1/0/23$|^router bgp|route-map interface Loopback0 ip address 198.51.100.11 255.255.255.255 interface GigabitEthernet1/0/23 description PE01_Gi1/0/1 no switchport ip address 203.0.113.130 255.255.255.252 router bgp 64512 bgp router-id 198.51.100.11 bgp log-neighbor-changes bgp deterministic-med network 203.0.113.0 mask 255.255.255.128 timers bgp 10 30 neighbor 198.51.100.12 remote-as 64512 neighbor 198.51.100.12 description CE02 neighbor 198.51.100.12 update-source Loopback0 neighbor 198.51.100.12 next-hop-self neighbor 198.51.100.12 soft-reconfiguration inbound neighbor 203.0.113.129 remote-as 64496 neighbor 203.0.113.129 description PE01 neighbor 203.0.113.129 soft-reconfiguration inbound neighbor 203.0.113.129 route-map LP300 in neighbor 203.0.113.129 route-map MED100 out route-map LP300 permit 10 set local-preference 300 route-map MED100 permit 10 set metric 100 |
CE02#show run | s back0|net1/0/23$|^router bgp|route-map interface Loopback0 ip address 198.51.100.12 255.255.255.255 interface GigabitEthernet1/0/23 description PE01_Gi1/0/2 no switchport ip address 203.0.113.134 255.255.255.252 router bgp 64512 bgp router-id 198.51.100.12 bgp log-neighbor-changes bgp deterministic-med network 203.0.113.0 mask 255.255.255.128 timers bgp 10 30 neighbor 198.51.100.11 remote-as 64512 neighbor 198.51.100.11 description CE01 neighbor 198.51.100.11 update-source Loopback0 neighbor 198.51.100.11 next-hop-self neighbor 198.51.100.11 soft-reconfiguration inbound neighbor 203.0.113.133 remote-as 64496 neighbor 203.0.113.133 description PE01 neighbor 203.0.113.133 soft-reconfiguration inbound neighbor 203.0.113.133 route-map LP100 in neighbor 203.0.113.133 route-map MED300 out route-map MED300 permit 10 set metric 300 route-map LP100 permit 10 set local-preference 100 |
PE01 と eBGP ピア、
CE01 と CE02 で iBGP ピアを張るコンフィグ
LP300 で上りトラフィックを優先する 値が高いほうが優先
MED100 で下りトラフィックを優先する 値が低いほうが優先 |
OSPF |
CE01#show run | s net1/0/1$|net1/0/2[1-2]$|el21|^router ospf interface Port-channel21 description CE02_Po21 no switchport ip address 203.0.113.137 255.255.255.252 ip ospf network point-to-point ip ospf cost 100 interface GigabitEthernet1/0/1 description CORE01_Gi1/0/23 no switchport ip address 203.0.113.141 255.255.255.252 ip ospf network point-to-point ip ospf cost 1 interface GigabitEthernet1/0/21 description CE02_Gi1/0/21 no switchport no ip address channel-group 21 mode active interface GigabitEthernet1/0/22 description CE02_Gi1/0/22 no switchport no ip address channel-group 21 mode active router ospf 1 router-id 198.51.100.11 passive-interface default no passive-interface GigabitEthernet1/0/1 no passive-interface Port-channel21 network 198.51.100.11 0.0.0.0 area 0.0.0.0 network 203.0.113.136 0.0.0.3 area 0.0.0.0 network 203.0.113.140 0.0.0.3 area 0.0.0.0 default-information originate metric 1 metric-type 1 |
CE02#show run | s net1/0/2$|net1/0/2[1-2]$|el21|^router ospf interface Port-channel21 description CE01_Po21 no switchport ip address 203.0.113.138 255.255.255.252 ip ospf network point-to-point ip ospf cost 100 interface GigabitEthernet1/0/2 description CORE02_Gi1/0/24 no switchport ip address 203.0.113.145 255.255.255.252 ip ospf network point-to-point ip ospf cost 40 interface GigabitEthernet1/0/21 description CE01_Gi1/0/21 no switchport no ip address channel-group 21 mode active interface GigabitEthernet1/0/22 description CE01_Gi1/0/22 no switchport no ip address channel-group 21 mode active router ospf 1 router-id 198.51.100.12 passive-interface default no passive-interface GigabitEthernet1/0/2 no passive-interface Port-channel21 network 198.51.100.12 0.0.0.0 area 0.0.0.0 network 203.0.113.144 0.0.0.3 area 0.0.0.0 network 203.0.113.128 0.0.0.127 area 0.0.0.0 default-information originate metric 100 metric-type 1 |
CE01 , 02 間
CE01 , 02 <-> CORE01 , 02 間 OSPF
|
GIR |
CE01#show run | s mainte maintenance-template BGP_OSPF router bgp 64512 router ospf 1 system mode maintenance timeout 15 template BGP_OSPF failsafe 5 |
CE02#show run | s mainte maintenance-template BGP_OSPF router bgp 64512 router ospf 1 system mode maintenance timeout 15 template BGP_OSPF failsafe 5 |
GIR で BGP と OSPF を切り替える
timeout 15 メンテナンス時間を設定します 15 は分を意味しています タイムアウトすると、stop maintenance が実行され、切り戻ります failsafe 5 不明 |
種別 | CORE01 コンフィグ | CORE02 コンフィグ | 解説 |
---|---|---|---|
OSPF |
CORE01#show run | s net1/0/2[1-2]$|el21|^router ospf interface Port-channel21 description CORE02_Po21 no switchport ip address 203.0.113.149 255.255.255.252 ip ospf network point-to-point ip ospf cost 50 interface GigabitEthernet1/0/21 description CORE02_Gi1/0/21 no switchport no ip address channel-group 21 mode active interface GigabitEthernet1/0/22 description CORE02_Gi1/0/22 no switchport no ip address channel-group 21 mode active router ospf 1 router-id 198.51.100.21 passive-interface default no passive-interface GigabitEthernet1/0/23 no passive-interface Port-channel21 network 198.51.100.21 0.0.0.0 area 0.0.0.0 network 203.0.113.0 0.0.0.127 area 0.0.0.0 network 203.0.113.140 0.0.0.3 area 0.0.0.0 network 203.0.113.148 0.0.0.3 area 0.0.0.0 |
CORE02#show run | s net1/0/2[1-2]$|el21|^router ospf interface Port-channel21 description CORE01_Po21 no switchport ip address 203.0.113.150 255.255.255.252 ip ospf network point-to-point ip ospf cost 50 interface GigabitEthernet1/0/21 description CORE01_GI1/0/21 no switchport no ip address channel-group 21 mode active interface GigabitEthernet1/0/22 description CORE01_GI1/0/22 no switchport no ip address channel-group 21 mode active router ospf 1 router-id 198.51.100.22 passive-interface default no passive-interface GigabitEthernet1/0/24 no passive-interface Port-channel21 network 198.51.100.22 0.0.0.0 area 0.0.0.0 network 203.0.113.0 0.0.0.127 area 0.0.0.0 network 203.0.113.144 0.0.0.3 area 0.0.0.0 network 203.0.113.148 0.0.0.3 area 0.0.0.0 |
CE01 , 02 から
OSPF デフォルトルートを 受信するための設定 |
HSRP |
CORE01#show run | s net1/0/1$|Vlan1$ interface GigabitEthernet1/0/1 description CPE01_Gi1/0/23 switchport mode access switchport nonegotiate spanning-tree portfast spanning-tree bpdufilter enable interface Vlan1 ip address 203.0.113.2 255.255.255.128 standby version 2 standby 1 ip 203.0.113.1 standby 1 priority 110 standby 1 preempt |
CORE02#show run | s net1/0/1$|Vlan1$ interface GigabitEthernet1/0/1 description CPE01_Gi1/0/24 switchport mode access switchport nonegotiate spanning-tree portfast spanning-tree bpdufilter enable interface Vlan1 ip address 203.0.113.3 255.255.255.128 standby version 2 standby 1 ip 203.0.113.1 standby 1 priority 105 standby 1 preempt |
CPE01 を HSRP で
収容するための設定 |
GIR |
CORE01#show run | s mainte maintenance-template OSPF_HSRP router ospf 1 hsrp Vlan1 1 system mode maintenance timeout 15 template OSPF_HSRP failsafe 5 |
CORE02#show run | s mainte maintenance-template OSPF_HSRP router ospf 1 hsrp Vlan1 1 system mode maintenance timeout 15 template OSPF_HSRP failsafe 5 |
GIR で OSPF と HSRP を切り替える |
種別 | CPE01 コンフィグ | 解説 |
---|---|---|
ホスト |
CPE01#show run | s net1/0/2[3-4]|Vlan1|ip route 0 interface GigabitEthernet1/0/23 description CORE01_Gi1/0/1 switchport mode access switchport nonegotiate spanning-tree portfast spanning-tree bpdufilter enable interface GigabitEthernet1/0/24 description CORE02_Gi1/0/1 switchport mode access switchport nonegotiate spanning-tree portfast spanning-tree bpdufilter enable interface Vlan1 ip address 203.0.113.101 255.255.255.128 ip route 0.0.0.0 0.0.0.0 203.0.113.1 |
CORE01 , 02 の HSRP VIP に対してデフォルトルートを設定 |
正常時の疎通・経路確認
コマンドリスト
PE01
PE01#ping 203.0.113.101 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 203.0.113.101, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 70/87/103 ms PE01# PE01#traceroute 203.0.113.101 Type escape sequence to abort. Tracing the route to 203.0.113.101 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.130 40 msec 40 msec 38 msec 2 203.0.113.142 81 msec 54 msec 61 msec 3 203.0.113.101 [AS 64512] 103 msec * 105 msec
通常時は CE01 -> CORE01 -> CPE01 を経由します。
PE01#show ip bgp BGP table version is 11, local router ID is 198.51.100.1 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, t secondary path, L long-lived-stale, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path 0.0.0.0 0.0.0.0 0 i *> 203.0.113.0/25 203.0.113.130 100 0 64512 i * 203.0.113.134 300 0 64512 i
CE01 宛を優先させています。
CORE01
CORE01#show ip route 0.0.0.0 Routing entry for 0.0.0.0/0, supernet Known via "ospf 1", distance 110, metric 2, candidate default path Tag 1, type extern 1 Last update from 203.0.113.141 on GigabitEthernet1/0/23, 00:01:20 ago Routing Descriptor Blocks: * 203.0.113.141, from 198.51.100.11, 00:01:20 ago, via GigabitEthernet1/0/23 Route metric is 2, traffic share count is 1 Route tag 1 CORE01# CORE01#show standby brief P indicates configured to preempt. | Interface Grp Pri P State Active Standby Virtual IP Vl1 1 110 P Active local 203.0.113.3 203.0.113.1
OSPF メトリック 1 と HSRP Priority 110 で優先させています。
CPE01
CPE01#ping 198.51.100.1 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 198.51.100.1, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 77/87/109 ms CPE01# CPE01#traceroute 198.51.100.1 Type escape sequence to abort. Tracing the route to 198.51.100.1 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.2 40 msec 41 msec 72 msec 2 203.0.113.141 63 msec 66 msec 69 msec 3 203.0.113.129 89 msec * 84 msec
通常時は CORE01 -> CE01 -> PE01 を経由します。
CE01 GIR BGP + OSPF 動作確認
start maintenance でホストを Remove します。
CE01#start maintenance Template BGP_OSPF will be applied. Do you want to continue?[confirm] CE01# Nov 3 2024 00:43:52 UTC: %MMODE-6-MMODE_SNAPSHOT_CREATE_ENTER_MMODE: Generating current snapshot 'before_maintenance' Nov 3 2024 00:43:52 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Isolate start for router bgp 64512 Nov 3 2024 00:44:23 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Isolate complete for router bgp 64512 Nov 3 2024 00:44:23 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Isolate start for router ospf 1 Nov 3 2024 00:44:53 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Isolate complete for router ospf 1 Nov 3 2024 00:44:53 UTC: %MMODE-6-MMODE_ISOLATED: System is in Maintenance CE01(maint-mode)#show system mode System Mode: Maintenance Maintenance window: 14 mins remaining CE01(maint-mode)#show system mode maintenance System Mode: Maintenance Maintenance window: 14 mins remaining Current Maintenance Parameters: Maintenance Duration: 15(mins) Failsafe Timeout: 5(mins) Maintenance Template: BGP_OSPF Snapshot Template: default Reload in Maintenance: False
確認 | 通常時 | CE01 メンテナンス時 | 備考 |
---|---|---|---|
BGP |
PE01#traceroute 203.0.113.101 Type escape sequence to abort. Tracing the route to 203.0.113.101 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.130 39 msec 65 msec 37 msec 2 203.0.113.142 66 msec 75 msec 67 msec 3 203.0.113.101 [AS 64512] 94 msec * 94 msec PE01#show ip bgp BGP table version is 13, local router ID is 198.51.100.1 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, t secondary path, L long-lived-stale, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path 0.0.0.0 0.0.0.0 0 i *> 203.0.113.0/25 203.0.113.130 100 0 64512 i * 203.0.113.134 300 0 64512 i |
PE01#traceroute 203.0.113.101 Type escape sequence to abort. Tracing the route to 203.0.113.101 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.134 50 msec 30 msec 35 msec 2 203.0.113.146 57 msec 67 msec 67 msec 3 203.0.113.101 [AS 64512] 125 msec * 135 msec PE01# PE01#show ip bgp BGP table version is 8, local router ID is 198.51.100.1 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, t secondary path, L long-lived-stale, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path 0.0.0.0 0.0.0.0 0 i *> 203.0.113.0/25 203.0.113.134 300 0 64512 i |
上り : CPE01
CORE01 はわたりを経由するように変更されています。
PE01 は CE02 を経由するように変更されています。 CE01 の Next Hop がなくなっており、BGP アドレス広報を停止していました。 |
CE01#show ip bgp summary BGP router identifier 198.51.100.11, local AS number 64512 BGP table version is 3, main routing table version 3 2 network entries using 496 bytes of memory 4 path entries using 544 bytes of memory 4/2 BGP path/bestpath attribute entries using 1184 bytes of memory 1 BGP AS-PATH entries using 24 bytes of memory 0 BGP route-map cache entries using 0 bytes of memory 0 BGP filter-list cache entries using 0 bytes of memory BGP using 2248 total bytes of memory 1 received paths for inbound soft reconfiguration BGP activity 2/0 prefixes, 4/0 paths, scan interval 60 secs 2 networks peaked at 08:12:30 Nov 4 2024 JST (00:02:19.633 ago) Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd 198.51.100.12 4 64512 24 24 3 0 0 00:03:04 1 203.0.113.129 4 64496 20 19 3 0 0 00:02:19 1 CE01#show ip bgp BGP table version is 3, local router ID is 198.51.100.11 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, t secondary path, L long-lived-stale, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path *> 0.0.0.0 203.0.113.129 300 0 64496 i *> 203.0.113.0/25 203.0.113.142 2 32768 i * i 198.51.100.12 41 100 0 i |
CE01(maint-mode)#show ip bgp summary BGP router identifier 198.51.100.11, local AS number 64512 BGP table version is 20, main routing table version 20 2 network entries using 496 bytes of memory 5 path entries using 680 bytes of memory 5/2 BGP path/bestpath attribute entries using 1480 bytes of memory 1 BGP AS-PATH entries using 24 bytes of memory 0 BGP route-map cache entries using 0 bytes of memory 0 BGP filter-list cache entries using 0 bytes of memory BGP using 2680 total bytes of memory 1 received paths for inbound soft reconfiguration BGP activity 5/3 prefixes, 22/17 paths, scan interval 60 secs 2 networks peaked at 08:12:51 Nov 3 2024 JST (03:45:55.560 ago) Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd 198.51.100.12 4 64512 153 160 20 0 0 00:22:50 2 203.0.113.129 4 64496 155 159 20 0 0 00:23:14 1 CE01(maint-mode)#show ip bgp BGP table version is 20, local router ID is 198.51.100.11 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, t secondary path, L long-lived-stale, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path * i 0.0.0.0 198.51.100.12 0 100 0 64496 i *> 203.0.113.129 300 0 64496 i * i 203.0.113.0/25 198.51.100.12 41 100 0 i *> 203.0.113.142 65536 32768 i |
BGP ピア
ピアは維持されます。 eBGP 受信ルート ルート自体は保持しています。 | |
OSPF |
CE02#show ip route 0.0.0.0 Routing entry for 0.0.0.0/0, supernet Known via "ospf 1", distance 110, metric 81, candidate default path Tag 1, type extern 1 Last update from 203.0.113.137 on Port-channel21, 00:00:20 ago Routing Descriptor Blocks: * 203.0.113.137, from 198.51.100.11, 00:00:20 ago, via Port-channel21 Route metric is 81, traffic share count is 1 Route tag 1 |
CE02#show ip route 0.0.0.0 Routing entry for 0.0.0.0/0, supernet Known via "bgp 64512", distance 20, metric 0, candidate default path Tag 64496, type external Last update from 203.0.113.133 00:00:07 ago Routing Descriptor Blocks: * 203.0.113.133, from 203.0.113.133, 00:00:07 ago opaque_ptr 0x7477AABBBCC0 Route metric is 0, traffic share count is 1 AS Hops 1 Route tag 64496 MPLS label: none |
上り : CE02
通常時は CE01 宛わたり Po21 を向いていますが、CE01 GIR 中は PE01 宛 203.0.113.133 を向いています。 |
CORE01#show ip route 0.0.0.0 Routing entry for 0.0.0.0/0, supernet Known via "ospf 1", distance 110, metric 2, candidate default path Tag 1, type extern 1 Last update from 203.0.113.141 on GigabitEthernet1/0/23, 00:07:11 ago Routing Descriptor Blocks: * 203.0.113.141, from 198.51.100.11, 00:07:11 ago, via GigabitEthernet1/0/23 Route metric is 2, traffic share count is 1 Route tag 1 CORE01#show ip ospf 1 rib OSPF Router with ID (198.51.100.21) (Process ID 1) Base Topology (MTID 0) OSPF local RIB Codes: * - Best, > - Installed in global RIB *> 198.51.100.11/32, Intra, cost 65536, area 0.0.0.0 via 203.0.113.141, GigabitEthernet1/0/23 *> 198.51.100.12/32, Intra, cost 91, area 0.0.0.0 via 203.0.113.150, Port-channel21 <snip> CORE01#ping 198.51.100.11 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 198.51.100.11, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 19/25/35 ms |
CORE01#show ip route 0.0.0.0 Routing entry for 0.0.0.0/0, supernet Known via "ospf 1", distance 110, metric 190, candidate default path Tag 1, type extern 1 Last update from 203.0.113.150 on Port-channel21, 00:00:06 ago Routing Descriptor Blocks: * 203.0.113.150, from 198.51.100.12, 00:00:06 ago, via Port-channel21 Route metric is 190, traffic share count is 1 Route tag 1 |
上り : CORE01
CE01 Lo0 ルートの OSPF コスト メトリックが 65536 になっており、重くなっていますが、疎通自体は可能です。 | |
CPE01#traceroute 198.51.100.1 Type escape sequence to abort. Tracing the route to 198.51.100.1 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.2 71 msec 73 msec 65 msec 2 203.0.113.141 82 msec 53 msec 55 msec 3 203.0.113.129 66 msec * 80 msec |
CPE01#traceroute 198.51.100.1 Type escape sequence to abort. Tracing the route to 198.51.100.1 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.2 37 msec 69 msec 38 msec 2 203.0.113.150 93 msec 86 msec 88 msec 3 203.0.113.145 109 msec 110 msec 111 msec 4 203.0.113.133 213 msec * 154 msec |
上り : CPE01
CORE01 のわたりを経由するようになりました。 |
timeout 15 経過後、切り戻りました。
CE01(maint-mode)# Nov 3 2024 23:52:04 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Insert start for router ospf 1 Nov 3 2024 23:52:34 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Insert complete for router ospf 1 Nov 3 2024 23:52:34 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Insert start for router bgp 64512 Nov 3 2024 23:53:04 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Insert complete for router bgp 64512 Nov 3 2024 23:53:04 UTC: %MMODE-6-MMODE_SNAPSHOT_CREATE_EXIT_MMODE: Generating current snapshot 'after_maintenance' Please use 'show system snapshots compare before_maintenance after_maintenance' to check the health of the system Nov 3 2024 23:53:04 UTC: %MMODE-6-MMODE_INSERTED: System is in Normal Mode
CORE01 GIR OSPF + HSRP 動作確認
start maintenance でホストを Remove します。
CORE01#start maintenance Template OSPF_HSRP will be applied. Do you want to continue?[confirm] CORE01# Nov 3 2024 23:55:21 UTC: %MMODE-6-MMODE_SNAPSHOT_CREATE_ENTER_MMODE: Generating current snapshot 'before_maintenance' Nov 3 2024 23:55:21 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Isolate start for router ospf 1 Nov 3 2024 23:55:51 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Isolate complete for router ospf 1 Nov 3 2024 23:55:51 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Isolate start for hsrp Vlan1 1 Nov 3 2024 23:55:51 UTC: %HSRP-5-STATECHANGE: Vlan1 Grp 1 state Active -> Init Nov 3 2024 23:56:21 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Isolate complete for hsrp Vlan1 1 Nov 3 2024 23:56:21 UTC: %MMODE-6-MMODE_ISOLATED: System is in Maintenance CORE01(maint-mode)#show system mode System Mode: Maintenance Maintenance window: 14 mins remaining CORE01(maint-mode)#show system mode maintenance System Mode: Maintenance Maintenance window: 14 mins remaining Current Maintenance Parameters: Maintenance Duration: 15(mins) Failsafe Timeout: 5(mins) Maintenance Template: OSPF_HSRP Snapshot Template: default Reload in Maintenance: False
確認 | 通常時 | CORE01 メンテナンス時 | 備考 |
---|---|---|---|
OSPF |
CE01#show ip route 198.51.100.21 Routing entry for 198.51.100.21/32 Known via "ospf 1", distance 110, metric 2, type intra area Last update from 203.0.113.142 on GigabitEthernet1/0/1, 00:00:07 ago Routing Descriptor Blocks: * 203.0.113.142, from 198.51.100.21, 00:00:07 ago, via GigabitEthernet1/0/1 Route metric is 2, traffic share count is 1 |
CE01#show ip route 198.51.100.21 Routing entry for 198.51.100.21/32 Known via "ospf 1", distance 110, metric 65536, type intra area Last update from 203.0.113.142 on GigabitEthernet1/0/1, 00:02:42 ago Routing Descriptor Blocks: * 203.0.113.142, from 198.51.100.21, 00:02:42 ago, via GigabitEthernet1/0/1 Route metric is 65536, traffic share count is 1 |
OSPF ルートメトリック
65536 になっており、全く優先されないルートになりました。 上述の結果と同じく疎通は可能です。 |
HSRP |
CORE01#show standby brief P indicates configured to preempt. | Interface Grp Pri P State Active Standby Virtual IP Vl1 1 110 P Active local 203.0.113.3 203.0.113.1 |
CORE01(maint-mode)#show standby brief P indicates configured to preempt. | Interface Grp Pri P State Active Standby Virtual IP Vl1 1 110 P Init 203.0.113.3 unknown 203.0.113.1 Nov 4 2024 00:04:55 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_COMPLETE: Maintenance Isolate complete for router ospf 1 Nov 4 2024 00:04:55 UTC: %MMODE-6-MMODE_CLIENT_TRANSITION_START: Maintenance Isolate start for hsrp Vlan1 1 Nov 4 2024 00:04:55 UTC: HSRP: Vl1 Grp 1 Resign out 203.0.113.2 Active pri 110 vIP 203.0.113.1 Nov 4 2024 00:04:55 UTC: %HSRP-5-STATECHANGE: Vlan1 Grp 1 state Active -> Init |
HSRP
Resign メッセージを送信し、降格しました。 State が Init となっており、HSRP Hello を送信しなくなりました。 |
CORE02#show standby brief P indicates configured to preempt. | Interface Grp Pri P State Active Standby Virtual IP Vl1 1 105 P Standby 203.0.113.2 local 203.0.113.1 |
CORE02#show standby brief P indicates configured to preempt. | Interface Grp Pri P State Active Standby Virtual IP Vl1 1 105 P Active local unknown 203.0.113.1 |
上り : CORE02
CORE01 が HSRP Hello を送信しなくなったため、Standby が unknown になりました。 | |
CPE01#traceroute 198.51.100.1 Type escape sequence to abort. Tracing the route to 198.51.100.1 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.2 48 msec 43 msec 83 msec 2 203.0.113.141 72 msec 78 msec 58 msec 3 203.0.113.129 82 msec * 78 msec |
CPE01#traceroute 198.51.100.1 Type escape sequence to abort. Tracing the route to 198.51.100.1 VRF info: (vrf in name/id, vrf out name/id) 1 203.0.113.3 47 msec 38 msec 48 msec 2 203.0.113.145 63 msec 63 msec 55 msec 3 203.0.113.137 79 msec 98 msec 90 msec 4 203.0.113.129 111 msec * 113 msec CPE01#ping 198.51.100.1 rep 1000000 tim 1 Type escape sequence to abort. Sending 1000000, 100-byte ICMP Echos to 198.51.100.1, timeout is 1 seconds: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !.!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!.!!!!!! <snip> CPE01#ping 198.51.100.1 rep 1000000 tim 1 Type escape sequence to abort. Sending 1000000, 100-byte ICMP Echos to 198.51.100.1, timeout is 1 seconds: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!.!!!!! |
上り : CPE01
CE01 のわたりを経由するようになりました。 Remove / Insert 時の断時間は OSPF / HSRP でそれぞれ 1 秒でした。 断時間が計測できないケースもありました。
|
動作確認 - ホスト別コマンドリスト
PE01
show ip bgp summary
show ip bgp
ping 203.0.113.101
traceroute 203.0.113.101
CE01 . CE02
show ip bgp summary
show ip bgp
show ip route 0.0.0.0
show ip route 198.51.100.21
show ip ospf neighbor
CORE01 , CORE02
show ip route 0.0.0.0
show ip route 198.51.100.11
show ip ospf neighbor
show standby brief
CPE01
traceroute 198.51.100.1
ping 198.51.100.1 rep 1000000 timeout 1
リファレンス
High Availability Configuration Guide, Cisco IOS XE Dublin 17.12.x (Catalyst 9500 Switches)
Chapter: Configuring Graceful Insertion and Removal