BGP简单配置

 

 

 

 

R1#sh ip bgp
BGP table version is 168, 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
*> 1.1.1.1/32       0.0.0.0                  0         32768 i
r>i3.3.3.3/32       3.3.3.3                  0    100      0 i
r>i4.4.4.4/32       3.3.3.3                  0    100      0 456 i
r                   4.4.4.4                  0             0 456 i
r>i5.5.5.5/32       3.3.3.3                  0    100      0 456 i
r                   4.4.4.4                                0 456 i

 


======================================================================================================================================================================

 

 

R1#sh ip bgp su
BGP router identifier 1.1.1.1, local AS number 123
BGP table version is 168, main routing table version 168
4 network entries using 404 bytes of memory
6 path entries using 288 bytes of memory
5 BGP path attribute entries using 300 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 1016 total bytes of memory
BGP activity 10/6 prefixes, 42/36 paths, scan interval 60 secs

Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd
3.3.3.3         4   123     217     359      168    0    0 00:51:04        3
4.4.4.4         4   456     203     226      168    0    0 00:04:11        2

 

======================================================================================================================================================================

 EBGP路由器


R1#sh run
Building configuration...

Current configuration : 2190 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R1
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
!
!
!
interface Loopback0
 ip address 1.1.1.1 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!        
interface Ethernet1/0
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/1
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/2
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/3
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/4
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/5
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/6
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/7
 no ip address
 shutdown
 duplex half
!
interface Serial2/0
 ip address 12.1.1.1 255.255.255.0
 serial restart-delay 0
!
interface Serial2/1
 ip address 14.1.1.1 255.255.255.0
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/4
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/5
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/6
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/7
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 router-id 1.1.1.1
 log-adjacency-changes
 network 1.1.1.0 0.0.0.255 area 0
 network 12.1.1.0 0.0.0.255 area 0
 network 14.1.1.0 0.0.0.255 area 1
!
router bgp 123
 no synchronization
 bgp log-neighbor-changes
 network 1.1.1.1 mask 255.255.255.255
 neighbor 3.3.3.3 remote-as 123
 neighbor 3.3.3.3 update-source Loopback0
 neighbor 3.3.3.3 next-hop-self
 neighbor 4.4.4.4 remote-as 456
 neighbor 4.4.4.4 ebgp-multihop 255
 neighbor 4.4.4.4 update-source Loopback0
 no auto-summary
!
ip classless
no ip http server
no ip http secure-server
!
!
!
gatekeeper
 shutdown
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
!
!
end

R1#

 

***********************************************************************************
 

 

R2#sh run
Building configuration...

Current configuration : 1856 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R2
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
!
!
!
!
interface Loopback0
 ip address 2.2.2.2 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!        
interface Ethernet1/0
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/1
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/2
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/3
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/4
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/5
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/6
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/7
 no ip address
 shutdown
 duplex half
!
interface Serial2/0
 ip address 12.1.1.2 255.255.255.0
 serial restart-delay 0
!
interface Serial2/1
 ip address 23.1.1.2 255.255.255.0
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/4
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/5
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/6
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/7
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 router-id 2.2.2.2
 log-adjacency-changes
 network 2.2.2.0 0.0.0.255 area 0
 network 12.1.1.0 0.0.0.255 area 0
 network 23.1.1.0 0.0.0.255 area 0
!
ip classless
no ip http server
no ip http secure-server
!
!
!
!
gatekeeper
 shutdown
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
!
!
end

R2# 

 

***********************************************************************************
 

R3#sh ip bgp
BGP table version is 190, local router ID is 3.3.3.3
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>i1.1.1.1/32       1.1.1.1                  0    100      0 i
*> 3.3.3.3/32       0.0.0.0                  0         32768 i
*> 4.4.4.4/32       5.5.5.5                                0 456 i
*> 5.5.5.5/32       5.5.5.5                  0             0 456 i

 


======================================================================================================================================================================

 

 

