BGP路由传递原则.docx
《BGP路由传递原则.docx》由会员分享,可在线阅读,更多相关《BGP路由传递原则.docx(54页珍藏版)》请在冰豆网上搜索。
BGP路由传递原则
实验一:
BGP路由传递原则
实验目标:
掌握BGP的路由传递原则
实验TOP:
基本配置
R1
01
!
02
03
hostname R1
04
05
!
06
07
noipdomainlookup
08
09
!
10
11
interfaceLoopback0
12
13
ipaddress1.1.1.1255.255.255.0
14
15
!
16
17
interfaceLoopback10
18
19
ipaddress10.10.10.10255.255.255.0
20
21
ipospfnetworkpoint-to-point
22
23
!
24
25
interfaceSerial1/0
26
27
ipaddress12.1.1.1255.255.255.0
28
29
!
30
31
interfaceSerial1/1
32
33
ipaddress13.1.1.1255.255.255.0
34
35
!
36
37
routerospf10
38
39
router-id 1.1.1.1
40
41
network10.10.10.00.0.0.255area0
42
43
network12.1.1.00.0.0.255area0
44
45
network13.1.1.00.0.0.255area0
46
47
!
48
49
routerbgp65001
50
51
nosynchronization
52
53
bgprouter-id 1.1.1.1
54
55
network1.1.1.0mask255.255.255.0
56
57
neighbor12.1.1.2remote-as65001
58
59
neighbor13.1.1.3remote-as65001
60
61
noauto-summary
62
63
!
R2
01
!
02
03
hostname R2
04
05
!
06
07
noipdomainlookup
08
09
!
10
11
interfaceLoopback0
12
13
ipaddress2.2.2.2255.255.255.0
14
15
!
16
17
interfaceLoopback10
18
19
ipaddress20.20.20.20255.255.255.0
20
21
ipospfnetworkpoint-to-point
22
23
!
24
25
interfaceSerial1/0
26
27
ipaddress24.2.2.2255.255.255.0
28
29
!
30
31
interfaceSerial1/1
32
33
ipaddress12.1.1.2255.255.255.0
34
35
!
36
37
routerospf10
38
39
router-id 2.2.2.2
40
41
network12.1.1.00.0.0.255area0
42
43
network20.20.20.00.0.0.255area0
44
45
network24.2.2.00.0.0.255area0
46
47
!
48
49
routerbgp65001
50
51
nosynchronization
52
53
bgprouter-id 2.2.2.2
54
55
network2.2.2.0mask255.255.255.0
56
57
neighbor12.1.1.1remote-as65001
58
59
neighbor24.2.2.4remote-as65001
60
61
noauto-summary
62
63
!
R3
01
!
02
03
hostname R3
04
05
!
06
07
noipdomainlookup
08
09
!
10
11
interfaceLoopback0
12
13
ipaddress3.3.3.3255.255.255.0
14
15
!
16
17
interfaceLoopback10
18
19
ipaddress30.30.30.30255.255.255.0
20
21
ipospfnetworkpoint-to-point
22
23
!
24
25
interfaceSerial1/1
26
27
ipaddress13.1.1.3255.255.255.0
28
29
!
30
31
interfaceSerial1/0
32
33
ipaddress34.3.3.3255.255.255.0
34
35
!
36
37
routerospf10
38
39
router-id 3.3.3.3
40
41
network13.1.1.00.0.0.255area0
42
43
network30.30.30.00.0.0.255area0
44
45
network34.3.3.00.0.0.255area0
46
47
!
48
49
routerbgp65001
50
51
nosynchronization
52
53
bgprouter-id 3.3.3.3
54
55
network3.3.3.0mask255.255.255.0
56
57
neighbor13.1.1.1remote-as65001
58
59
neighbor34.3.3.4remote-as65001
60
61
noauto-summary
62
63
!
R4
01
!
02
03
hostname R4
04
05
!
06
07
noipdomainlookup
08
09
!
10
11
interfaceLoopback0
12
13
ipaddress4.4.4.4255.255.255.0
14
15
!
16
17
interfaceLoopback10
18
19
ipaddress40.40.40.40255.255.255.0
20
21
ipospfnetworkpoint-to-point
22
23
!
24
25
interfaceSerial1/0
26
27
ipaddress24.2.2.4255.255.255.0
28
29
!
30
31
interfaceSerial1/1
32
33
ipaddress34.3.3.4255.255.255.0
34
35
!
36
37
InterfaceSerial1/2
38
39
Ip address45.4.4.4255.255.255.0
40
41
!
42
43
InterfaceSerial1/3
44
45
Ip address46.4.4.4255.255.255.0
46
47
!
48
49
routerospf10
50
51
router-id 4.4.4.4
52
53
network40.40.40.00.0.0.255area0
54
55
network24.2.2.00.0.0.255area0
56
57
network34.3.3.00.0.0.255area0
58
59
!
60
61
routerbgp65001
62
63
nosynchronization
64
65
bgprouter-id 4.4.4.4
66
67
network4.4.4.0mask255.255.255.0
68
69
neighbor24.2.2.2remote-as65001
70
71
neighbor34.3.3.3remote-as65001
72
73
neighbor45.4.4.5remote-as65002
74
75
neighbor46.4.4.6remote-as65003
76
77
noauto-summary
78
79
!
R5
01
!
02
03
HostnameR5
04
05
!
06
07
noipdomainlookup
08
09
!
10
11
interfaceLoopback0
12
13
ipaddress5.5.5.5255.255.255.0
14
15
!
16
17
interfaceSerial1/0
18
19
ipaddress45.4.4.5255.255.255.0
20
21
!
22
23
routerbgp65002
24
25
nosynchronization
26
27
bgprouter-id 5.5.5.5
28
29
network5.5.5.0mask255.255.255.0
30
31
neighbor45.4.4.4remote-as65001
32
33
noauto-summary
34
35
!
R6
01
!
02
03
hostname R6
04
05
!
06
07
interfaceLoopback0
08
09
ipaddress6.6.6.6255.255.255.0
10
11
!
12
13
interfaceSerial1/0
14
15
ipaddress46.4.4.6255.255.255.0
16
17
!
18
19
routerbgp65003
20
21
nosynchronization
22
23
bgprouter-id 6.6.6.6
24
25
network6.6.6.0mask255.255.255.0
26
27
neighbor46.4.4.4remote-as65001
28
29
noauto-summary
30
31
!
批注:
路由器接口默认是关闭的,所以应将对应的接口开启
基本配置完成之后,我们开始检查BGP对等体关系是否正常建立
R1#showipbgpsummary
BGProuteridentifier1.1.1.1,localASnumber65001
BGPtableversionis4,mainroutingtableversion4
3networkentriesusing303bytesofmemory
3pathentriesusing144bytesofmemory
2BGPpathattributeentriesusing120bytesofmemory
0BGProute-mapcacheentriesusing0bytesofmemory
0BGPfilter-listcacheentriesusing0bytesofmemory
BGPusing567totalbytesofmemory
BGPactivity3/0prefixes,3/0paths,scaninterval60secs
Neighbor V ASMsgRcvdMsgSent TblVer InQOutQUp/Down State/PfxRcd
12.1.1.2 465001 10 10 4 0 000:
05:
28 1
13.1.1.3 465001 9 9 4 0 000:
04:
42 1
R1#
//R1此时已经正常与R2和R3建立iBGP对等体关系
R2#showipbgpsummary
BGProuteridentifier2.2.2.2,localASnumber65001
BGPtableversionis4,mainroutingtableversion4
5networkentriesusing505bytesofmemory
5pathentriesusing240bytesofmemory
4BGPpathattributeentriesusing240bytesofmemory
2BGPAS-PATHentriesusing48bytesofmemory
0BGProute-mapcacheentriesusing0bytesofmemory
0BGPfilter-listcacheentriesusing0bytesofmemory
BGPusing1033totalbytesofmemory
BGPactivity5/0prefixes,5/0paths,scaninterval60secs
Neighbor V ASMsgRcvdMsgSent TblVer InQOutQUp/Down State/PfxRcd
12.1.1.1 465001 11 11 4 0 000:
06:
13 1
24.2.2.4 465001 11 9 4 0 000:
04:
51 3
R2#
//R2此时已经正常与R1和R4建立iBGP对等体关系
R3#showipbgpsummary
BGProuteridentifier3.3.3.3,localASnumber65001
BGPtableversionis4,mainroutingtableversion4
5networkentriesusing505bytesofmemory
5pathentriesusing240bytesofmemory
4BGPpathattributeentriesusing240bytesofmemory
2BGPAS-PATHentriesusing48bytesofmemory
0BGProute-mapcacheentriesusing0bytesofmemory
0BGPfilter-listcacheentriesusing0bytesofmemory
BGPusing1033totalbytesofmemory
BGPactivity5/0prefixes,5/0paths,scaninterval60secs
Neighbor V ASMsgRcvdMsgSent TblVer InQOutQUp/Down State/PfxRcd
13.1.1.1 465001 10 10 4 0 000:
05:
53 1
34.3.3.4 465001 12 10 4 0 000:
05:
16 3
R3#
//R3此时已经正常与R1和R4建立iBGP对等体关系
R4#showipbgpsummary
BGProuteridentifier4.4.4.4,localASnumber65001
BGPtableversionis6,main