BGP Local Preference

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi friends this is here welcome to my networking channel and today let us discuss about bgp local preference attribute so local different sent to all ibgb neighbors within a single autonomous system so it is not exchanged between the ebg neighbors and always highest local is preferred and the default value is hundred so always reduce to take the outbound path which always prefers the best outbound path so now let us go to the scenario so first thing i am going to show all the bgp neighbor relationship on all this router and the next thing i'm going to advertise the prefix as a loopback address and third thing i'm going to uh configure the vgp local preference attribute so r1 as per this architecture our own has established an ebg relationship with r2 and ebg navy relationship with r3 since both are in different autonomous system number and r2 has established an ibgp relationship with r3 and ebg relationship with r1 right this both are in the same autonomous system number so now let us go to the r1 r2 and r3 let us configure the individual bgp navy relationship right so go to r1 router bgp one and it does two ebgb neighbor right so let us check the 12.2 and 13.2 so neighbor is 192.168.192.168.12.2 and the remote autonomous system number is true right similarly 13 liters to evgp enables 12.2 and another one is 13.2 12.21 13.2 so two ebg enables you are configured similarly go to r2 r2 has one ipg neighbor and one ebg whenever so let us enable the routing protocol bgp followed by the autonomous system number then configure the neighbor statement so the neighbor statement is r2 has 23.2 and total dot one 23.2 is the ibgb neighbor right so 192.16 as a ib gb neighbor that is true and similarly 12.1 to 12.1 as the ebgb neighbor right number one similarly go to r3 and configure the individual bgp navy relationship so router bgp two right and it has two enables one is an ib gb neighbor and a ebg whenever ibgb neighbor is 23.1 192.168.23.1 and the remote is value is 2. so always make sure that you are configuring the correct neighbor statement if you are configuring any correct neighbor statement the vgb neighbor relationship will not establish between the routers so 23.1 another one is 13.1 right so 13.1 as an ebgb neighbor so once this is done first thing we need to check the neighbor relationship so neighbor is coming up it is showing the notification right so neighbor is coming up so okay let us check the neighbor statement show ipbgp all summary okay still one more neighbor to come up so see still that it is showing active right first it will be idle then go to active then it will go to the established state so the nav now the neighbor is established and it is receiving the prefixes you will see you are seeing the uptime of the neighbor and the prefix would show some value if you decided to show like this idle or active that means the neighbor is about to establish so now the neighbor is in established state similarly go to or to uncheck the neighbor relationship right show ipbgp all summary and similarly go to r3 and check the neighbor relationship show ipbgb all summary so here it's a urc you are able to see right neighbor is up so then let us advertise the prefix for the individual routers go to router bgp one advertiser network is 1.1.1.0 and the mask is 255.25.55.0 similarly go to r2 and configure the prefix right so router bgp 2 and the network prefix is 2.2.0 mask is 25.25.2 i think you are following so the third thing go to the router configuration mode router bgp 2 and the prefix is 3.3.3.0 and the mask is 25.50 so first i will configure the bgp navy relationship then i check the neighbor right neighbor is established on all these three routers and the second thing i advertise this loopback as a prefix on individual routers so now i am going to check the bgb routing table type so let us check the bgp routing table that is show ipbgp yeah we are able to see the bgp routing table and the corresponding prefaces so from r1 network we are able to see the 2.2 prefix and 3.3 is getting advertised right so what i'm going to do i'm going to set the local preference attribute so what we can do we can make this as the highest preferred path or this either this we can do so let us make this path as a preferred path that means i need to set the value as more than 100 my default value is 100 so what i am going to do i am going to set this attribute as the highest attribute so let us go to the individual navy relationship router bgp one right so let us see the neighbor neighbor is uh yeah 12.2 so this will make it as a preferred path so what we can do we can set the route map statement so go to the individual route map statement and set the local inbound since it is shared within the internal ibg universe i am setting as in so then i have to configure the individual route map statement right route map loc lock and permit statement followed by the sequence number and set the local difference attributes always set it more than 100 right so make it as 900 so what happened this path will make it as a preferred 12.2 so for r1 so this will take this as the preferred outbound part for reaching 2.2 or 3.3 network right that is the purpose of local preference so let us check the routing table again so it should show up in the routing table so routing table what i think it will show is it will show all the prefixes and it will show all the attributes so these are the default attributes network desktop metric and local preference right so the next step is the default attribute and local preference it's under that report it will always prefer for the highest local preference so let us see the show ipbgp still the value i have changed right nine and that still it is not reflecting in the network prefix right so what we can do we can just do a soft reset clear ipbgp soft residue to specify the value 192.16.12.2 remote neighbor will make it a soft in similarly 13.2 so i'm doing a soft reset so now let us check the show ip bgp neighbor relationship because software is really very simple if you are doing hard reset what happen it will kill all the bgp enable relationship then it will take time to for the bgp neighbor to come up then it will advertise the prefix after that it will show up in the bgb routing table so for preventing all scenario i am just doing a soft reset using this command two command so once i am doing a soft reset what happened delete a request for a fresh update from the neighbor right so it will request for the update so now it is getting there now the prefix attribute right so the local difference attribute is advertising in the bgp table so what uh path it is taking let us see for 1.1 network it is taking this path as a preferred path so 2.2 it is taking this path as a preferred path because of the highest local parents value similarly for reaching 3.3 network it is taking 12.2 as a preferred path because of the highest local preference attribute because default standards would always take the highest preferred outbound path so our own network for reaching either 2.2 net prefix or 3.3 prefix it is taking 12.2 as a highest preferred outbound path because this will be taken as the highest local difference attribute and it always prefers the highest outbound path so this path will be the preferred path preferred outbound part for reaching this 2.2 network or 3.3 network so that's the thing you are able to see right so this is the purpose of local difference the main point you remember is it is sent to internal neighbors and all the highest local differences uh preferred and it is used to prefer the outbound path right i hope you understood thanks for watching please subscribe me for more videos thank you have a wonderful day
Info
Channel: Selvajegan Networking Channel
Views: 322
Rating: undefined out of 5
Keywords: BGP Local Preference, Local Preference
Id: y8qsff4QPtc
Channel Id: undefined
Length: 8min 50sec (530 seconds)
Published: Thu Jan 14 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.