R3#sh ip bgp su
BGP router identifier 3.3.3.3, local AS number 123
BGP table version is 190, main routing table version 190
4 network entries using 404 bytes of memory
4 path entries using 192 bytes of memory
4 BGP path attribute entries using 240 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 860 total bytes of memory
BGP activity 99/95 prefixes, 129/125 paths, scan interval 60 secs

Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd
1.1.1.1         4   123     297     169      190    0    0 00:53:06        1
5.5.5.5         4   456      62      80      190    0    0 00:19:41        2

 

 

======================================================================================================================================================================

 

 

R3#sh run
Building configuration...

Current configuration : 2190 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R3
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
!
!
!
!
!
interface Loopback0
 ip address 3.3.3.3 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!        
interface Ethernet1/0
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/1
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/2
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/3
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/4
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/5
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/6
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/7
 no ip address
 shutdown
 duplex half
!
interface Serial2/0
 ip address 23.1.1.3 255.255.255.0
 serial restart-delay 0
!
interface Serial2/1
 ip address 35.1.1.3 255.255.255.0
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/4
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/5
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/6
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/7
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 router-id 3.3.3.3
 log-adjacency-changes
 network 3.3.3.0 0.0.0.255 area 0
 network 23.1.1.0 0.0.0.255 area 0
 network 35.1.1.0 0.0.0.255 area 1
!
router bgp 123
 no synchronization
 bgp log-neighbor-changes
 network 3.3.3.3 mask 255.255.255.255
 neighbor 1.1.1.1 remote-as 123
 neighbor 1.1.1.1 update-source Loopback0
 neighbor 1.1.1.1 next-hop-self
 neighbor 5.5.5.5 remote-as 456
 neighbor 5.5.5.5 ebgp-multihop 255
 neighbor 5.5.5.5 update-source Loopback0
 no auto-summary
!
ip classless
no ip http server
no ip http secure-server
!
!
!
gatekeeper
 shutdown
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
!
!
end

R3# 

 

 

***********************************************************************************
 

 

R4#sh ip bgp
BGP table version is 312, local router ID is 4.4.4.4
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
*> 1.1.1.1/32       1.1.1.1                  0             0 123 i
*> 3.3.3.3/32       1.1.1.1                                0 123 i
*> 4.4.4.4/32       0.0.0.0                  0         32768 i
r>i5.5.5.5/32       5.5.5.5                  0    100      0 i

 

======================================================================================================================================================================

 

 

R4#sh ip bgp su
BGP router identifier 4.4.4.4, local AS number 456
BGP table version is 312, main routing table version 312
4 network entries using 404 bytes of memory
4 path entries using 192 bytes of memory
4 BGP path attribute entries using 300 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 920 total bytes of memory
BGP activity 10/6 prefixes, 38/34 paths, scan interval 60 secs

Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd
1.1.1.1         4   123     203     223      312    0    0 00:07:30        2
5.5.5.5         4   456     157     288      312    0    0 01:53:34        1

 

 

======================================================================================================================================================================

 

 


R4#sh run
Building configuration...

Current configuration : 2190 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R4
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
!
!
!
!
!
!
interface Loopback0
 ip address 4.4.4.4 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!        
interface Ethernet1/0
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/1
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/2
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/3
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/4
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/5
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/6
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/7
 no ip address
 shutdown
 duplex half
!
interface Serial2/0
 ip address 14.1.1.4 255.255.255.0
 serial restart-delay 0
!
interface Serial2/1
 ip address 46.1.1.4 255.255.255.0
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/4
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/5
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/6
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/7
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 router-id 4.4.4.4
 log-adjacency-changes
 network 4.4.4.0 0.0.0.255 area 1
 network 14.1.1.0 0.0.0.255 area 1
 network 46.1.1.0 0.0.0.255 area 1
!
router bgp 456
 no synchronization
 bgp log-neighbor-changes
 network 4.4.4.4 mask 255.255.255.255
 neighbor 1.1.1.1 remote-as 123
 neighbor 1.1.1.1 ebgp-multihop 255
 neighbor 1.1.1.1 update-source Loopback0
 neighbor 5.5.5.5 remote-as 456
 neighbor 5.5.5.5 update-source Loopback0
 neighbor 5.5.5.5 next-hop-self
 no auto-summary
