This post will skim over BGP packets and attributes.
BGP Packet Types: Link to heading
There are five types of packets in BGP:
- Open
- Keepalive
- Notification
- Update
- Refresh
BGP Attributes: Link to heading
There are four categories of attributes with different types in each:
- Well-known Mandatory - These attributes must be present in any BGP update.
- Origin
- AS Path - Loop protection
- Next-Hop
- Well-known Discretionary - Must be in every BGP implementation but is not required in every BGP update.
- Local Prefrence
- Atomic Aggregator
- Optional Transitive - If present it should be passed long to the next peers.
- Aggregator
- Community (4 octets)
- Extended Community (8 octets)
- Optional Non-Transitive - Doesn't have to be updated to peers.
- Multi Exit Discriminator (MED)
- Originator ID
- Cluster List
- Multiprotocol Reachable NLRI
- Multiprotocol Unreachable NLRI
BGP Route Selection: Link to heading
- Highest Local Preference First
- Shortest AS Path
- Lowest Origin Value
- Lowest MED value
- Lowest IGP metric as AS exit
- Longest uptime of eBGP peer or lowest router ID
- Lowest Peeer IP Address