Pertama kita konfig BGP nya dulu ya.. oya diasumsikan ip address sudah di konfig standard idn ya..
R1(config)#do sh run | s r b router bgp 12 bgp log-neighbor-changes network 1.1.0.0 mask 255.255.255.0 network 1.1.1.0 mask 255.255.255.0 network 1.1.2.0 mask 255.255.255.0 network 1.1.3.0 mask 255.255.255.0 neighbor 13.13.13.3 remote-as 3 neighbor 12.12.12.2 remote-as 12
R2(config-router)#do sh run | s r b router bgp 12 bgp log-neighbor-changes network 1.1.4.0 mask 255.255.255.0 network 1.1.5.0 mask 255.255.255.0 network 1.1.6.0 mask 255.255.255.0 network 1.1.7.0 mask 255.255.255.0 neighbor 23.23.23.3 remote-as 3 neighbor 12.12.12.1 remote-as 12
R3(config-router)#do sh run | s r b router bgp 3 bgp log-neighbor-changes neighbor 13.13.13.1 remote-as 12 neighbor 23.23.23.2 remote-as 12 neighbor 34.34.34.4 remote-as 4
Kita lihat hasilnya di R3 yaaR4(config-router)#do sh run | s r b router bgp 4 bgp log-neighbor-changes neighbor 34.34.34.3 remote-as 3
Oke R3 sudah punya informasi prefix yang lengkap dalam BGP..R4(config-router)#do sh ip bgp BGP table version is 27, local router ID is 34.34.34.4 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path *> 1.1.0.0/24 34.34.34.3 0 3 12 i *> 1.1.1.0/24 34.34.34.3 0 3 12 i *> 1.1.2.0/24 34.34.34.3 0 3 12 i *> 1.1.3.0/24 34.34.34.3 0 3 12 i *> 1.1.4.0/24 34.34.34.3 0 3 12 i *> 1.1.5.0/24 34.34.34.3 0 3 12 i *> 1.1.6.0/24 34.34.34.3 0 3 12 i *> 1.1.7.0/24 34.34.34.3 0 3 12 i
Sekarang kita lakukan summarization di R3 yaa
Kita coba lihat hasilnya di R4..R3(config)#router bgp 3 R3(config-router)#aggregate-address 1.1.0.0 255.255.248.0 as-set summary-only
Oke hasilnya normal ya...R4(config-router)#do sh ip bgp BGP table version is 38, local router ID is 34.34.34.4 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path *> 1.1.0.0/21 34.34.34.3 0 0 3 12 i
Sekarang ada sedikit masalah nih.. R1 akan mengkonfigurasikan prefix 1.1.0.0/24 dengan community no-advertise
Sebenarnya ini masalah sepele.. tapi akibatnya bisa besar lho.. kita coba lihat R3 yaaR1(config)#access-list 1 permit 1.1.0.0 0.0.0.255 R1(config)#route-map set-com R1(config-route-map)#match ip address 1 R1(config-route-map)#set community no-advertise R1(config-route-map)#router bgp 12 R1(config-router)#nei 13.13.13.3 route-map set-com out R1(config-router)#nei 13.13.13.3 send-community R1(config-router)#do cle ip bgp * soft
Tuh kannn.... di R4 jadi hilang prefix hasil summary nya.. kenapa demikian?? karena R3 melakukan summary pada network 1.1.0.0/21,, dan salah satu prefix nya (1.1.0.0/24) memiliki community no-advertise.. jadi akibatnya semua prefix akan terpengaruhi dan tidak akan diadvertise kemanapun...R4(config-router)#do sh ip bgp R4(config-router)#
Untuk mengatasi masalah ini.. kita bisa melakukan summary pada beberapa prefix saja menggunakan advertisemap pada R3 seperti berikut
Perhatikan bahwa kita membuat prefix list.. pertama mendeny network 1.1.0.0/24.. artinya nanti prefix 1.1.0.0/24 tidak akan diikutkan dalam summarization..R3(config)#ip prefix-list advertise-map deny 1.1.0.0/24 R3(config)#ip prefix-list advertise-map permit 1.1.0.0/21 ge 24 le 24 R3(config)#route-map to-aggregate R3(config-route-map)#match ip address prefix-list advertise-map R3(config-route-map)#router bgp 3 R3(config-router)# aggregate-address 1.1.0.0 255.255.248.0 as-set summary-only advertise-map to-aggregate
Kita coba cek hasilnya di R4 yaa
Okeee sudah berhasil kan..R4(config-router)#do sh ip bgp BGP table version is 42, local router ID is 34.34.34.4 Status codes: s suppressed, d damped, h history, * valid, > best, i - internal, r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter, x best-external, a additional-path, c RIB-compressed, Origin codes: i - IGP, e - EGP, ? - incomplete RPKI validation codes: V valid, I invalid, N Not found Network Next Hop Metric LocPrf Weight Path *> 1.1.0.0/21 34.34.34.3 0 0 3 12 i
Oke sampai disini dulu ya.. semoga bermanfaat..
Tidak ada komentar:
Posting Komentar
Komentar