SlideShare une entreprise Scribd logo
1  sur  26
Télécharger pour lire hors ligne
Presentation on
BGP Path Selection & Attributes
BGP Weight
&
BGP AS-Path Prepending
Prsented By
• Shawan Roy
• Mobile: 01933827475
BGP Path Selection &
Attributes
Difference Between BGP & IGP Path Selection
• BGP (Border Gateway Protocol)
routers usually receive multiple
paths to the same destination.
• BGP however, selects the best
path based on a set of
attributes.
• IGPs select the path with the
lowest metric. For example:
• RIP selects the path with the
lowest hop count.
• OSPF selects the path with the
lowest cost.
• EIGRP selects the path with the
highest bandwidth and lowest
delay (unless you change the K
values).
How to know about best path in BGP?
Path is selected based on the following attributes
Priority Attribute
1 Weight
2 Local Preference
3 Originate
4 AS path length
5 Origin code
6 MED (MULTI_EXIT_DISC)
7 eBGP path over iBGP path
8 Shortest IGP path to BGP next hop
9 Oldest path
10 Router ID
11 Neighbor IP address
Quick overview of Each Attribute (1 of 3)
• Weight: Prefer the path with the highest weight. This is a value that is local to the router
and it’s Cisco proprietary. The default value is 0 for all routes that are not originated by
the local router.
• Local Preference: The local preference is used within an autonomous system and
exchanged between iBGP routers. We prefer the path with the highest local preference.
The default value is 100.
• Originate: Prefer the path that the local router originated. In the BGP table, you will see
next hop 0.0.0.0. You can get a path in the BGP table through the BGP network
command, aggregation, or redistribution. A BGP router will prefer routes that it installed
into BGP itself over a route that another router installed in BGP.
• AS path length: Prefer the path with the shortest AS path length. For example, AS path 1
2 3 is preferred over AS path 1 2 3 4 5.
Quick overview of Each Attribute (2 of 3)
• Origin code: Prefer the lowest origin code. There are three origin
codes: IGP, EGP, INCOMPLETE. IGP is lower than EGP and EGP is lower
than INCOMPLETE.
• MED (MULTI_EXIT_DISC): Prefer the path with the lowest MED. The
MED is exchanged between autonomous systems.
• eBGP path over iBGP path: Prefer eBGP (external BGP) over iBGP
(internal BGP) paths.
• Shortest IGP path to BGP next hop: Prefer the path within the
autonomous system with the lowest IGP metric to the BGP next hop.
Quick overview of Each Attribute (3 of 3)
• Oldest Path: Prefer the path that we received first, in other words, the
oldest path.
• Router ID: Prefer the path with the lowest BGP neighbor router ID.
The router ID is based on the highest IP address. If you have a
loopback interface, then the IP address on the loopback will be used.
The router ID can also be manually configured.
• Neighbor IP address: Prefer the path with the lowest neighbor IP
address. If you have two eBGP routers and two links in between then
the router ID will be the same. In this case, the neighbor IP address is
the tiebreaker.
BGP Weight Attribute
About BGP Weight Attribute (1 of 2)
• BGP weight attribute is a Cisco proprietary path attribute that is local
to the router and is used to influence local path selection on a certain
router.
• BGP weight is the first tie breaker for best path selection on a Cisco
router, the attribute is not propagated to other routers in the BGP
updates and only found on Cisco routers.
• The path with the highest weight is selected as the best toward a
destination.
About BGP Weight Attribute (2 of 2)
• The weight can be a number from 0 to 65,535. Paths that the router
originates have a weight of 32,768 by default, and other paths have a
weight of 0. As we mentioned earlier the path with the highest weight
value wins.
• BGP weight can be set using three ways on a Cisco router. Those are:
assigned per neighbor, using AS-Path access lists, using route-maps
(complex).
• BGP weight is the easiest way to manipulate the BGP path selection
on a single Cisco router for outbound traffic. The attribute is local and
will not be propagated to other routers in the network within the BGP
update messages.
BGP Weight Attribute Assigned per neighbor (1 of
4)
• R1 to get to R6 it has chosen the path through
R4-
When both paths are external prefer the oldest one –
This is the tiebreaker!
BGP Weight Attribute Assigned per neighbor (2 of
4)
• To prove that we can restart the bgp process on R4 to
make R5 the oldest route. On R4 I have done a clear ip
bgp * This now makes the route through R5 the oldest
one and is preferred.
BGP Weight Attribute Assigned per neighbor (3 of
4)
• Under BGP enter the following command – neighbor
10.0.14.4 weight 100
BGP Weight Attribute Assigned per neighbor (4 of
4)
• You will also notice that all prefixes received from R4 have
also had their weight changed to 100
BGP Weight Attribute Using AS-Path access lists (1
of 2)
• For this example we only want to set the weight for the
6.6.6.6/32 prefix. First we need to match this prefix in an
access list
This is now applied to the neighbor statement for R4 – we also need to remove the previous
weight attribute
BGP Weight Attribute Using AS-Path access lists (1
of 2)
• You can see now that we have changed the weight
attribute for the 6.6.6.6/32 prefix only. All other routes
have the default weight of 0.
BGP AS-Path Prepending
About BGP AS-Path Prepending
• AS-Path prepending is a way to manipulate the AS-Path attribute of a
BGP route.
• It allows prepending multiple entries of AS to a BGP route.
• This can come as a workaround if a specific path is required to be
followed, and other means like Multi-Exit Discriminator (MED) is not
supported.
• AS-Path prepending can be applied to inbound and outbound
direction using route-maps.
Outbound AS-Path Prepending (1 of 2)
• AS-Path prepending can be
applied to outbound direction
on R3 router as below-
• Outbound AS-Path prepending on
R3-
Outbound AS-Path Prepending (2 of 2)
• When R3 router advertises its 10.1.1.0/24 network
to R2 router, it prepends its own AS 200 multiple
times. However, R1 router receives the original
BGP route with a single AS-path entry.
• BGP tables on R1 and R2-
R2 router has two paths to 10.1.1.0/24. However, it
chooses the path through R1 since that path has
shortest AS-Path (indicated by a > sign, meaning best
route). Hence, the direct path through R3 router can
act as a backup path.
Inbound AS-Path Prepending (1 of 2)
• Inbound AS-Path prepending is configured using
set as-path prepend last-as command under route-
map which is then applied in inbound direction.
The last-as keyword copies the AS number of the
neighbor advertising the BGP route that matches
the route-map.
• Inbound AS-Path prepending on R1-
Inbound AS-Path Prepending (2 of 2)
• This configuration causes R1 to prepend the AS
number of R3 twice before installing in the BGP
table. As seen below, R3 does not prepend any AS
number by itself.
• BGP tables on R1 and R3-
References
• https://networklessons.com/bgp/bgp-attributes-and-path-selection
• http://www.networkers-online.com/blog/2012/05/bgp-weight/
• https://www.rogerperkin.co.uk/bgp/bgp-weight-attribute/
• https://sites.google.com/site/amitsciscozone/home/bgp/bgp-as-
path-prepending-and-as-path-filters
Thank You!

