BGP is an external gateway protocol designed for the TCP/ IP Internet to be used between multiple autonomous domains. It is neither based on the pure link state algorithm nor on the pure distance vector algorithm. Its main function is to exchange network accessible information with other autonomous domains of BGP. Each autonomous domain can run a different internal gateway protocol. BGP update information includes pairwise information of network number/ autonomous domain path. An autonomous domain path includes an autonomous domain string that must be passed to a particular network, and these updates are transmitted via TCP to guarantee the reliability of the transmission.
BGP-4 is fast becoming the de facto Internet external routing protocol standard, and BGP protocol is often used between ISP.
The BGP system runs on a specific router as a high-level protocol. When the system starts, the BGP router exchanges routing information with peers by sending the entire BGP routing table, and then only the update message is exchanged. The system is running to check if the connections between the two are normal by receiving and sending keep-alive messages.
The router that sends the BGP message is called the BGP speaker, which continuously receives or generates new paths from the message and advertise it to other BGP spokesmen. When the BGP spokesperson receives a new route from another autonomous system by advertisement, if the route is better than the currently known route, Or there is currently no receive route, which it advertises to all other BGP spokespersons in the autonomous system. A BGP spokesman will also refer to the other BGP spokesmen with whom he exchanges messages as peer, and several related peer may form a peer group.
BGP runs on a router in two ways:
When the BGP is running inside the same autonomous system (AS), it is called IBGP. When BGP is running between autonomous systems, it is called EBGP.
The operation of the BGP protocol machine is message driven and its messages can be divided into four categories:
Open message is the first message sent after the connection was established, and is used to establish a connection between the peers of the BGP. Notification message is an error Notification message. Keep-alive message is a message used to detect the validity of a connection. Update message is the most important information in a BGP system for exchanging routing information between peers, It consists of up to three parts, namely unreachable routing, path attributes, and network reachability information NLRI (network layer reach/reachable information).