NLRI BGP

BGP

8

BGP- Network Layer Reachability Information (NLRI), BGP.

  NLRI    BGP

BGP:

  1. BGP
  2. BGP
  3. BGP

: BGP 7


NLRI

NLRI, , BGP, Cisco . BGP. , Cisco , show running-configuration BGP, , BGP, no synchronization. , BGP BGP, IGP ( ). " " (black hole), BGP BGP, IGP. - , BGP, iBGP iBGP. , , , BGP IGP, .

, Cisco network IGPs CLI. , , . network. IGP ( , ), BGP network . BGP , , (- ) , BGP.

, BGP, IGPs . . , , , . , Null0.

, network BGP, , , IP- (, 10.0.0.0/8), mask . 1 BGP. , ATL.

1: Network BGP

TPA1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
TPA1(config)#interface loopback 192
TPA1(config-if)#ip address 192.168.1.1 255.255.255.0
TPA1(config-if)#exit
TPA1(config)#interface loopback 172
TPA1(config-if)#ip address 172.16.10.1 255.255.255.0
TPA1(config-if)#exit
TPA1(config)router bgp 100
TPA1(config-router)#network 192.168.1.0
TPA1(config-router)#network 172.16.10.0 mask 255.255.255.0
TPA1(config-router)#end
TPA1#
ATL#
ATL#show ip bgp
show ip bgp

network , , . - BGP IGP . 2 , EIGRP, BGP. , (?) .

2: BGP

TPA1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
TPA1(config)router bgp 100
TPA1(config-router)#redistribute eigrp 100
TPA1(config-router)#end
TPA1#
ATL#show ip bgp
 show ip bgp

() NLRI BGP, BGP ( show ip bgp), (r) (*). (r) RIB, , BGP BGP, - - .

RIB (AD). , IBGP AD 200. , IGP ( , RIP AD 120), IBGP. BGP AD, . , , , EBGP-learned, 20 ( ).

, IGP BGP, AD , AD IBGP. , RIP BGP AD IBGP 119, IGP.

RIB show ip bgp, show ip bgp rib-failure, . BGP.


BGP

, BGP, BGP. , . , , :

  • Distribute lists
  • Extended ACLs
  • Prefix lists
  • AS Path filters
  • Route maps

3 . route map, ( ) .

3: route map BGP

ATL# configure terminal
Enter configuration commands, one per line. End with CNTL/Z. 
ATL(config)#ip access-list standard MYPREFIX
ATL(config-std-nacl)#permit 192.168.1.0 0.0.0.255
ATL(config-std-nacl)#exit 
ATL(config)#route-map MYMAP deny 10
ATL(config-route-map)#match ip address MYPREFIX
ATL(config-route-map)#exit 
ATL(config)#route-map MYMAP permit 20
 ATL(config-route-map)#exit 
ATL(config)#router bqp 200
ATL(config-router)#neighbor 10.10.10.1 route-map MYMAP in
ATL(config-router)#end 
ATL#
ATL# clear ip bqp * soft
ATL# show ip bqp
 show ip bqp

, clear ip bgp * soft. , BGP , , BGP , .

, BGP , , . , , :

  • Weight
  • MED
  • Local Preference
  • AS Path

, AS Path . AS Path AS Path Prepending. , AS , ( ) AS Path. , .

Local Preference . Local Preference, , BGP. , Local Preference, . , , Local Preference - , BGP, , IBGP. LOCAL Local Preference.

AS 200 (ATL ATL2) TPA1 TPA2 AS 100. 4, , (192.168.1.0) 10.10.10.1 . , , 10.21.21.1.

4: Local Preference

ATL# show ip bqp
 show ip bqp

. , , (192.168.1.0), , , 100 TPA2 10.21.21.1. , , 10.21.21.1 .

5 .

ATL# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
 ATL(config)#ip access-list standard OURPREFIX
ATL(config-std-nacl)#permit 192.168.1.0 0.0.0.255
ATL(config-std-nacl)#exit
ATL(config)#route-map SETLOCALPREF permit 10 
ATL(config-route-map)#match ip address OURPREFIX
 ATL(config-route-map)#set local-preference 110 
ATL(config-route-map)#exit
ATL(config)#route-map SETLOCALPREF permit 20
ATL(config-route-map)#exit 
ATL(config)#router bqp 200
ATL(config-router)#neighbor 10.21.21.1 route-map SETLOCALPREF in
ATL(config-router)#end ATL#
ATL# clear ip bqp * soft
ATL# show ip bqp
 show ip bqp

, 10.21.21.1, . Local Preference - 110. , BGP.


50% Merion Academy