Contenu connexe

Tendances

EIGRP (Enhanced Interior Gateway Routing Protocol)
EIGRP (Enhanced Interior Gateway Routing Protocol)EIGRP (Enhanced Interior Gateway Routing Protocol)
EIGRP (Enhanced Interior Gateway Routing Protocol)NetProtocol Xpert
 
STP (spanning tree protocol)
STP (spanning tree protocol)STP (spanning tree protocol)
STP (spanning tree protocol)Netwax Lab
 
IOS Zone based Firewall
IOS Zone based FirewallIOS Zone based Firewall
IOS Zone based FirewallNetwax Lab
 
ospf routing protocol
ospf routing protocolospf routing protocol
ospf routing protocolAmeer Agel
 
An Overview of Border Gateway Protocol (BGP)
An Overview of Border Gateway Protocol (BGP)An Overview of Border Gateway Protocol (BGP)
An Overview of Border Gateway Protocol (BGP)Jasim Alam
 
Routing and OSPF
Routing and OSPFRouting and OSPF
Routing and OSPFarpit
 
BGP Multihoming Techniques
BGP Multihoming TechniquesBGP Multihoming Techniques
BGP Multihoming TechniquesAPNIC
 
QoS Cheatsheet by packetlife.net
QoS Cheatsheet by packetlife.netQoS Cheatsheet by packetlife.net
QoS Cheatsheet by packetlife.netFebrian ‎
 
