需求:假设AS65001 网络是 电信网 AS65002 网络是移动网,网段202.106.15.0 是电信业务段,网络202.106.48.0 是移动业务段
互相访问,并且R4能远程控制R1.
R1上配置:
R1#en
R1#conf t
R1(config-if)#inter f1/0 配置IP地址
R1(config-if)#ip address 202.106.16.1 255.255.255.0
R1(config-if)#no shut
R1(config-if)#inter f0/0
R1(config-if)#ip address 202.106.15.11 255.255.255.0
R1(config-if)#no shut
R1(config-if)#inter loop 0 配置环回口地址
R1(config-if)#ip address 1.1.1.1 255.255.255.255
R1(config-if)#no shut
R1(config)#inter f0/1
R1(config-if)#ip address 202.106.12.1 255.255.255.0
R1(config-if)#no shut
R1(config)#no cdp run
R1(config)#router isis 启动ISIS协议
R1(config-router)#net 49.0001.0001.0001.0001.00 NET地址
R1(config-router)#is-type level-1 IS类型等级是1
R1(config-router)#ex
R1(config)#inter f0/1
R1(config-if)#ip router isis
R1(config-if)#inter f1/0
R1(config-if)#ip router isis
R1(config-if)#inter loop 0
R1(config-if)#ip router isis
R1(config-if)#router bgp 65001 BGP AS65001
R1(config-router)#bgp router-id 1.1.1.1 BGP路由ID
R1(config-router)#neighbor 2.2.2.2 remote-as 65001 建立邻居关系
R1(config-router)#neighbor 2.2.2.2 update-source l 0 更新源为 环回口
R1(config-router)#neighbor 6.6.6.6 remote-as 65001
R1(config-router)#neighbor 6.6.6.6 update-source l 0
*Mar 1 00:26:27.907: %BGP-5-ADJCHANGE: neighbor 2.2.2.2 Up 与2建立邻居关系
R1(config-router)#
*Mar 1 00:33:30.271: %BGP-5-ADJCHANGE: neighbor 6.6.6.6 Up 与6建立邻居关系
R1(config-router)#ex
R1(config)#int f0/0
R1(config-if)#vrrp 1 ip 202.106.15.1 VRRP冗余备份
R1(config-if)#vrrp 1 priority 120 优先级为120
R1(config-if)#vrrp 1 preempt 配置抢占
R1(config-if)#ex
R1(config)#track 1 interface f0/1 line-protocol 监控端口
R1(config)#track 2 interface f1/0 line-protocol
R1(config-track)#inter f0/0
R1(config-if)#vrrp 1 track 1
R1(config-if)#vrrp 1 track 2
R1(config)#router bgp 65001
R1(config-router)#network 202.106.15.0 mask 255.255.255.0 发布网络
R1(config)#line vty 0 4 开启远程管理
R1(config-line)#password 110
R1(config-line)#login
R1(config-line)#exit
R1(config)#enable secret 110
R1#show vrrp br R1是主路由器
Interface Grp Pri Time Own Pre State Master addr Group addr
Fa0/0 1 120 3531 Y Master 202.106.15.11 202.106.15.1
R1#show bgp
BGP table version is 5, local router ID is 1.1.1.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
r RIB-failure, S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
r>i2.2.2.2/32 2.2.2.2 0 100 0 i
*> 202.106.15.0 0.0.0.0 0 32768 i
*>i202.106.48.0 3.3.3.3 0 100 0 65002 i
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd 邻居关系表
2.2.2.2 4 65001 42 41 5 0 0 00:19:10 2
6.6.6.6 4 65001 31 32 5 0 0 00:27:03 0