!
ip classless
no ip http server
no ip http secure-server
!
!
!
gatekeeper
 shutdown
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
!
!
end

R4#

 


***********************************************************************************
 

 

R5#sh ip bgp
R5#sh ip bgp
BGP table version is 308, local router ID is 5.5.5.5
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
*> 1.1.1.1/32       3.3.3.3                                0 123 i
*> 3.3.3.3/32       3.3.3.3                  0             0 123 i
r>i4.4.4.4/32       4.4.4.4                  0    100      0 i
*> 5.5.5.5/32       0.0.0.0                  0         32768 i
R5#
R5#
R5#

 

======================================================================================================================================================================

 


R5#sh ip bgp su
BGP router identifier 5.5.5.5, local AS number 456
BGP table version is 308, main routing table version 308
4 network entries using 404 bytes of memory
4 path entries using 192 bytes of memory
4 BGP path attribute entries using 300 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 920 total bytes of memory
BGP activity 90/86 prefixes, 118/114 paths, scan interval 60 secs

Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd
3.3.3.3         4   123      69      77      308    0    0 00:22:09        2
4.4.4.4         4   456     290     160      308    0    0 01:54:46        1

 

 

======================================================================================================================================================================

 

 

R5#  sh run
Building configuration...

Current configuration : 2190 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R5
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
!
!
!
!
!
interface Loopback0
 ip address 5.5.5.5 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!        
interface Ethernet1/0
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/1
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/2
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/3
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/4
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/5
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/6
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/7
 no ip address
 shutdown
 duplex half
!
interface Serial2/0
 ip address 35.1.1.5 255.255.255.0
 serial restart-delay 0
!
interface Serial2/1
 ip address 56.1.1.5 255.255.255.0
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/4
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/5
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/6
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/7
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 router-id 5.5.5.5
 log-adjacency-changes
 network 5.5.5.0 0.0.0.255 area 1
 network 35.1.1.0 0.0.0.255 area 1
 network 56.1.1.0 0.0.0.255 area 1
!
router bgp 456
 no synchronization
 bgp log-neighbor-changes
 network 5.5.5.5 mask 255.255.255.255
 neighbor 3.3.3.3 remote-as 123
 neighbor 3.3.3.3 ebgp-multihop 255
 neighbor 3.3.3.3 update-source Loopback0
 neighbor 4.4.4.4 remote-as 456
 neighbor 4.4.4.4 update-source Loopback0
 neighbor 4.4.4.4 next-hop-self
 no auto-summary
!
ip classless
no ip http server
no ip http secure-server
!
!
!
gatekeeper
 shutdown
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
!
!
end

R5#

 


***********************************************************************************
 

 

R6#sh run
Building configuration...

Current configuration : 1856 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R6
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
!
ip cef
!
!
!
!
interface Loopback0
 ip address 6.6.6.6 255.255.255.255
!
interface FastEthernet0/0
 no ip address
 shutdown
 duplex half
!        
interface Ethernet1/0
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/1
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/2
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/3
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/4
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/5
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/6
 no ip address
 shutdown
 duplex half
!
interface Ethernet1/7
 no ip address
 shutdown
 duplex half
!
interface Serial2/0
 ip address 46.1.1.6 255.255.255.0
 serial restart-delay 0
!
interface Serial2/1
 ip address 56.1.1.6 255.255.255.0
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/4
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/5
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/6
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/7
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 router-id 6.6.6.6
 log-adjacency-changes
 network 6.6.6.0 0.0.0.255 area 1
 network 46.1.1.0 0.0.0.255 area 1
 network 56.1.1.0 0.0.0.255 area 1
!
ip classless
no ip http server
no ip http secure-server
!
!
!
gatekeeper
 shutdown
!
!
line con 0
 exec-timeout 0 0
 logging synchronous
 stopbits 1
line aux 0
 stopbits 1
line vty 0 4
!
!
end

R6#   

 

 


***********************************************************************************
 

 

你可能感兴趣的:(职场,配置,休闲,BGP)