Open Shortest Path First (OSPF) || 2020 || Ser-2
Open Shortest Path First (OSPF) || 2020 || Ser-2Open Shortest Path First (OSPF) || 2020 || Ser-2
Open Shortest Path First (OSPF) || 2020 || Ser-2Nutan Singh
 
BGP Techniques for Network Operators
BGP Techniques for Network OperatorsBGP Techniques for Network Operators
BGP Techniques for Network OperatorsAPNIC
 
CCNA Advanced Routing Protocols
CCNA Advanced Routing ProtocolsCCNA Advanced Routing Protocols
CCNA Advanced Routing ProtocolsDsunte Wilson
 

Tendances (20)

BGP
BGP BGP
BGP
 
EIGRP (Enhanced Interior Gateway Routing Protocol)
EIGRP (Enhanced Interior Gateway Routing Protocol)EIGRP (Enhanced Interior Gateway Routing Protocol)
EIGRP (Enhanced Interior Gateway Routing Protocol)
 
STP (spanning tree protocol)
STP (spanning tree protocol)STP (spanning tree protocol)
STP (spanning tree protocol)
 
IOS Zone based Firewall
IOS Zone based FirewallIOS Zone based Firewall
IOS Zone based Firewall
 
ospf routing protocol
ospf routing protocolospf routing protocol
ospf routing protocol
 
Cisco ospf
Cisco ospf Cisco ospf
Cisco ospf
 
An Overview of Border Gateway Protocol (BGP)
An Overview of Border Gateway Protocol (BGP)An Overview of Border Gateway Protocol (BGP)
An Overview of Border Gateway Protocol (BGP)
 
Ospf area types
Ospf area typesOspf area types
Ospf area types
 
Routing and OSPF
Routing and OSPFRouting and OSPF
Routing and OSPF
 
Border Gatway Protocol
Border Gatway ProtocolBorder Gatway Protocol
Border Gatway Protocol
 
BGP Multihoming Techniques
BGP Multihoming TechniquesBGP Multihoming Techniques
BGP Multihoming Techniques
 
OSPF v3
OSPF v3OSPF v3
OSPF v3
 
QoS Cheatsheet by packetlife.net
QoS Cheatsheet by packetlife.netQoS Cheatsheet by packetlife.net
QoS Cheatsheet by packetlife.net
 
Mpls
MplsMpls
Mpls
 
Eigrp.ppt
Eigrp.pptEigrp.ppt
Eigrp.ppt
 
Open Shortest Path First (OSPF) || 2020 || Ser-2
Open Shortest Path First (OSPF) || 2020 || Ser-2Open Shortest Path First (OSPF) || 2020 || Ser-2
Open Shortest Path First (OSPF) || 2020 || Ser-2
 
BGP Techniques for Network Operators
BGP Techniques for Network OperatorsBGP Techniques for Network Operators
BGP Techniques for Network Operators
 
Bgp
BgpBgp
Bgp
 
CCNA Advanced Routing Protocols
CCNA Advanced Routing ProtocolsCCNA Advanced Routing Protocols
CCNA Advanced Routing Protocols
 
Implementing cisco mpls
Implementing cisco mplsImplementing cisco mpls
Implementing cisco mpls
 

Similaire à BGP Path Selection & Attributes BGP Weight & BGP AS-Path Prepending

bgp features presentation routing protocle
bgp features presentation routing protoclebgp features presentation routing protocle
bgp features presentation routing protocleBadr Belhajja
 
BGP (border gateway routing protocol)
BGP (border gateway routing protocol)BGP (border gateway routing protocol)
BGP (border gateway routing protocol)Netwax Lab
 
Describe the different metrics that BGP can use in building a routing.docx
Describe the different metrics that BGP can use in building a routing.docxDescribe the different metrics that BGP can use in building a routing.docx
Describe the different metrics that BGP can use in building a routing.docxearleanp
 
PLNOG15: BGP New Advanced Features - Piotr Wojciechowski
PLNOG15: BGP New Advanced Features - Piotr WojciechowskiPLNOG15: BGP New Advanced Features - Piotr Wojciechowski
PLNOG15: BGP New Advanced Features - Piotr WojciechowskiPROIDEA
 
