IOS-XRvへのインターネットフルルートの注入 |
Dynalconf HOME |
IOS-XRvにGoBGPを使用してインターネットフルルートを注入します。
mkdir /opt/gobgp cd /opt/gobgp wget https://github.com/osrg/gobgp/releases/download/v2.22.0/gobgp_2.22.0_linux_amd64.tar.gz tar zxvf gobgp_2.22.0_linux_amd64.tar.gz
ln -s /opt/gobgp/gobgpd /usr/local/bin/gobgpd ln -s /opt/gobgp/gobgp /usr/local/bin/gobgp
[global.config] as = 65000 router-id = "192.168.208.13" [[neighbors]] [neighbors.config] neighbor-address = "192.168.208.50" peer-as = 65000 [[neighbors]] [neighbors.config] neighbor-address = "192.168.208.51" peer-as = 65001
gobgpd -f gobgp.conf
gobgp mrt inject global --no-ipv6 rib.20201220.0000
gobgp mrt inject global --no-ipv6 --nexthop 192.168.208.1 rib.20201220.0000
# gobgp global rib 100.0.0.0 Network Next Hop AS_PATH Age Attrs *> 100.0.0.0/16 202.249.2.169 7500 2497 701 00:01:58 [{Origin: i}] * 100.0.0.0/16 202.249.2.169 2497 701 00:01:58 [{Origin: i}]
qemu-system-x86_64 \ -enable-kvm \ -daemonize \ -display none \ -vnc :0 \ -smp cores=2,threads=1,sockets=1 \ -m 4096 \ -drive file=iosxrv-k9-demo-6.1.3_3.qcow2,if=ide,index=0,media=disk,format=qcow2 \ -serial telnet:192.168.208.5:3000,server,nowait \ -device e1000,netdev=net0,mac=84:00:00:12:34:56 \ -netdev bridge,id=net0,br=br00010 \ -device e1000,netdev=net1,mac=84:00:00:12:34:57 \ -netdev bridge,id=net1,br=br1 \ -device e1000,netdev=net2,mac=84:00:00:12:34:58 \ -netdev bridge,id=net2,br=br2
logging console debugging telnet vrf default ipv4 server max-servers 5 line console session-timeout 360 ! line default session-timeout 360 ! interface MgmtEth0/0/CPU0/0 shutdown ! interface GigabitEthernet0/0/0/0.808 ipv4 address 192.168.208.50 255.255.255.0 encapsulation dot1q 808 ! interface GigabitEthernet0/0/0/1 shutdown ! router static address-family ipv4 unicast 0.0.0.0/0 192.168.208.254 202.249.2.0/24 192.168.208.1 ! ! router bgp 65000 bgp router-id 192.168.208.50 address-family ipv4 unicast ! neighbor 192.168.208.13 remote-as 65000 address-family ipv4 unicast ! ! ! end
router static address-family ipv4 unicast 202.249.2.0/24 192.168.208.1
RP/0/0/CPU0:ios# RP/0/0/CPU0:ios#sh bgp ipv4 unicast summary Fri Dec 25 04:04:41.068 UTC BGP router identifier 192.168.208.50, local AS number 65000 BGP generic scan interval 60 secs Non-stop routing is enabled BGP table state: Active Table ID: 0xe0000000 RD version: 1653183 BGP main routing table version 1653183 BGP NSR Initial initsync version 3 (Reached) BGP NSR/ISSU Sync-Group versions 0/0 BGP scan interval 60 secs BGP is operating in STANDALONE mode. Process RcvTblVer bRIB/RIB LabelVer ImportVer SendTblVer StandbyVer Speaker 1653183 1653183 1653183 1653183 1653183 0 Neighbor Spk AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down St/PfxRcd 192.168.208.13 0 65000 1653390 211 1653183 0 0 01:44:30 834425 <--- 834425 routes RP/0/0/CPU0:ios# RP/0/0/CPU0:ios#sh route ipv4 summary Fri Dec 25 04:04:54.837 UTC Route Source Routes Backup Deleted Memory(bytes) connected 1 0 0 160 local 1 0 0 160 static 2 0 0 320 dagr 0 0 0 0 bgp 65000 834425 0 0 133508000 Total 834429 0 0 133508640 RP/0/0/CPU0:ios# RP/0/0/CPU0:ios#sh cef summary Fri Dec 25 04:05:05.986 UTC Router ID is 0.0.0.0 IP CEF with switching (Table Version 0) for node0_0_CPU0 Load balancing: L3 Tableid 0xe0000000 (0xa0f78294), Vrfid 0x60000000, Vrid 0x20000000, Flags 0x1019 Vrfname default, Refcount 834473 834438 routes, 0 protected, 0 reresolve, 0 unresolved (0 old, 0 new), 66755040 bytes 834429 rib, 0 lsd, 0:1 aib, 2 internal, 2 interface, 4 special, 1 default routes 0 Drop Pathlist elements 21 load sharing elements, 6048 bytes, 834430 references Shared load sharing elements with 4896 bytes, 834426 references, including: 17 Pathlist elements, 17 recursive, 17 platform shared, 0 in retry 17 Loadinfo elements, 0 recursive, 17 platform shared Exclusive load sharing elements with 1152 bytes, 4 references, including: 4 Pathlist elements, 0 recursive, 0 platform shared, 0 in retry 4 Loadinfo elements, 0 recursive, 0 platform shared 0 route delete cache elements 5 local route bufs received, 8779 remote route bufs received, 0 mix bufs received 834429 local routes, 0 remote routes 7 total local route updates processed 837662 total remote route updates processed 0 pkts pre-routed to cust card 0 pkts pre-routed to rp card 0 pkts received from core card 0 CEF route update drops, 3238 revisions of existing leaves 0 CEF route update drops due to version mis-match Resolution Timer: 15s 0 prefixes modified in place 0 deleted stale prefixes 0 prefixes with label imposition, 0 prefixes with label information 0 LISP EID prefixes, 0 merged, via 0 rlocs 4 next hops 2 incomplete next hops 0 PD backwalks on LDIs with backup path RP/0/0/CPU0:ios# RP/0/0/CPU0:ios#sh memory summary Fri Dec 25 04:08:52.800 UTC Physical Memory: 4095M total (1560M available) Application Memory : 3892M (1560M available) Image: 74M (bootram: 74M) Reserved: 128M, IOMem: 0, flashfsys: 0 Total shared window: 243M RP/0/0/CPU0:ios#
RP/0/0/CPU0:Dec 25 02:38:44.551 : bgp[1052]: %ROUTING-BGP-5-MAXPFX : No. of IPv4 Unicast prefixes received from 192.168.208.13 has reached 786433, max 1048576
RP/0/0/CPU0:Dec 25 02:40:26.304 : fib_mgr[209]: %ROUTING-FIB-4-RSRC_LOW : FIB running low on Shared Memory resource memory. FIB will now begin resource constrained forwarding. Only route deletes will be handled in this state, which may result in mismatch between RIB/FIB. Traffic loss on certain prefixes can be expected. FIB will automatically resume normal operation, once the resource utilization returns to normal level.
Router# Router#sh bgp ipv4 unicast sum Router#sh bgp ipv4 unicast summary BGP router identifier 192.168.120.50, local AS number 65000 BGP table version is 834426, main routing table version 834426 834425 network entries using 120157200 bytes of memory 834425 path entries using 73429400 bytes of memory 152529/152529 BGP path/bestpath attribute entries using 24404640 bytes of memory 135469 BGP AS-PATH entries using 5706138 bytes of memory 204 BGP community entries using 8132 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 223705510 total bytes of memory BGP activity 834425/0 prefixes, 834425/0 paths, scan interval 60 secs Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd 192.168.208.13 4 65000 152594 15 834426 0 0 00:05:20 834425 <--- 834425 routes Router# Router#sh ip route summary IP routing table name is default (0x0) IP routing table maximum-paths is 32 Route Source Networks Subnets Replicates Overhead Memory (bytes) connected 0 2 0 144 368 static 1 0 0 72 184 application 0 0 0 0 0 bgp 65000 208927 625498 0 60078600 153534200 External: 0 Internal: 834425 Local: 0 internal 8643 33389072 Total 217571 625500 0 60078816 186923824 Router# Router#sh ip cef summary IPv4 CEF is enabled and running VRF Default 834456 prefixes (834456/0 fwd/non-fwd) Table id 0x0 Database epoch: 0 (834456 entries at this epoch) Router# Router#sh memory statistics Head Total(b) Used(b) Free(b) Lowest(b) Largest(b) Processor 2BDD6880 2438183184 817163012 1621020172 1620985280 809298832 I/O C000000 67108864 16420440 50688424 50645324 50592380 Router# Router#sh bgp ipv4 unicast neighbors BGP neighbor is 192.168.208.13, remote AS 65000, internal link BGP version 4, remote router ID 192.168.208.13 BGP state = Established, up for 00:11:48 Last read 00:00:12, last write 00:00:28, hold time is 90, keepalive interval is 30 seconds Neighbor sessions: 1 active, is not multisession capable (disabled) Neighbor capabilities: Route refresh: advertised and received(new) Four-octets ASN Capability: advertised and received Address family IPv4 Unicast: advertised and received Enhanced Refresh Capability: advertised Multisession Capability: Stateful switchover support enabled: NO for session 1 Message statistics: InQ depth is 0 OutQ depth is 0 Sent Rcvd Opens: 1 1 Notifications: 0 0 Updates: 1 152582 Keepalives: 28 24 Route Refresh: 0 0 Total: 30 152607 Do log neighbor state changes (via global configuration) Default minimum time between advertisement runs is 0 seconds For address family: IPv4 Unicast Session: 192.168.208.13 BGP table version 834426, neighbor version 834426/0 Output queue size : 0 Index 1, Advertise bit 0 1 update-group member Slow-peer detection is disabled Slow-peer split-update-group dynamic is disabled Sent Rcvd Prefix activity: ---- ---- Prefixes Current: 0 834425 (Consumes 73429400 bytes) Prefixes Total: 0 834425 Implicit Withdraw: 0 0 Explicit Withdraw: 0 0 Used as bestpath: n/a 834425 Used as multipath: n/a 0 Used as secondary: n/a 0 Outbound Inbound Local Policy Denied Prefixes: -------- ------- Bestpath from this peer: 834425 n/a Total: 834425 0 Number of NLRIs in the update sent: max 0, min 0 Last detected as dynamic slow peer: never Dynamic slow peer recovered: never Refresh Epoch: 1 Last Sent Refresh Start-of-rib: never Last Sent Refresh End-of-rib: never Last Received Refresh Start-of-rib: never Last Received Refresh End-of-rib: never Sent Rcvd Refresh activity: ---- ---- Refresh Start-of-RIB 0 0 Refresh End-of-RIB 0 0 Address tracking is enabled, the RIB does have a route to 192.168.208.13 Route to peer address reachability Up: 1; Down: 0 Last notification 00:12:31 Connections established 1; dropped 0 Last reset never Interface associated: (none) (peering address in same link) Transport(tcp) path-mtu-discovery is enabled Graceful-Restart is disabled SSO is disabled Connection state is ESTAB, I/O status: 1, unread input bytes: 0 Connection is ECN Disabled, Mininum incoming TTL 0, Outgoing TTL 255 Local host: 192.168.208.50, Local port: 33719 Foreign host: 192.168.208.13, Foreign port: 179 Connection tableid (VRF): 0 Maximum output segment queue size: 50 Enqueued packets for retransmit: 0, input: 0 mis-ordered: 0 (0 bytes) Event Timers (current time is 0x17040AC): Timer Starts Wakeups Next Retrans 30 1 0x0 TimeWait 0 0 0x0 AckHold 5112 20 0x0 SendWnd 0 0 0x0 KeepAlive 0 0 0x0 GiveUp 0 0 0x0 PmtuAger 95 94 0x17042CA DeadWait 0 0 0x0 Linger 0 0 0x0 ProcessQ 0 0 0x0 iss: 865896396 snduna: 865897009 sndnxt: 865897009 irs: 3896150993 rcvnxt: 3910909390 sndwnd: 29200 scale: 0 maxrcvwnd: 16384 rcvwnd: 15511 scale: 0 delrcvwnd: 873 SRTT: 976 ms, RTTO: 1166 ms, RTV: 190 ms, KRTT: 0 ms minRTT: 4 ms, maxRTT: 1000 ms, ACK hold: 200 ms uptime: 719476 ms, Sent idletime: 8796 ms, Receive idletime: 8792 ms Status Flags: active open Option Flags: nagle, path mtu capable IP Precedence value : 6 Datagrams (max data segment is 1460 bytes): Rcvd: 13264 (out of order: 2365), with data: 11478, total data bytes: 14758396 Sent: 17340 (retransmit: 1, fastretransmit: 0, partialack: 0, Second Congestion: 0), with data: 30, total data bytes: 612 Packets received in fast path: 0, fast processed: 0, slow path: 0 fast lock acquisition failures: 0, slow path: 0 TCP Semaphore 0x31EAB5C8 FREE Router#
Dynalconf HOME |