发新话题
打印

[网络转载] 实验EBGP、IBGP链路冗余

实验EBGP、IBGP链路冗余

TOPO如下:


r3#sh ru
interface Loopback0

ip address 9.9.9.9 255.255.255.0

!
interface Serial0

ip address 152.1.1.3 255.255.255.0


clockrate 64000

!
router bgp 65100

no synchronization


bgp log-neighbor-changes


network 9.9.9.0 mask 255.255.255.0


neighbor 152.1.1.1 remote-as 65100


no auto-summary

!
End



r1#sh ru
interface Loopback0

ip address 5.5.5.5 255.255.255.0

!
interface Ethernet0

ip address 172.16.2.1 255.255.255.0

!
interface Serial0

ip address 152.1.1.1 255.255.255.0

!
interface Serial1

ip address 172.16.1.1 255.255.255.0

!
router bgp 65100

no synchronization


bgp log-neighbor-changes


neighbor 2.2.2.2 remote-as 65101


neighbor 2.2.2.2 ebgp-multihop 2


neighbor 2.2.2.2 update-source Loopback0


neighbor 152.1.1.3 remote-as 65100


neighbor 152.1.1.3 next-hop-self


no auto-summary

!
ip route 2.2.2.2 255.255.255.255 Serial1
ip route 2.2.2.2 255.255.255.255 Ethernet0
!
End


r2#sh ru
interface Loopback0

ip address 2.2.2.2 255.255.255.0


ip ospf network point-to-point

!

interface Ethernet0

ip address 172.16.2.2 255.255.255.0

!
interface Serial0

ip address 10.1.1.1 255.255.255.0


clockrate 64000

!
interface Serial1

ip address 172.16.1.2 255.255.255.0


clockrate 64000

!
router ospf 10

router-id 2.2.2.2


network 2.2.2.2 0.0.0.0 area 0


network 10.0.0.0 0.255.255.255 area 0

!
router bgp 65101

no synchronization


neighbor 4.4.4.4 remote-as 65101


neighbor 4.4.4.4 next-hop-self


neighbor 5.5.5.5 remote-as 65100


neighbor 5.5.5.5 ebgp-multihop 2


neighbor 5.5.5.5 update-source Loopback0


no auto-summary

!
ip route 5.5.5.5 255.255.255.255 Serial1
ip route 5.5.5.5 255.255.255.255 Ethernet0
!
End

r4#sh ru
interface Loopback0

ip address 4.4.4.4 255.255.255.0


ip ospf network point-to-point

!
interface Ethernet0

ip address 10.2.2.2 255.255.255.0

!
interface Serial0

ip address 10.1.1.2 255.255.255.0

!
interface Serial1

ip address 192.168.1.2 255.255.255.0

!
router ospf 10

router-id 4.4.4.4


log-adjacency-changes


network 4.4.4.4 0.0.0.0 area 0


network 10.0.0.0 0.255.255.255 area 0

!
router bgp 65101

no synchronization


bgp log-neighbor-changes


neighbor 2.2.2.2 remote-as 65101


neighbor 2.2.2.2 update-source Loopback0


neighbor 2.2.2.2 next-hop-self


neighbor 192.168.1.1 remote-as 65102


no auto-summary

!
End

r5# sh ru
interface Loopback0

ip address 8.8.8.8 255.255.255.0

!
interface Serial1

ip address 192.168.1.1 255.255.255.0


clockrate 64000

!
router bgp 65102

no synchronization


bgp log-neighbor-changes


network 8.8.8.0 mask 255.255.255.0


neighbor 192.168.1.2 remote-as 65101


no auto-summary

!
End






R3
r3#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area


N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2


E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP


i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area


* - candidate default, U - per-user static route, o - ODR


P - periodic downloaded static route


Gateway of last resort is not set


152.1.0.0/24 is subnetted, 1 subnets

C
152.1.1.0 is directly connected, Serial0


8.0.0.0/24 is subnetted, 1 subnets

B
8.8.8.0 [200/0] via 152.1.1.1, 00:02:17


9.0.0.0/24 is subnetted, 1 subnets

C
9.9.9.0 is directly connected, Loopback0



r3#sh ip bgp
BGP table version is 5, local router ID is 9.9.9.9
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete


Network
Next Hop
Metric LocPrf Weight Path

*>i8.8.8.0/24
152.1.1.1
100
0 65101 65102 i

*> 9.9.9.0/24
0.0.0.0
0
32768 i



R1
r1#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area


N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2


E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP


i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area


* - candidate default, U - per-user static route, o - ODR


P - periodic downloaded static route


Gateway of last resort is not set


152.1.0.0/24 is subnetted, 1 subnets

C
152.1.1.0 is directly connected, Serial0


2.0.0.0/32 is subnetted, 1 subnets

S
2.2.2.2 is directly connected, Ethernet0


is directly connected, Serial1


5.0.0.0/24 is subnetted, 1 subnets

C
5.5.5.0 is directly connected, Loopback0