Study Notes BGP Exam
Study Notes BGP ExamStudy Notes BGP Exam
Study Notes BGP ExamDuane Bodle
 
Cisco BGP Exam 642-661 Review Notes
Cisco BGP Exam 642-661 Review NotesCisco BGP Exam 642-661 Review Notes
Cisco BGP Exam 642-661 Review NotesDuane Bodle
 
Computer network (14)
Computer network (14)Computer network (14)
Computer network (14)NYversity
 
Routing Protocol EIGRP
Routing Protocol EIGRPRouting Protocol EIGRP
Routing Protocol EIGRPDmitry Figol
 
Bgp 6 advanced transit as issues
Bgp 6   advanced transit as issuesBgp 6   advanced transit as issues
Bgp 6 advanced transit as issuesAuguste Behe
 
PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...
PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...
PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...PROIDEA
 
Routing Protocol in detail
Routing Protocol in detailRouting Protocol in detail
Routing Protocol in detailDil_E_Dastan
 
15 coms 525 tcpip - border gateway protocols
15    coms 525 tcpip - border gateway protocols15    coms 525 tcpip - border gateway protocols
15 coms 525 tcpip - border gateway protocolsPalanivel Kuppusamy
 

Similaire à BGP Path Selection & Attributes BGP Weight & BGP AS-Path Prepending (20)

bgp features presentation routing protocle
bgp features presentation routing protoclebgp features presentation routing protocle
bgp features presentation routing protocle
 
Bgp training
Bgp trainingBgp training
Bgp training
 
11 bgp-ethernet
11 bgp-ethernet11 bgp-ethernet
11 bgp-ethernet
 
BGP (border gateway routing protocol)
BGP (border gateway routing protocol)BGP (border gateway routing protocol)
BGP (border gateway routing protocol)
 
Describe the different metrics that BGP can use in building a routing.docx
Describe the different metrics that BGP can use in building a routing.docxDescribe the different metrics that BGP can use in building a routing.docx
Describe the different metrics that BGP can use in building a routing.docx
 
PLNOG15: BGP New Advanced Features - Piotr Wojciechowski
PLNOG15: BGP New Advanced Features - Piotr WojciechowskiPLNOG15: BGP New Advanced Features - Piotr Wojciechowski
PLNOG15: BGP New Advanced Features - Piotr Wojciechowski
 
Study Notes BGP Exam
Study Notes BGP ExamStudy Notes BGP Exam
Study Notes BGP Exam
 
Part8-ibgp.pptx
Part8-ibgp.pptxPart8-ibgp.pptx
Part8-ibgp.pptx
 
Cisco BGP Exam 642-661 Review Notes
Cisco BGP Exam 642-661 Review NotesCisco BGP Exam 642-661 Review Notes
Cisco BGP Exam 642-661 Review Notes
 
BGP Advanced topics
BGP Advanced topicsBGP Advanced topics
BGP Advanced topics
 
Computer network (14)
Computer network (14)Computer network (14)
Computer network (14)
 
Routing Protocol EIGRP
Routing Protocol EIGRPRouting Protocol EIGRP
Routing Protocol EIGRP
 
EIGRP Protocol.pptx
EIGRP Protocol.pptxEIGRP Protocol.pptx
EIGRP Protocol.pptx
 
Bgp 6 advanced transit as issues
Bgp 6   advanced transit as issuesBgp 6   advanced transit as issues
Bgp 6 advanced transit as issues
 
PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...
PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...
PLNOG 6: Rafał Szarecki - Routing w Sieci - Praktyczne aspekty implementacji ...
 
Routing Protocol in detail
Routing Protocol in detailRouting Protocol in detail
Routing Protocol in detail
 
B G P Part2
B G P  Part2B G P  Part2
B G P Part2
 
B G P Part2
B G P  Part2B G P  Part2
B G P Part2
 
15 coms 525 tcpip - border gateway protocols
15    coms 525 tcpip - border gateway protocols15    coms 525 tcpip - border gateway protocols
15 coms 525 tcpip - border gateway protocols
 
Bgp Toc
Bgp TocBgp Toc
Bgp Toc
 

Plus de Shawan Roy

Presentation on Pretreatment (Scouring & Bleaching)
Presentation on Pretreatment (Scouring & Bleaching)Presentation on Pretreatment (Scouring & Bleaching)
Presentation on Pretreatment (Scouring & Bleaching)Shawan Roy
 
Presentation on Smart Textile
Presentation on Smart TextilePresentation on Smart Textile
Presentation on Smart TextileShawan Roy
 
Assignment on Camouflage Fabric
Assignment on Camouflage FabricAssignment on Camouflage Fabric
Assignment on Camouflage FabricShawan Roy
 
Presentation on Camouflage Fabric
Presentation on Camouflage FabricPresentation on Camouflage Fabric
Presentation on Camouflage FabricShawan Roy
 
Calculation of rf for maddar & turmeric
Calculation of rf for maddar & turmericCalculation of rf for maddar & turmeric
Calculation of rf for maddar & turmericShawan Roy
 
Assignment on latest development on dyeing technique
Assignment on latest development on dyeing techniqueAssignment on latest development on dyeing technique
Assignment on latest development on dyeing techniqueShawan Roy
 
Astm standard on apparel (Source Copy)
Astm standard on apparel (Source Copy)Astm standard on apparel (Source Copy)
Astm standard on apparel (Source Copy)Shawan Roy
 
ASTM Standard on Apparel
ASTM Standard on ApparelASTM Standard on Apparel
ASTM Standard on ApparelShawan Roy
 
Weft knit fabric geometry
Weft knit fabric geometryWeft knit fabric geometry
Weft knit fabric geometryShawan Roy
 
Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)
Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)
Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)Shawan Roy
 
Presentation on children's wear
Presentation on children's wearPresentation on children's wear
Presentation on children's wearShawan Roy
 
Method for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structureMethod for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structureShawan Roy
 
Method for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structureMethod for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structureShawan Roy
 
Electromagnetic field (emf)
Electromagnetic field (emf)Electromagnetic field (emf)
Electromagnetic field (emf)Shawan Roy
 

Plus de Shawan Roy (15)

Presentation on Pretreatment (Scouring & Bleaching)
Presentation on Pretreatment (Scouring & Bleaching)Presentation on Pretreatment (Scouring & Bleaching)
Presentation on Pretreatment (Scouring & Bleaching)
 
Presentation on Smart Textile
Presentation on Smart TextilePresentation on Smart Textile
Presentation on Smart Textile
 
Assignment on Camouflage Fabric
Assignment on Camouflage FabricAssignment on Camouflage Fabric
Assignment on Camouflage Fabric
 
Presentation on Camouflage Fabric
Presentation on Camouflage FabricPresentation on Camouflage Fabric
Presentation on Camouflage Fabric
 
Calculation of rf for maddar & turmeric
Calculation of rf for maddar & turmericCalculation of rf for maddar & turmeric
Calculation of rf for maddar & turmeric
 
Assignment on latest development on dyeing technique
Assignment on latest development on dyeing techniqueAssignment on latest development on dyeing technique
Assignment on latest development on dyeing technique
 
Astm standard on apparel (Source Copy)
Astm standard on apparel (Source Copy)Astm standard on apparel (Source Copy)
Astm standard on apparel (Source Copy)
 
ASTM Standard on Apparel
ASTM Standard on ApparelASTM Standard on Apparel
ASTM Standard on Apparel
 
Weft knit fabric geometry
Weft knit fabric geometryWeft knit fabric geometry
Weft knit fabric geometry
 
Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)
Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)
Presentation on Weft Knitting Machine (Single Jersey, Rib & Interlock)
 
Presentation on children's wear
Presentation on children's wearPresentation on children's wear
Presentation on children's wear
 
Method for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structureMethod for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structure
 
RN cleaner
RN cleanerRN cleaner
RN cleaner
 
Method for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structureMethod for measuring or investigation of fiber structure
Method for measuring or investigation of fiber structure
 
Electromagnetic field (emf)
Electromagnetic field (emf)Electromagnetic field (emf)
Electromagnetic field (emf)
 

Dernier

Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Association for Project Management
 
Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...
Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...
Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...HetalPathak10
 
6 ways Samsung’s Interactive Display powered by Android changes the classroom
6 ways Samsung’s Interactive Display powered by Android changes the classroom6 ways Samsung’s Interactive Display powered by Android changes the classroom
6 ways Samsung’s Interactive Display powered by Android changes the classroomSamsung Business USA
 
