CN111917577A - BGP routing information acquisition method, BGP routing information acquisition device, computer equipment and storage medium - Google Patents

BGP routing information acquisition method, BGP routing information acquisition device, computer equipment and storage medium Download PDF

Info

Publication number
CN111917577A
CN111917577A CN202010746221.9A CN202010746221A CN111917577A CN 111917577 A CN111917577 A CN 111917577A CN 202010746221 A CN202010746221 A CN 202010746221A CN 111917577 A CN111917577 A CN 111917577A
Authority
CN
China
Prior art keywords
bgp
route
message
neighbor
routing information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010746221.9A
Other languages
Chinese (zh)
Other versions
CN111917577B (en
Inventor
晏平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yunnan Nuoxunke Technology Co ltd
Original Assignee
Yunnan Nuoxunke Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Yunnan Nuoxunke Technology Co ltd filed Critical Yunnan Nuoxunke Technology Co ltd
Priority to CN202010746221.9A priority Critical patent/CN111917577B/en
Publication of CN111917577A publication Critical patent/CN111917577A/en
Application granted granted Critical
Publication of CN111917577B publication Critical patent/CN111917577B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/02Standardisation; Integration
    • H04L41/0213Standardised network management protocols, e.g. simple network management protocol [SNMP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/12Discovery or management of network topologies
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • H04L45/04Interdomain routing, e.g. hierarchical routing

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention relates to a BGP route information acquisition method, a device, computer equipment and a storage medium, wherein the method comprises the steps of constructing a neighbor relation with a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor; acquiring an update information message and a keep-alive message from a BGP route reflector through an IBGP neighbor; acquiring the attribute of the BGP route according to the updating information to obtain BGP route information; and feeding back the BGP routing information to the terminal for displaying at the terminal. The invention passively collects BGP routing information by establishing neighbors with the BGP routing reflector, can collect BGP routing information and change conditions in real time, does not increase any network load, does not generate any influence on network operation, realizes the real-time collection of BGP routing information, and solves the problem that SNMP can not obtain BGP routing in real time.

Description

BGP routing information acquisition method, BGP routing information acquisition device, computer equipment and storage medium
Technical Field
The present invention relates to network management, and more particularly, to a BGP routing information collection method, apparatus, computer device, and storage medium.
Background
The existing network management systems are implemented by training devices in a network in turn based on SNMP, i.e., a simple network management Protocol, and cannot acquire real-time running conditions of any BGP (Border Gateway Protocol) route and historical data of route running.
SNMP is a traditional network management technique that does not have the ability to obtain BGP dynamic routes in real-time, which is of interest to network managers. BGP is a routing Protocol for autonomous systems operating over TCP (Transmission Control Protocol) and is used to exchange routing information between different autonomous systems. When two autonomous systems need to exchange routing information, each autonomous system must designate a node that operates BGP to exchange routing information with other autonomous systems on behalf of the autonomous system. The SNMP-based network management system is a device-level monitoring and management system based on periodic polling. Events occurring in the network between polling intervals may be missed and increasing the density of polling may increase the load on the network. Unfortunately, the SNMP protocol itself is unaware of problems internal to the BGP routing protocol. For example, some user feedback cannot access some networks, but from the view of the network management system, the states of all routers and links are normal, so it is difficult to determine where the problem is and how to troubleshoot the problem. In fact, as part of BGP routes are repeatedly declared and withdrawn, the routes are suppressed from being pulled into a blacklist and are no longer transmitted outward, so that some networks cannot be accessed, but current network management tools do not have the capability of collecting BGP real-time routing states, and fault location is not performed from the beginning.
Therefore, it is necessary to design a new method to realize real-time BGP routing information acquisition and solve the problem that SNMP cannot acquire BGP routes in real time.
Disclosure of Invention
The invention aims to overcome the defects of the prior art and provides a BGP routing information acquisition method, a BGP routing information acquisition device, computer equipment and a storage medium.
In order to achieve the purpose, the invention adopts the following technical scheme: the BGP routing information acquisition method comprises the following steps:
constructing a neighbor relation with a BGP route reflector in a certain autonomous system in a collection network route to obtain an IBGP neighbor;
acquiring an update information message and a keep-alive message from a BGP route reflector through an IBGP neighbor;
acquiring the attribute of the BGP route according to the updating information to obtain BGP route information;
and feeding back the BGP routing information to the terminal for displaying at the terminal.
The further technical scheme is as follows: after constructing and collecting a neighbor relation of a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor, the method further comprises the following steps:
and setting the state of establishing the neighbor as the state of establishing the connection.
The further technical scheme is as follows: the constructing and collecting a neighbor relation of a BGP route reflector in an autonomous system in the network route to obtain the IBGP neighbor comprises the following steps:
establishing TCP connection with a BGP route reflector in a certain autonomous system in a collection network route, and monitoring the corresponding TCP initialization condition;
acquiring an opening message from a BGP route reflector, and driving the BGP route reflector to enter a state that the opening message is sent;
sending an opening message to a BGP route reflector for the BGP route reflector to check and sending a keep-alive message by the BGP route reflector;
and responding the keep-alive message and driving a BGP route reflector to transit to the state that the connection is established.
The further technical scheme is as follows: the opening message comprises the version number of the BGP router, the number of the local autonomous system, the six times of keep-alive message time and the ID number of the BGP router.
The further technical scheme is as follows: the update information includes an unreachable route length, an unreachable route, a path attribute length, a path attribute, and network layer reachability information.
The further technical scheme is as follows: the keep-alive message comprises a message header for confirming whether the connection between the two neighbor parties is normal or not.
The invention also provides a BGP routing information acquisition device, which comprises:
the neighbor construction unit is used for constructing a neighbor relation with one BGP route reflector in a certain autonomous system in the collection network route so as to obtain an IBGP neighbor;
the message acquisition unit is used for acquiring an update message and a keep-alive message from the BGP route reflector through the IBGP neighbors;
an attribute obtaining unit, configured to obtain an attribute of the BGP route according to the update information, so as to obtain BGP route information;
and the feedback unit is used for feeding back the BGP routing information to the terminal so as to display the BGP routing information on the terminal.
The further technical scheme is as follows: further comprising:
and the neighbor establishing state setting unit is used for setting the state of establishing the neighbor as the state of establishing the connection.
The invention also provides computer equipment which comprises a memory and a processor, wherein the memory is stored with a computer program, and the processor realizes the method when executing the computer program.
The invention also provides a storage medium storing a computer program which, when executed by a processor, is operable to carry out the method as described above.
Compared with the prior art, the invention has the beneficial effects that: the invention establishes the neighbor with the BGP route reflector to realize the exchange of the keep-alive message, the update message and the error message with the BGP route reflector, completes the real-time acquisition of the BGP route by acquiring the route information and the attribute in the update message, passively collects the BGP route information, can acquire the BGP route information and the change condition in real time, does not increase any network load, does not generate any influence on the network operation, realizes the real-time acquisition of the BGP route information, and solves the problem that the SNMP can not acquire the BGP route in real time.
The invention is further described below with reference to the accompanying drawings and specific embodiments.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic view of an application scenario of a BGP routing information collection method according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of a BGP routing information collection method according to an embodiment of the present invention;
fig. 3 is a schematic sub-flow diagram of a BGP routing information collection method according to an embodiment of the present invention;
fig. 4 is a schematic block diagram of a BGP routing information acquisition device according to an embodiment of the present invention;
fig. 5 is a schematic block diagram of a neighbor building unit of a BGP routing information acquisition apparatus according to an embodiment of the present invention;
FIG. 6 is a schematic block diagram of a computer device provided by an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It is also to be understood that the terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in the specification of the present invention and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be further understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
Referring to fig. 1 and fig. 2, fig. 1 is a schematic view of an application scenario of a BGP routing information collection method according to an embodiment of the present invention. Fig. 2 is a schematic flowchart of a BGP routing information collection method according to an embodiment of the present invention. The BGP routing information acquisition method is applied to an acquisition server. The collection server performs data interaction with a BGP route reflector in an autonomous system in a collection network route, and the collection server performs data interaction with the terminal.
Fig. 2 is a schematic flowchart of a BGP routing information collection method according to an embodiment of the present invention. As shown in fig. 2, the method includes the following steps S110 to S150.
S110, constructing a neighbor relation with a BGP route reflector in a certain autonomous system in the collection network route to obtain an IBGP neighbor.
In this embodiment, the IBGP neighbor refers to a connection relationship of an internal BGP protocol, and the IBGP neighbor provides more information to an internal router, and routers corresponding to the IBGP neighbor are connected in a full mesh structure.
The IBGP neighbors are established by using a BGP route reflector and an acquisition server in a certain autonomous system in the acquisition network route, the BGP route reflector can completely inform the route to the IBGP neighbors, the IBGP has the synchronization requirement, and BGP attributes or route changes in the whole autonomous system can be informed to the related IBGP neighbors through the BGP route reflector.
In this embodiment, each autonomous system has a BGP route, and the BGP route reflector is connected to a number of BGP routes through a BGP network. The BGP route reflector is connected with the acquisition router to acquire BGP route information in real time.
In an embodiment, referring to fig. 3, the step S110 may include steps S111 to S114.
S111, establishing TCP connection with a BGP route reflector in a certain autonomous system in the collection network route, and monitoring corresponding TCP initialization conditions.
In this embodiment, the BGP route reflector device first establishes a TCP connection with the acquisition server, and the BGP route reflector device listens for TCP initialization from the acquisition server.
S112, acquiring the opening message from the BGP route reflector, and driving the BGP route reflector to enter a state that the opening message is sent.
Specifically, after the TCP connection is established, the BGP route reflector sends an open message to the acquisition server, enters a state in which the open message has been sent, and waits until the acquisition server responds.
In this embodiment, the establishing of the neighbor relation includes six states, the first state is an idle state, and the state does not allow the connection of the BGP route reflector, that is, the connection of the BGP route, and does not allocate network resources; the second is a connection state, which indicates that the acquisition server and the BGP routing transmitter complete three-way handshake connection; the third is an active state, which is a state that the handshake fails or the opening message is sent without response and then enters; and the fourth state is a state that the opening message is sent after three-way handshake, which is equivalent to synchronizing the autonomous system, the version number and the keep-alive time, if the sending is successful, the idle state is entered, in the state, the TCP connection is already established, the BGP route also sends the first opening message, and the rest work is carried out, and the BGP route waits for the peer of the BGP route to send the opening message. And checking the correctness of the received opening message, if an error exists, the system sends an error notification message and returns to an idle state, and if no error exists, the BGP route starts to send the keep-alive message, resets a keep-alive message timer, starts to time and simultaneously shifts to an opening message confirmation state. And the fifth mode is an open message confirmation state, in which the BGP route sends a keep-alive message and resets a keep-alive timer, if a keep-alive message is received, the connection is established, the BGP neighbor relation is established, if the TCP connection is interrupted, the BGP route returns to an idle state, and the open message is confirmed after the open message is sent to the other side. The sixth is that the connection is established, sending keep alive message, if the connection is successfully received and enters the established state, failing to return to the idle state, and after the connection is established, sending keep alive message, updating message and error message, in this state, the BGP neighbor relation is established, at this time, BGP exchanges the updating message with its neighbors, and at the same time, the keeping timer is reset.
S113, sending an opening message to the BGP route reflector for the BGP route reflector to check and sending a keep-alive message by the BGP route reflector;
s114 responds to the keep-alive message and drives the BGP route reflector to transition to the state that the connection is established.
Specifically, after the TCP connection is established, the BGP route reflector sends an open message to the acquisition server and enters an open message sent state, and waits until the acquisition server responds; the acquisition server sends an opening message to the routing equipment; the BGP route reflector checks the opening message, and sends a keep-alive message after the check is successful; the collection server responds to the keep-alive message of the BGP route reflector, the state of the BGP route reflector is transited to the connection established state, and the neighbor establishment is completed;
and S120, setting the state of establishing the neighbor as the state of establishing the connection.
S130, obtaining the update information message and the keep-alive message from the BGP route reflector through the IBGP neighbors.
And when a routing event changes, the IBGP neighbors are notified through the update information message.
In this embodiment, the open message is sent at the beginning of establishing the connection, and it is used to invoke a call with the other side, including the version number of the BGP route, the number of the home-end autonomous system, the time of the keep-alive message of six times, and the ID number of the BGP router.
The update information includes an unreachable route length, an unreachable route, a path attribute length, a path attribute, and network layer reachability information. Specifically, the update information carries reachable routes and unreachable routes, and then carries attributes of all routes, and the message includes all valuable information; real-time information of the route can be obtained from the update information.
The keep-alive message comprises a message header for confirming whether the connection between the two neighbor parties is normal or not, and is a message with low overhead.
The error message is sent only when there is a problem in the connection, for example, when the negotiated parameters at the beginning of establishing the connection by the BGP are not matched, or some illegal messages are received, or for other reasons, the BGP sends the error message, and the BGP connection is interrupted while sending the error message. The contents are error code + error subcode + unmatched parameter information.
And S140, acquiring the attribute of the BGP route according to the updating information to obtain BGP route information.
In this embodiment, the BGP routing information refers to an attribute of the BGP route, and is a reachable route or an unreachable route, a corresponding path attribute length, a path attribute, and network layer reachability information.
And S150, feeding back the BGP routing information to a terminal for displaying at the terminal.
The acquisition server establishes an IBGP neighbor with the BGP reflector, and the neighbor establishing state is a connection established state, namely the acquisition server and the BGP reflector can exchange three messages of keep-alive messages, update messages and error messages. And completing the real-time collection of the BGP route by collecting the route information and the attribute in the update message.
The method comprises the steps that a TCP connection is established between an acquisition server and a BGP route reflector, and a BGP neighbor is established between the acquisition server and the BGP reflector through the interaction of message packets and the interaction of keep-alive message packets; after the BGP neighborhood is established between the collection server and the BGP route reflector, collecting the route information and the path attribute information of the update message; the acquisition server and the BGP route reflector continuously carry out neighbor keep-alive and collect BGP data change in real time; the collection server passively receives BGP routing data, and is different from a traditional polling device data collection mode.
The BGP routing information acquisition method realizes the exchange of the keep-alive message, the update message and the error report message with the BGP routing reflector by establishing the neighbor with the BGP routing reflector, finishes the real-time acquisition of the BGP routing by acquiring the routing information and the attribute in the update message, passively collects the BGP routing information, can acquire the BGP routing information and the change condition in real time, does not increase any network load, does not generate any influence on the network operation, realizes the real-time acquisition of the BGP routing information, and solves the problem that the SNMP cannot acquire the BGP routing in real time.
Fig. 4 is a schematic block diagram of a BGP routing information collection apparatus 300 according to an embodiment of the present invention. As shown in fig. 4, the present invention further provides a BGP routing information collecting device 300 corresponding to the BGP routing information collecting method. The BGP routing information collection apparatus 300 includes a unit configured to execute the BGP routing information collection method described above, and may be configured in a server. Specifically, referring to fig. 4, the BGP routing information collecting device 300 includes a neighbor constructing unit 301, a packet obtaining unit 303, an attribute obtaining unit 304, and a feedback unit 305.
A neighbor construction unit 301, configured to construct a neighbor relationship with a BGP route reflector in an autonomous system in a collection network route, so as to obtain an IBGP neighbor; a message obtaining unit 303, configured to obtain, through an IBGP neighbor, an update message and a keep-alive message from a BGP route reflector; an attribute obtaining unit 304, configured to obtain an attribute of the BGP route according to the update information, so as to obtain BGP route information; a feedback unit 305, configured to feed back the BGP routing information to the terminal for displaying at the terminal.
In an embodiment, the apparatus further includes: a neighbor establishing state setting unit 302, configured to set a state of establishing a neighbor as a state of establishing a connection.
In an embodiment, as shown in fig. 5, the neighbor building unit 301 includes a building subunit 3011, an open message acquiring subunit 3012, a sending subunit 3013, and a response subunit 3014.
An establishing subunit 3011, configured to establish a TCP connection with a BGP route reflector in an autonomous system in a collection network route, and monitor a corresponding TCP initialization condition; an open message acquiring subunit 3012, configured to acquire an open message packet from the BGP route reflector, and drive the BGP route reflector to enter a state where the open message has been sent; a sending subunit 3013, configured to send an open message to the BGP route reflector, so that the BGP route reflector performs verification and sends a keep-alive message; and a reply subunit 3014, configured to reply to the keep-alive message and drive the BGP route reflector to transition to the state where the connection is established.
It should be noted that, as can be clearly understood by those skilled in the art, the specific implementation process of the BGP route information collection device 300 and each unit may refer to the corresponding description in the foregoing method embodiment, and for convenience and conciseness of description, no further description is provided here.
The BGP route information collection apparatus 300 may be implemented as a computer program that runs on a computer device as shown in fig. 6.
Referring to fig. 6, fig. 6 is a schematic block diagram of a computer device according to an embodiment of the present application. The computer device 500 may be a server, wherein the server may be an independent server or a server cluster composed of a plurality of servers.
Referring to fig. 6, the computer device 500 includes a processor 502, memory, and a network interface 505 connected by a system bus 501, where the memory may include a non-volatile storage medium 503 and an internal memory 504.
The non-volatile storage medium 503 may store an operating system 5031 and a computer program 5032. The computer programs 5032 include program instructions that, when executed, cause the processor 502 to perform a BGP routing information collection method.
The processor 502 is used to provide computing and control capabilities to support the operation of the overall computer device 500.
The internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503, and when the computer program 5032 is executed by the processor 502, the processor 502 may be enabled to execute a BGP routing information collection method.
The network interface 505 is used for network communication with other devices. Those skilled in the art will appreciate that the configuration shown in fig. 6 is a block diagram of only a portion of the configuration associated with the present application and does not constitute a limitation of the computer device 500 to which the present application may be applied, and that a particular computer device 500 may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
Wherein the processor 502 is configured to run the computer program 5032 stored in the memory to implement the following steps:
constructing a neighbor relation with a BGP route reflector in a certain autonomous system in a collection network route to obtain an IBGP neighbor; acquiring an update information message and a keep-alive message from a BGP route reflector through an IBGP neighbor; acquiring the attribute of the BGP route according to the updating information to obtain BGP route information; and feeding back the BGP routing information to the terminal for displaying at the terminal.
Wherein the update information includes an unreachable route length, an unreachable route, a path attribute length, a path attribute, and network layer reachability information.
The keep-alive message comprises a message header for confirming whether the connection between the two neighbor parties is normal or not.
In an embodiment, after the step of constructing and collecting a neighbor relation of a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor is implemented by the processor 502, the following steps are further implemented:
and setting the state of establishing the neighbor as the state of establishing the connection.
In an embodiment, when implementing the step of constructing and collecting a neighbor relation of a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor, the processor 502 specifically implements the following steps:
establishing TCP connection with a BGP route reflector in a certain autonomous system in a collection network route, and monitoring the corresponding TCP initialization condition; acquiring an opening message from a BGP route reflector, and driving the BGP route reflector to enter a state that the opening message is sent; sending an opening message to a BGP route reflector for the BGP route reflector to check and sending a keep-alive message by the BGP route reflector; and responding the keep-alive message and driving a BGP route reflector to transit to the state that the connection is established.
The message opening message comprises a version number of the BGP router, a number of the local autonomous system, six times of keep-alive message time and an ID number of the BGP router.
It should be understood that, in the embodiment of the present Application, the Processor 502 may be a Central Processing Unit (CPU), and the Processor 502 may also be other general-purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, and the like. Wherein a general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
It will be understood by those skilled in the art that all or part of the flow of the method implementing the above embodiments may be implemented by a computer program instructing associated hardware. The computer program includes program instructions, and the computer program may be stored in a storage medium, which is a computer-readable storage medium. The program instructions are executed by at least one processor in the computer system to implement the flow steps of the embodiments of the method described above.
Accordingly, the present invention also provides a storage medium. The storage medium may be a computer-readable storage medium. The storage medium stores a computer program, wherein the computer program, when executed by a processor, causes the processor to perform the steps of:
constructing a neighbor relation with a BGP route reflector in a certain autonomous system in a collection network route to obtain an IBGP neighbor; acquiring an update information message and a keep-alive message from a BGP route reflector through an IBGP neighbor; acquiring the attribute of the BGP route according to the updating information to obtain BGP route information; and feeding back the BGP routing information to the terminal for displaying at the terminal.
Wherein the update information includes an unreachable route length, an unreachable route, a path attribute length, a path attribute, and network layer reachability information.
The keep-alive message comprises a message header for confirming whether the connection between the two neighbor parties is normal or not.
In an embodiment, after the step of constructing and collecting a neighbor relation of a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor is implemented by the processor by executing the computer program, the following steps are further implemented:
and setting the state of establishing the neighbor as the state of establishing the connection.
In an embodiment, when the processor executes the computer program to implement the step of constructing and acquiring a neighbor relation of a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor, the following steps are specifically implemented:
establishing TCP connection with a BGP route reflector in a certain autonomous system in a collection network route, and monitoring the corresponding TCP initialization condition; acquiring an opening message from a BGP route reflector, and driving the BGP route reflector to enter a state that the opening message is sent; sending an opening message to a BGP route reflector for the BGP route reflector to check and sending a keep-alive message by the BGP route reflector; and responding the keep-alive message and driving a BGP route reflector to transit to the state that the connection is established.
The message opening message comprises a version number of the BGP router, a number of the local autonomous system, six times of keep-alive message time and an ID number of the BGP router.
The storage medium may be a usb disk, a removable hard disk, a Read-Only Memory (ROM), a magnetic disk, or an optical disk, which can store various computer readable storage media.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps of the examples described in connection with the embodiments disclosed herein may be embodied in electronic hardware, computer software, or combinations of both, and that the components and steps of the examples have been described in a functional general in the foregoing description for the purpose of illustrating clearly the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative. For example, the division of each unit is only one logic function division, and there may be another division manner in actual implementation. For example, various elements or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented.
The steps in the method of the embodiment of the invention can be sequentially adjusted, combined and deleted according to actual needs. The units in the device of the embodiment of the invention can be merged, divided and deleted according to actual needs. In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a storage medium. Based on such understanding, the technical solution of the present invention essentially or partially contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a terminal, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention.
While the invention has been described with reference to specific embodiments, the invention is not limited thereto, and various equivalent modifications and substitutions can be easily made by those skilled in the art within the technical scope of the invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (10)

  1. The BGP routing information acquisition method is characterized by comprising the following steps:
    constructing a neighbor relation with a BGP route reflector in a certain autonomous system in a collection network route to obtain an IBGP neighbor;
    acquiring an update information message and a keep-alive message from a BGP route reflector through an IBGP neighbor;
    acquiring the attribute of the BGP route according to the updating information to obtain BGP route information;
    and feeding back the BGP routing information to the terminal for displaying at the terminal.
  2. 2. The BGP routing information collection method of claim 1, wherein the constructing and collecting a neighbor relation with a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor further comprises:
    and setting the state of establishing the neighbor as the state of establishing the connection.
  3. 3. The BGP routing information collection method of claim 2, wherein the constructing and collecting a neighbor relation of a BGP route reflector in an autonomous system in a network route to obtain an IBGP neighbor comprises:
    establishing TCP connection with a BGP route reflector in a certain autonomous system in a collection network route, and monitoring the corresponding TCP initialization condition;
    acquiring an opening message from a BGP route reflector, and driving the BGP route reflector to enter a state that the opening message is sent;
    sending an opening message to a BGP route reflector for the BGP route reflector to check and sending a keep-alive message by the BGP route reflector;
    and responding the keep-alive message and driving a BGP route reflector to transit to the state that the connection is established.
  4. 4. The BGP routing information collection method of claim 3, wherein the open message packet comprises a version number of the BGP route, a home autonomous system number, a keep-alive message packet time of six times, and an ID number of the BGP router.
  5. 5. The BGP routing information collection method of claim 1, wherein the update information includes an unreachable route length, an unreachable route, a path attribute length, a path attribute, and network layer reachability information.
  6. 6. The BGP routing information collection method of claim 1, wherein the keep-alive message comprises a header for confirming whether the connection between both neighboring parties is normal.
  7. A BGP routing information collection device, comprising:
    the neighbor construction unit is used for constructing a neighbor relation with one BGP route reflector in a certain autonomous system in the collection network route so as to obtain an IBGP neighbor;
    the message acquisition unit is used for acquiring an update message and a keep-alive message from the BGP route reflector through the IBGP neighbors;
    an attribute obtaining unit, configured to obtain an attribute of the BGP route according to the update information, so as to obtain BGP route information;
    and the feedback unit is used for feeding back the BGP routing information to the terminal so as to display the BGP routing information on the terminal.
  8. 8. The BGP routing information collector of claim 7, further comprising:
    and the neighbor establishing state setting unit is used for setting the state of establishing the neighbor as the state of establishing the connection.
  9. 9. A computer device, characterized in that the computer device comprises a memory, on which a computer program is stored, and a processor, which when executing the computer program implements the method according to any of claims 1 to 6.
  10. 10. A storage medium, characterized in that the storage medium stores a computer program which, when executed by a processor, implements the method according to any one of claims 1 to 6.
CN202010746221.9A 2020-07-29 2020-07-29 BGP route information acquisition method, device, computer equipment and storage medium Active CN111917577B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010746221.9A CN111917577B (en) 2020-07-29 2020-07-29 BGP route information acquisition method, device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010746221.9A CN111917577B (en) 2020-07-29 2020-07-29 BGP route information acquisition method, device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN111917577A true CN111917577A (en) 2020-11-10
CN111917577B CN111917577B (en) 2024-03-05

Family

ID=73287981

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010746221.9A Active CN111917577B (en) 2020-07-29 2020-07-29 BGP route information acquisition method, device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111917577B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114124780A (en) * 2021-11-15 2022-03-01 迈普通信技术股份有限公司 Route publishing method, device, electronic equipment and storage medium
CN114143807A (en) * 2021-10-27 2022-03-04 中盈优创资讯科技有限公司 Method and device for evaluating integrity rate of route registration

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101119585A (en) * 2006-08-01 2008-02-06 华为技术有限公司 Distributed non-cooperation multipoint-to-multipoint network, node and connection establishing method
CN101163109A (en) * 2007-11-14 2008-04-16 中国科学院计算技术研究所 Autonomic system network routing topology constructing method
CN101252488A (en) * 2008-04-15 2008-08-27 中国科学院计算技术研究所 Multi self-governing system router level topology processing system and method
CN102368724A (en) * 2011-09-08 2012-03-07 华为技术有限公司 Message forwarding method and apparatus thereof
CN102394794A (en) * 2011-11-04 2012-03-28 中国人民解放军国防科学技术大学 Coordinated monitoring method for preventing BGP routing hijacking
CN102761482A (en) * 2012-06-29 2012-10-31 杭州华三通信技术有限公司 Method for building BGP (border gateway protocol) neighbor and equipment therefore
CN103618677A (en) * 2013-12-11 2014-03-05 王逊 Network flow regulation method and system
US20160261486A1 (en) * 2015-03-02 2016-09-08 Cisco Technology, Inc. Symmetric routing enforcement
CN109150713A (en) * 2018-08-22 2019-01-04 赛尔网络有限公司 Based on the method for routing and route monitoring method between BGP+ source terminal and purpose terminal

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101119585A (en) * 2006-08-01 2008-02-06 华为技术有限公司 Distributed non-cooperation multipoint-to-multipoint network, node and connection establishing method
CN101163109A (en) * 2007-11-14 2008-04-16 中国科学院计算技术研究所 Autonomic system network routing topology constructing method
CN101252488A (en) * 2008-04-15 2008-08-27 中国科学院计算技术研究所 Multi self-governing system router level topology processing system and method
CN102368724A (en) * 2011-09-08 2012-03-07 华为技术有限公司 Message forwarding method and apparatus thereof
CN102394794A (en) * 2011-11-04 2012-03-28 中国人民解放军国防科学技术大学 Coordinated monitoring method for preventing BGP routing hijacking
CN102761482A (en) * 2012-06-29 2012-10-31 杭州华三通信技术有限公司 Method for building BGP (border gateway protocol) neighbor and equipment therefore
CN103618677A (en) * 2013-12-11 2014-03-05 王逊 Network flow regulation method and system
US20160261486A1 (en) * 2015-03-02 2016-09-08 Cisco Technology, Inc. Symmetric routing enforcement
CN109150713A (en) * 2018-08-22 2019-01-04 赛尔网络有限公司 Based on the method for routing and route monitoring method between BGP+ source terminal and purpose terminal

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
CRISTINA MAYR; CLAUDIO RISSO; EDUARDO GRAMPÍN: "A Combinatorial Optimization Framework for the Design of resilient iBGP Overlays", IEEE, 16 May 2019 (2019-05-16) *
徐镜湖;胡宁;朱培栋;: "面向多ISP协同的域间路由策略管理方法", 计算机应用, no. 12, 1 December 2008 (2008-12-01) *
李宪民: "论BGP协议的工作原理", 论BGP协议的工作原理, pages 3 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114143807A (en) * 2021-10-27 2022-03-04 中盈优创资讯科技有限公司 Method and device for evaluating integrity rate of route registration
CN114143807B (en) * 2021-10-27 2023-08-08 中盈优创资讯科技有限公司 Route registration integrity rate evaluation method and device
CN114124780A (en) * 2021-11-15 2022-03-01 迈普通信技术股份有限公司 Route publishing method, device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN111917577B (en) 2024-03-05

Similar Documents

Publication Publication Date Title
KR101046028B1 (en) How to Provide Guaranteed Distributed Failure Notification
US5964837A (en) Computer network management using dynamic switching between event-driven and polling type of monitoring from manager station
US20090147698A1 (en) Network automatic discovery method and system
JPH0936910A (en) Management of routing in packet communication network
EP2553870B1 (en) An operations, administrations and management proxy and a method for handling operations, administrations and management messages
US9350628B2 (en) Dynamic management of maintenance association membership in a computer network
CN111917577B (en) BGP route information acquisition method, device, computer equipment and storage medium
CN104144124B (en) Data forwarding method, Apparatus and system
CN109873719B (en) Fault detection method and device
RYU Project Team RYU SDN Framework-English Edition
CN112953785B (en) Link detection method and system for communication equipment of multi-core processor
US7860024B1 (en) Network monitoring method and system
JP2022529459A (en) Efficient message transmission and loop avoidance in RPL networks
WO2020057475A1 (en) Method for determining routing oscillation information and related device therefor
CN112910704B (en) Local area network system, method and device supporting dynamic self-adaptive network configuration
JP2008306435A (en) Packet repeater
JP5229007B2 (en) Monitoring system, network device, monitoring information providing method and program
CN112468367A (en) Data acquisition and interaction method, system, equipment and medium
CN114143904B (en) CPE management method based on 5G fusion network shunt
CN107248935B (en) System and method for network management to discover and monitor network elements
WO2021046565A2 (en) Pce controlled network reliability
JP2001202305A (en) Reliability improving method for communication in nms system, and nms system
CN115801555B (en) Main-standby switching method and device based on preemption delay and electronic equipment
Nguyen et al. MCMP: A transport/session level distributed protocol for desktop conference setup
CN114531393B (en) Method, device, equipment and medium for issuing segment routing strategy

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant