pada posting ini kita akan melihat bagaimana kita manipulate path bgp...
pastikan dulu intial config ping ke masing-masing router bisa berjalan...dan tambahkan protocol IGP di iBGP supaya BGP bisa up...
ada soal seperti ini,
***konfigurasi bagaimana AS#12 ke AS#6 menggunakan R1 sebagai exit point...anda hanya bisa melakukan confignya di R4 menggunakan outbound direction MED....***
berikut confignya...
R1
interface Loopback0
ip address 10.1.1.1 255.255.255.255!
interface Loopback100
ip address 100.1.1.1 255.255.255.255
interface FastEthernet0/0.12
encapsulation dot1Q 12
ip address 10.1.12.1 255.255.255.0
ip router isis
no snmp trap link-status
isis circuit-type level-1
!
interface FastEthernet0/0.13
encapsulation dot1Q 13
ip address 10.1.13.1 255.255.255.0
no snmp trap link-status
router isis
net 49.0001.0000.0000.0001.00
is-type level-1
passive-interface Loopback0
!
router bgp 12
bgp router-id 10.1.1.1
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 10.1.1.2 remote-as 12
neighbor 10.1.1.2 update-source Loopback0
neighbor 10.1.13.3 remote-as 34
!
address-family ipv4
neighbor 10.1.1.2 activate
neighbor 10.1.1.2 send-community both
neighbor 10.1.1.2 route-reflector-client
neighbor 10.1.1.2 next-hop-self
neighbor 10.1.13.3 activate
neighbor 10.1.13.3 send-community both
no auto-summary
no synchronization
network 10.1.1.1 mask 255.255.255.255 route-map SET_COM
network 100.1.1.1 mask 255.255.255.255
exit-address-family
ip bgp-community new-format
ip prefix-list SET_NET seq 5 permit 100.1.1.1/32
logging alarm informational
route-map SET_COM permit 10
set community 1:1
!
R2
interface Loopback0
ip address 10.1.1.2 255.255.255.255interface FastEthernet0/0.12
encapsulation dot1Q 12
ip address 10.1.12.2 255.255.255.0
ip router isis
no snmp trap link-status
isis circuit-type level-1
!
interface FastEthernet0/0.24
encapsulation dot1Q 24
ip address 10.1.24.2 255.255.255.0
no snmp trap link-status
router isis
net 49.0001.0000.0000.0002.00
is-type level-1
passive-interface Loopback0
!
router bgp 12
bgp router-id 10.1.1.2
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 10.1.1.1 remote-as 12
neighbor 10.1.1.1 update-source Loopback0
neighbor 10.1.24.4 remote-as 34
!
address-family ipv4
neighbor 10.1.1.1 activate
neighbor 10.1.1.1 send-community both
neighbor 10.1.1.1 next-hop-self
neighbor 10.1.24.4 activate
neighbor 10.1.24.4 send-community both
no auto-summary
no synchronization
network 10.1.1.2 mask 255.255.255.255 route-map ORIGIN
exit-address-family
ip bgp-community new-format
route-map ORIGIN permit 10
set origin incomplete
set community 2:2
!
route-map ORIGIN permit 20
!
route-map SET_COM permit 10
set community 2:2
R3
interface Loopback0
ip address 10.1.1.3 255.255.255.255interface FastEthernet0/0.13
encapsulation dot1Q 13
ip address 10.1.13.3 255.255.255.0
no snmp trap link-status
!
interface FastEthernet0/0.34
encapsulation dot1Q 34
ip address 10.1.34.3 255.255.255.0
ip ospf network point-to-point
ip ospf mtu-ignore
no snmp trap link-status
!
interface FastEthernet0/0.35
encapsulation dot1Q 35
ip address 10.1.35.3 255.255.255.0
no snmp trap link-status
router ospf 1
router-id 10.1.1.3
log-adjacency-changes
passive-interface Loopback0
network 10.1.1.3 0.0.0.0 area 0
network 10.1.34.0 0.0.0.255 area 0
!
router bgp 34
bgp router-id 10.1.1.3
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 10.1.1.4 remote-as 34
neighbor 10.1.1.4 update-source Loopback0
neighbor 10.1.13.1 remote-as 12
neighbor 10.1.35.5 remote-as 6
neighbor 10.1.35.5 local-as 7735
!
address-family ipv4
neighbor 10.1.1.4 activate
neighbor 10.1.1.4 send-community both
neighbor 10.1.1.4 route-reflector-client
neighbor 10.1.1.4 next-hop-self
neighbor 10.1.13.1 activate
neighbor 10.1.13.1 send-community both
neighbor 10.1.13.1 route-map IN_TO_R1 in
neighbor 10.1.13.1 route-map OUT_TO_R1 out
neighbor 10.1.35.5 activate
no auto-summary
no synchronization
network 10.1.1.3 mask 255.255.255.255 route-map SET_COM
exit-address-family
ip bgp-community new-format
ip as-path access-list 1 permit _5$
ip prefix-list R1 seq 5 permit 10.1.1.1/32
logging alarm informational
!
route-map OUT_TO_R1 permit 10
match as-path 1
set metric 66666
!
route-map OUT_TO_R1 permit 20
!
route-map SET_COM permit 10
set community 3:3
!
route-map IN_TO_R1 permit 10
match ip address prefix-list R1
set local-preference 75
!
route-map IN_TO_R1 permit 20
R4
interface Loopback0
ip address 10.1.1.4 255.255.255.255interface FastEthernet0/0.24
encapsulation dot1Q 24
ip address 10.1.24.4 255.255.255.0
no snmp trap link-status
!
interface FastEthernet0/0.34
encapsulation dot1Q 34
ip address 10.1.34.4 255.255.255.0
ip ospf network point-to-point
ip ospf mtu-ignore
no snmp trap link-status
!
interface FastEthernet0/0.46
encapsulation dot1Q 46
ip address 10.1.46.4 255.255.255.0
no snmp trap link-status
router ospf 1
router-id 10.1.1.4
log-adjacency-changes
passive-interface Loopback0
network 10.1.1.4 0.0.0.0 area 0
network 10.1.34.0 0.0.0.255 area 0
!
router bgp 34
bgp router-id 10.1.1.4
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 10.1.1.3 remote-as 34
neighbor 10.1.1.3 update-source Loopback0
neighbor 10.1.1.6 remote-as 6
neighbor 10.1.1.6 ebgp-multihop 5
neighbor 10.1.1.6 update-source FastEthernet0/0.46
neighbor 10.1.24.2 remote-as 12
!
address-family ipv4
neighbor 10.1.1.3 activate
neighbor 10.1.1.3 send-community both
neighbor 10.1.1.3 next-hop-self
neighbor 10.1.1.6 activate
neighbor 10.1.1.6 send-community both
neighbor 10.1.24.2 activate
neighbor 10.1.24.2 send-community both
neighbor 10.1.24.2 route-map COM out
no auto-summary
no synchronization
network 10.1.1.4 mask 255.255.255.255 route-map SET_COM
exit-address-family
ip route 10.1.1.6 255.255.255.255 10.1.46.6
ip bgp-community new-format
ip community-list 1 permit 6:6
ip prefix-list R2 seq 5 permit 10.1.1.2/32
logging alarm informational
!
route-map COM permit 10 match community 1 set as-path prepend 34 34 34!
route-map SET_COM permit 10
set origin incomplete
set community 4:4
!
route-map IN_TO_R2 permit 10
match ip address prefix-list R2
set local-preference 55
!
route-map IN_TO_R2 permit 20
R5
!
interface Loopback0
ip address 10.1.1.5 255.255.255.255interface FastEthernet0/0.35
encapsulation dot1Q 35
ip address 10.1.35.5 255.255.255.0
no snmp trap link-status
router bgp 5
bgp router-id 10.1.1.5
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 10.1.35.3 remote-as 7735
neighbor 10.1.35.3 local-as 6 no-prepend
!
address-family ipv4
neighbor 10.1.35.3 activate
neighbor 10.1.35.3 send-community
neighbor 10.1.35.3 allowas-in
no auto-summary
no synchronization
network 10.1.1.5 mask 255.255.255.255 route-map SET_COM
exit-address-family
ip bgp-community new-format
route-map SET_COM permit 10
set community 5:5
R6
interface Loopback0
ip address 10.1.1.6 255.255.255.255
interface FastEthernet0/0.46
encapsulation dot1Q 46
ip address 10.1.46.6 255.255.255.0
no snmp trap link-status
router bgp 6
bgp router-id 10.1.1.6
no bgp default ipv4-unicast
bgp log-neighbor-changes
neighbor 10.1.46.4 remote-as 34
neighbor 10.1.46.4 update-source Loopback0
!
address-family ipv4
neighbor 10.1.46.4 activate
neighbor 10.1.46.4 send-community both
neighbor 10.1.46.4 allowas-in
no auto-summary
no synchronization
network 10.1.1.6 mask 255.255.255.255 route-map SET_COM
exit-address-family
ip bgp-community new-format
route-map SET_COM permit 10
set community 6:6
kita bisa verifikasi disini....
R2#sh ip bgp
BGP table version is 10, local router ID is 10.1.1.2
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>i10.1.1.1/32 10.1.1.1 0 100 0 i
*> 10.1.1.2/32 0.0.0.0 0 32768 ?
*>i10.1.1.3/32 10.1.1.1 0 100 0 34 i
*>i10.1.1.4/32 10.1.1.1 0 100 0 34 ?
*>i10.1.1.5/32 10.1.1.1 66666 100 0 34 7735 6 5 i
*>i10.1.1.6/32 10.1.1.1 0 100 0 34 6 i* 10.1.24.4 0 34 34 34 34 6 i*>i100.1.1.1/32 10.1.1.1 0 100 0 i
R2#