How to Uninstall a Module in Odoo 17 Using Command Line
How to Uninstall a Module in Odoo 17 Using Command LineHow to Uninstall a Module in Odoo 17 Using Command Line
How to Uninstall a Module in Odoo 17 Using Command LineCeline George
 
4.11.24 Poverty and Inequality in America.pptx
4.11.24 Poverty and Inequality in America.pptx4.11.24 Poverty and Inequality in America.pptx
4.11.24 Poverty and Inequality in America.pptxmary850239
 
Narcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdfNarcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdfPrerana Jadhav
 
Q-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITWQ-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITWQuiz Club NITW
 
ClimART Action | eTwinning Project
ClimART Action    |    eTwinning ProjectClimART Action    |    eTwinning Project
ClimART Action | eTwinning Projectjordimapav
 
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxBIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxSayali Powar
 
Congestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationCongestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationdeepaannamalai16
 
Mythology Quiz-4th April 2024, Quiz Club NITW
Mythology Quiz-4th April 2024, Quiz Club NITWMythology Quiz-4th April 2024, Quiz Club NITW
Mythology Quiz-4th April 2024, Quiz Club NITWQuiz Club NITW
 
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITWQ-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITWQuiz Club NITW
 
An Overview of the Calendar App in Odoo 17 ERP
An Overview of the Calendar App in Odoo 17 ERPAn Overview of the Calendar App in Odoo 17 ERP
An Overview of the Calendar App in Odoo 17 ERPCeline George
 
Employablity presentation and Future Career Plan.pptx
Employablity presentation and Future Career Plan.pptxEmployablity presentation and Future Career Plan.pptx
Employablity presentation and Future Career Plan.pptxryandux83rd
 
4.9.24 School Desegregation in Boston.pptx
4.9.24 School Desegregation in Boston.pptx4.9.24 School Desegregation in Boston.pptx
4.9.24 School Desegregation in Boston.pptxmary850239
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...Nguyen Thanh Tu Collection
 

Dernier (20)

Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
 
Mattingly "AI & Prompt Design" - Introduction to Machine Learning"
Mattingly "AI & Prompt Design" - Introduction to Machine Learning"Mattingly "AI & Prompt Design" - Introduction to Machine Learning"
Mattingly "AI & Prompt Design" - Introduction to Machine Learning"
 
Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...
Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...
Satirical Depths - A Study of Gabriel Okara's Poem - 'You Laughed and Laughed...
 
6 ways Samsung’s Interactive Display powered by Android changes the classroom
6 ways Samsung’s Interactive Display powered by Android changes the classroom6 ways Samsung’s Interactive Display powered by Android changes the classroom
6 ways Samsung’s Interactive Display powered by Android changes the classroom
 
How to Uninstall a Module in Odoo 17 Using Command Line
How to Uninstall a Module in Odoo 17 Using Command LineHow to Uninstall a Module in Odoo 17 Using Command Line
How to Uninstall a Module in Odoo 17 Using Command Line
 
4.11.24 Poverty and Inequality in America.pptx
4.11.24 Poverty and Inequality in America.pptx4.11.24 Poverty and Inequality in America.pptx
4.11.24 Poverty and Inequality in America.pptx
 
Narcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdfNarcotic and Non Narcotic Analgesic..pdf
Narcotic and Non Narcotic Analgesic..pdf
 
Q-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITWQ-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITW
 
ClimART Action | eTwinning Project
ClimART Action    |    eTwinning ProjectClimART Action    |    eTwinning Project
ClimART Action | eTwinning Project
 
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxBIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
 
Chi-Square Test Non Parametric Test Categorical Variable
Chi-Square Test Non Parametric Test Categorical VariableChi-Square Test Non Parametric Test Categorical Variable
Chi-Square Test Non Parametric Test Categorical Variable
 
Faculty Profile prashantha K EEE dept Sri Sairam college of Engineering
Faculty Profile prashantha K EEE dept Sri Sairam college of EngineeringFaculty Profile prashantha K EEE dept Sri Sairam college of Engineering
Faculty Profile prashantha K EEE dept Sri Sairam college of Engineering
 
Congestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentationCongestive Cardiac Failure..presentation
Congestive Cardiac Failure..presentation
 