172.16.0.0/24 is subnetted, 2 subnets

C
172.16.1.0 is directly connected, Serial1

C
172.16.2.0 is directly connected, Ethernet0


8.0.0.0/24 is subnetted, 1 subnets

B
8.8.8.0 [20/0] via 2.2.2.2, 00:04:48


9.0.0.0/24 is subnetted, 1 subnets

B
9.9.9.0 [200/0] via 152.1.1.3, 00:07:22


r1#sh ip bgp

BGP table version is 9, local router ID is 5.5.5.5
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete


Network
Next Hop
Metric LocPrf Weight Path

*> 8.8.8.0/24
2.2.2.2
0 65101 65102 i

*>i9.9.9.0/24
152.1.1.3
0
100
0 i



R2
r2#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area


N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2


E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP


i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area


* - candidate default, U - per-user static route, o - ODR


P - periodic downloaded static route


Gateway of last resort is not set


2.0.0.0/24 is subnetted, 1 subnets

C
2.2.2.0 is directly connected, Loopback0


4.0.0.0/24 is subnetted, 1 subnets

O
4.4.4.0 [110/65] via 10.1.1.2, 00:12:06, Serial0


5.0.0.0/32 is subnetted, 1 subnets

S
5.5.5.5 is directly connected, Ethernet0


is directly connected, Serial1


172.16.0.0/24 is subnetted, 2 subnets

C
172.16.1.0 is directly connected, Serial1

C
172.16.2.0 is directly connected, Ethernet0


8.0.0.0/24 is subnetted, 1 subnets

B
8.8.8.0 [200/0] via 4.4.4.4, 00:10:50


9.0.0.0/24 is subnetted, 1 subnets

B
9.9.9.0 [20/0] via 5.5.5.5, 00:02:47



10.0.0.0/24 is subnetted, 2 subnets

O
10.2.2.0 [110/74] via 10.1.1.2, 00:12:08, Serial0

C
10.1.1.0 is directly connected, Serial0




r2# sh ip bgp
BGP table version is 7, local router ID is 2.2.2.2
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete


Network
Next Hop
Metric LocPrf Weight Path

*>i8.8.8.0/24
4.4.4.4
0
100
0 65102 i

*> 9.9.9.0/24
5.5.5.5
0 65100 i



R4
r4#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area


N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2


E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP


i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area


* - candidate default, U - per-user static route, o - ODR


P - periodic downloaded static route


Gateway of last resort is not set


2.0.0.0/24 is subnetted, 1 subnets

O
2.2.2.0 [110/65] via 10.1.1.1, 00:24:11, Serial0


4.0.0.0/24 is subnetted, 1 subnets

C
4.4.4.0 is directly connected, Loopback0


8.0.0.0/24 is subnetted, 1 subnets

B
8.8.8.0 [20/0] via 192.168.1.1, 00:22:59


9.0.0.0/24 is subnetted, 1 subnets

B
9.9.9.0 [200/0] via 2.2.2.2, 00:07:05


10.0.0.0/24 is subnetted, 2 subnets

C
10.1.1.0 is directly connected, Serial0

C
10.2.2.0 is directly connected, Ethernet0

C
192.168.1.0/24 is directly connected, Serial1


r4# sh ip bgp
BGP table version is 15, local router ID is 4.4.4.4
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete


Network
Next Hop
Metric LocPrf Weight Path

*> 8.8.8.0/24
192.168.1.1
0
0 65102 i

*>i9.9.9.0/24
2.2.2.2
100
0 65100 i


R5
r5#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area


N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2


E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP


i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area


* - candidate default, U - per-user static route, o - ODR


P - periodic downloaded static route


Gateway of last resort is not set


8.0.0.0/24 is subnetted, 1 subnets

C
8.8.8.0 is directly connected, Loopback0


9.0.0.0/24 is subnetted, 1 subnets

B
9.9.9.0 [20/0] via 192.168.1.2, 00:07:20

C
192.168.1.0/24 is directly connected, Serial1


r5#sh ip bgp
BGP table version is 15, local router ID is 8.8.8.8
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete


Network
Next Hop
Metric LocPrf Weight Path

*> 8.8.8.0/24
0.0.0.0
0
32768 i

*> 9.9.9.0/24
192.168.1.2
0 65101 65100 i





r3#ping
Protocol [ip]:
Target IP address: 8.8.8.8
Repeat count [5]:
Datagram size [100]:
Timeout in seconds [2]:
Extended commands [n]: y
Source address or interface: 9.9.9.9
Type of service [0]:
Set DF bit in IP header? [no]:
Validate reply data? [no]:
Data pattern [0xABCD]:
Loose, Strict, Record, Timestamp, Verbose[none]:
Sweep range of sizes [n]:
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 8.8.8.8, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 88/95/124 ms

Trace得到结论EbgpIbgp负载均衡,数据报各走一边。

TOP

看懂了吗,问谁呢,本来就这样,就英文,代码,非转业弄不情

TOP

发新话题