Mythology Quiz-4th April 2024, Quiz Club NITW
Mythology Quiz-4th April 2024, Quiz Club NITWMythology Quiz-4th April 2024, Quiz Club NITW
Mythology Quiz-4th April 2024, Quiz Club NITW
 
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITWQ-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
Q-Factor HISPOL Quiz-6th April 2024, Quiz Club NITW
 
An Overview of the Calendar App in Odoo 17 ERP
An Overview of the Calendar App in Odoo 17 ERPAn Overview of the Calendar App in Odoo 17 ERP
An Overview of the Calendar App in Odoo 17 ERP
 
Employablity presentation and Future Career Plan.pptx
Employablity presentation and Future Career Plan.pptxEmployablity presentation and Future Career Plan.pptx
Employablity presentation and Future Career Plan.pptx
 
4.9.24 School Desegregation in Boston.pptx
4.9.24 School Desegregation in Boston.pptx4.9.24 School Desegregation in Boston.pptx
4.9.24 School Desegregation in Boston.pptx
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...
BÀI TẬP BỔ TRỢ TIẾNG ANH 8 - I-LEARN SMART WORLD - CẢ NĂM - CÓ FILE NGHE (BẢN...
 
Mattingly "AI & Prompt Design: Large Language Models"
Mattingly "AI & Prompt Design: Large Language Models"Mattingly "AI & Prompt Design: Large Language Models"
Mattingly "AI & Prompt Design: Large Language Models"
 

BGP Path Selection & Attributes BGP Weight & BGP AS-Path Prepending

  • 1. Presentation on BGP Path Selection & Attributes BGP Weight & BGP AS-Path Prepending
  • 2. Prsented By • Shawan Roy • Mobile: 01933827475
  • 3. BGP Path Selection & Attributes
  • 4. Difference Between BGP & IGP Path Selection • BGP (Border Gateway Protocol) routers usually receive multiple paths to the same destination. • BGP however, selects the best path based on a set of attributes. • IGPs select the path with the lowest metric. For example: • RIP selects the path with the lowest hop count. • OSPF selects the path with the lowest cost. • EIGRP selects the path with the highest bandwidth and lowest delay (unless you change the K values).
  • 5. How to know about best path in BGP?
  • 6. Path is selected based on the following attributes Priority Attribute 1 Weight 2 Local Preference 3 Originate 4 AS path length 5 Origin code 6 MED (MULTI_EXIT_DISC) 7 eBGP path over iBGP path 8 Shortest IGP path to BGP next hop 9 Oldest path 10 Router ID 11 Neighbor IP address
  • 7. Quick overview of Each Attribute (1 of 3) • Weight: Prefer the path with the highest weight. This is a value that is local to the router and it’s Cisco proprietary. The default value is 0 for all routes that are not originated by the local router. • Local Preference: The local preference is used within an autonomous system and exchanged between iBGP routers. We prefer the path with the highest local preference. The default value is 100. • Originate: Prefer the path that the local router originated. In the BGP table, you will see next hop 0.0.0.0. You can get a path in the BGP table through the BGP network command, aggregation, or redistribution. A BGP router will prefer routes that it installed into BGP itself over a route that another router installed in BGP. • AS path length: Prefer the path with the shortest AS path length. For example, AS path 1 2 3 is preferred over AS path 1 2 3 4 5.
  • 8. Quick overview of Each Attribute (2 of 3) • Origin code: Prefer the lowest origin code. There are three origin codes: IGP, EGP, INCOMPLETE. IGP is lower than EGP and EGP is lower than INCOMPLETE. • MED (MULTI_EXIT_DISC): Prefer the path with the lowest MED. The MED is exchanged between autonomous systems. • eBGP path over iBGP path: Prefer eBGP (external BGP) over iBGP (internal BGP) paths. • Shortest IGP path to BGP next hop: Prefer the path within the autonomous system with the lowest IGP metric to the BGP next hop.
  • 9. Quick overview of Each Attribute (3 of 3) • Oldest Path: Prefer the path that we received first, in other words, the oldest path. • Router ID: Prefer the path with the lowest BGP neighbor router ID. The router ID is based on the highest IP address. If you have a loopback interface, then the IP address on the loopback will be used. The router ID can also be manually configured. • Neighbor IP address: Prefer the path with the lowest neighbor IP address. If you have two eBGP routers and two links in between then the router ID will be the same. In this case, the neighbor IP address is the tiebreaker.
  • 11. About BGP Weight Attribute (1 of 2) • BGP weight attribute is a Cisco proprietary path attribute that is local to the router and is used to influence local path selection on a certain router. • BGP weight is the first tie breaker for best path selection on a Cisco router, the attribute is not propagated to other routers in the BGP updates and only found on Cisco routers. • The path with the highest weight is selected as the best toward a destination.
  • 12. About BGP Weight Attribute (2 of 2) • The weight can be a number from 0 to 65,535. Paths that the router originates have a weight of 32,768 by default, and other paths have a weight of 0. As we mentioned earlier the path with the highest weight value wins. • BGP weight can be set using three ways on a Cisco router. Those are: assigned per neighbor, using AS-Path access lists, using route-maps (complex). • BGP weight is the easiest way to manipulate the BGP path selection on a single Cisco router for outbound traffic. The attribute is local and will not be propagated to other routers in the network within the BGP update messages.
  • 13. BGP Weight Attribute Assigned per neighbor (1 of 4) • R1 to get to R6 it has chosen the path through R4- When both paths are external prefer the oldest one – This is the tiebreaker!
  • 14. BGP Weight Attribute Assigned per neighbor (2 of 4) • To prove that we can restart the bgp process on R4 to make R5 the oldest route. On R4 I have done a clear ip bgp * This now makes the route through R5 the oldest one and is preferred.
  • 15. BGP Weight Attribute Assigned per neighbor (3 of 4) • Under BGP enter the following command – neighbor 10.0.14.4 weight 100
  • 16. BGP Weight Attribute Assigned per neighbor (4 of 4) • You will also notice that all prefixes received from R4 have also had their weight changed to 100
  • 17. BGP Weight Attribute Using AS-Path access lists (1 of 2) • For this example we only want to set the weight for the 6.6.6.6/32 prefix. First we need to match this prefix in an access list This is now applied to the neighbor statement for R4 – we also need to remove the previous weight attribute
  • 18. BGP Weight Attribute Using AS-Path access lists (1 of 2) • You can see now that we have changed the weight attribute for the 6.6.6.6/32 prefix only. All other routes have the default weight of 0.
  • 20. About BGP AS-Path Prepending • AS-Path prepending is a way to manipulate the AS-Path attribute of a BGP route. • It allows prepending multiple entries of AS to a BGP route. • This can come as a workaround if a specific path is required to be followed, and other means like Multi-Exit Discriminator (MED) is not supported. • AS-Path prepending can be applied to inbound and outbound direction using route-maps.
  • 21. Outbound AS-Path Prepending (1 of 2) • AS-Path prepending can be applied to outbound direction on R3 router as below- • Outbound AS-Path prepending on R3-
  • 22. Outbound AS-Path Prepending (2 of 2) • When R3 router advertises its 10.1.1.0/24 network to R2 router, it prepends its own AS 200 multiple times. However, R1 router receives the original BGP route with a single AS-path entry. • BGP tables on R1 and R2- R2 router has two paths to 10.1.1.0/24. However, it chooses the path through R1 since that path has shortest AS-Path (indicated by a > sign, meaning best route). Hence, the direct path through R3 router can act as a backup path.
  • 23. Inbound AS-Path Prepending (1 of 2) • Inbound AS-Path prepending is configured using set as-path prepend last-as command under route- map which is then applied in inbound direction. The last-as keyword copies the AS number of the neighbor advertising the BGP route that matches the route-map. • Inbound AS-Path prepending on R1-
  • 24. Inbound AS-Path Prepending (2 of 2) • This configuration causes R1 to prepend the AS number of R3 twice before installing in the BGP table. As seen below, R3 does not prepend any AS number by itself. • BGP tables on R1 and R3-
  • 25. References • https://networklessons.com/bgp/bgp-attributes-and-path-selection • http://www.networkers-online.com/blog/2012/05/bgp-weight/ • https://www.rogerperkin.co.uk/bgp/bgp-weight-attribute/ • https://sites.google.com/site/amitsciscozone/home/bgp/bgp-as- path-prepending-and-as-path-filters