WO2021018155A1 - 一种路由信息监控方法和装置 - Google Patents
一种路由信息监控方法和装置 Download PDFInfo
- Publication number
- WO2021018155A1 WO2021018155A1 PCT/CN2020/105297 CN2020105297W WO2021018155A1 WO 2021018155 A1 WO2021018155 A1 WO 2021018155A1 CN 2020105297 W CN2020105297 W CN 2020105297W WO 2021018155 A1 WO2021018155 A1 WO 2021018155A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- neighbor
- network device
- neighbors
- peer
- bgp
- Prior art date
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/02—Topology update or discovery
- H04L45/025—Updating only a limited number of routers, e.g. fish-eye update
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/02—Topology update or discovery
- H04L45/04—Interdomain routing, e.g. hierarchical routing
Definitions
- This application relates to the field of communication technology, and in particular to a method and device for monitoring routing information.
- Border Gateway Protocol (English: Border Gateway Protocol, abbreviated as: BGP) has become the Internet border routing protocol standard for exchanging routing information between autonomous areas.
- BGP Border Gateway Protocol
- the amount of routing information exchanged between autonomous regions is increasing, which gradually affects the performance of the network, especially the frequent changes of the routing caused by the network shock, which initiates the operation and maintenance of the network.
- BGP Border Gateway Protocol
- BGP monitoring protocol (English: BGP Monitoring) of the network devices to be monitored by configuring one by one.
- BMP also known as "enable monitoring”
- the network device to be monitored that is configured as BMP enabled sends the routing information of all BGP neighbors of the network device to the monitoring server (English: Monitoring Station) , Realize the monitoring of BGP routing information of network equipment.
- the routing information of all its neighbors will be sent without filtering.
- the routing information sent is likely to include a lot of information that does not need to be Concerned about the routing information of neighbors, the monitoring is not flexible enough and monitoring resources are wasted, which makes it difficult to implement flexible monitoring of the routing information of network devices.
- the embodiments of the present application provide a routing information monitoring method and device, which can set filtering conditions for monitoring target neighbors, so that network equipment can report the routing information of target neighbors that meet the filtering conditions to the controller, so as to realize the More flexible monitoring of routing information of monitoring network equipment.
- the network device to be monitored performs routing information monitoring.
- the specific process may include: the network device obtains neighbor monitoring conditions; the network device determines from all neighbors of the network device that the neighbor monitoring conditions are met As the target neighbor, the network device can send the routing information of the target neighbor to realize the monitoring of the network device to be monitored according to the neighbor monitoring conditions.
- the network device can flexibly select the target neighbor that meets the neighbor monitoring condition according to the neighbor monitoring condition, which solves the problem that the network device will All neighbor routing information is sent to the controller without being filtered, and some of the neighbor routing information does not need to be paid attention to at all. This leads to the problem of wasted routing information monitoring and improves the flexibility of routing information monitoring for network devices.
- the network device sends the routing information of the target neighbor, specifically: the network device sends the routing information of the first target neighbor in the online state among the target neighbors; in this embodiment, it can also be specifically Including: when the second target neighbor in the offline state among the target neighbors goes online, the network device sends the routing information of the second target neighbor.
- the network device obtains neighbor monitoring conditions.
- it may be: the neighbor monitoring conditions received by the network device from the controller; in another case, the neighbor monitoring conditions are also It may be that the configuration information received by the network device includes neighbor monitoring conditions.
- the neighbor monitoring conditions may be: the neighbor monitoring conditions received by the network device from the controller; in another case, the neighbor monitoring conditions are also It may be that the configuration information received by the network device includes neighbor monitoring conditions. In this way, by flexibly obtaining neighbor monitoring conditions, it is possible to effectively filter out the routing information of the target neighbors that need to be paid attention to, and send the filtered routing information of the target neighbors to the controller to realize flexible monitoring of routing information It provides a data basis for improving the flexibility of monitoring the routing information of network equipment.
- the neighbor monitoring condition includes at least one of the following conditions: condition one, the BGP neighbor of the public network among the neighbors of the network device, condition two, the BGP neighbor of the private network among the neighbors of the network device, and condition three, the network device BGP neighbors of the fourth version of the Internet Protocol (English: Internet Protocol version 4, abbreviated as: IPv4) among neighbors, condition four, network equipment neighbors of the sixth version of the Internet Protocol (English: Internet Protocol version 6, abbreviated: IPv6) BGP neighbor, condition five, the BGP neighbor of the internal Border Gateway Protocol (English: internal Border Gateway Protocol, abbreviated as iBGP) in the neighbor of the network device, condition six, the external Border Gateway Protocol (English: external Border Gateway Protocol) in the neighbor of the network device , Abbreviation: eBGP) BGP neighbor, condition 7: The neighbor address of the network device meets the target regular expression BGP neighbor.
- condition one the BGP neighbor of the public network among the neighbors of the network device
- condition two the BGP neighbor of the private network among the neighbors of the
- the neighbor monitoring condition can be specifically implemented through dynamic programming, which improves the flexibility of dynamically monitoring network equipment.
- the embodiment of the present application may further include: the network device establishes a BGP monitoring protocol BMP session with the controller; the network device sends summary information of all neighbors
- the summary information includes at least the Internet Protocol IP address, routing identifier RD, and autonomous system serial number AS Number of each neighbor.
- All neighbors refer to neighbors that have established a BGP neighbor relationship with the network device at the current moment.
- the network device sends the summary information of all neighbors, which may specifically be: the network device sends the summary information of all neighbors through the Peer Summary Report message extended by the BMP.
- the Peer Summary Report message includes: a message header, a set of neighbor headers, a list of Peer Headers, and a timestamp; the message header includes the number of neighbor headers, the Peer Header Number field, and the Sequence Number field of the message; each Peer Header includes The Peer Type field, the Peer Flags field, the RD field, the local autonomous system Local AS field, the neighbor address Peer Address field, the neighbor autonomous system Peer AS field, and the neighbor BGP identifier Peer BGP ID field.
- the controller can obtain the summary information of all neighbors of the network device, which can provide a data basis for subsequent more accurate determination of neighbor monitoring conditions.
- the network device sending the routing information of the target neighbor may specifically be: the network device sends the routing information of the target neighbor through BMP. In this way, flexible monitoring of the routing information of the target neighbor of the network device in the BMP scenario can be realized.
- this embodiment may further include: the network device sends the updated routing information of the target neighbor.
- the network device sends the updated routing information of the target neighbor.
- the network device in addition to obtaining neighbor monitoring conditions, can also obtain the target device list, then the network device can determine whether it is in the target device list. If so, the network device can The acquired neighbor monitoring condition determines the target neighbor that meets the neighbor monitoring condition among the neighbors of the network device. In addition, the network device can also be used as a transit device, and according to the target device list, the neighbor monitoring conditions are respectively forwarded to other target devices in the target device list except itself.
- the network device to be monitored performs routing information monitoring.
- the specific process may include: the controller sends a neighbor monitoring condition to the network device, and the neighbor monitoring condition is used to instruct the network device of the receiving party according to the The neighbor monitoring condition determines the target neighbor of the network device; then, the controller can receive the routing information of the target neighbor sent by the network device.
- the network device can flexibly select the target neighbor that meets the neighbor monitoring condition according to the neighbor monitoring condition, which solves the problem of the network device
- the routing information of all its neighbors is sent to the controller without being filtered, and the routing information of some of its neighbors does not need to be paid attention to at all, which leads to the problem of waste of routing information monitoring and improves the flexibility of monitoring the routing information of network equipment Sex.
- the controller can also send a list of target devices to the network device, so that the network device can act as a transit device, and forward the neighbor monitoring conditions to other target devices in the target device list according to the target device list. Reduce the data interaction between the controller and each network device.
- the controller receiving the routing information of the target neighbor may specifically be: the controller receives the routing information of the first target neighbor in the online state among the target neighbors; in this embodiment, it may be specifically Including: when the second target neighbor in the offline state among the target neighbors goes online, the controller receives the routing information of the second target neighbor.
- neighbor monitoring conditions are specifically implemented through dynamic programming.
- this embodiment may further include: the controller establishes a BGP monitoring protocol BMP session with the network device, and the controller receives all neighbors of the network device
- the summary information includes at least the Internet Protocol IP address, routing identifier RD, and autonomous system serial number AS Number of each neighbor. All neighbors refer to neighbors that have established a BGP neighbor relationship with network equipment at the current moment.
- the controller receives summary information of all neighbors of the network device, specifically: the controller receives the neighbor summary report Peer Summary Report message sent by the network device, and the Peer Summary Report message is a message extended by the BGP monitoring protocol BMP. Carry summary information of all neighbors of the network device.
- the Peer Summary Report message includes: a message header, a set of neighbor headers, a list of Peer Headers, and a timestamp; the message header includes the number of neighbor headers, the Peer Header Number field, and the Sequence Number field of the message; each Peer Header includes The Peer Type field, the Peer Flags field, the RD field, the local autonomous system Local AS field, the neighbor address Peer Address field, the neighbor autonomous system Peer AS field, and the neighbor BGP identifier Peer BGP ID field.
- the neighbor monitoring condition includes at least one of the following conditions: the BGP neighbor of the public network among the neighbors of the network device, the BGP neighbor of the private network among the neighbors of the network device, and the IPv4 neighbor among the neighbors of the network device BGP neighbors, IPv6 BGP neighbors among network device neighbors, iBGP BGP neighbors among network device neighbors, eBGP BGP neighbors among network device neighbors, or BGP neighbors whose neighbor addresses meet the target regular expression.
- this embodiment may further include: the controller determines a neighbor monitoring condition according to the summary information, where the neighbor monitoring condition is used to indicate the target neighbor whose routing information is to be sent, for example: the neighbor summary condition is the target neighbor List of identities.
- the controller receives the routing information of the target neighbor sent by the network device, specifically: the controller receives the routing information of the target neighbor through the BGP monitoring protocol BMP.
- this embodiment may further include: the controller receives updated routing information of the target neighbor of the network device.
- the method provided in the second aspect corresponds to the method provided in the first aspect. Therefore, various possible implementations and technical effects of the method provided in the second aspect can be referred to the aforementioned first aspect. Introduction of methods.
- the network device to be monitored performs routing information monitoring.
- the specific process may include: when the network device establishes a Border Gateway Protocol BGP monitoring protocol BMP session with the controller, the network device can send all neighbors’ Summary information, which includes at least the Internet Protocol (English: Internet Protocol, abbreviation: IP) address, routing identifier (English: Route Distinguisher, abbreviation: RD) and autonomous system serial number (English: Autonomous System Number, abbreviation) of each neighbor : AS Number), all neighbors are neighbors that have established a BGP neighbor relationship with the network device at the current moment.
- IP Internet Protocol
- routing identifier English: Route Distinguisher, abbreviation: RD
- autonomous system serial number English: Autonomous System Number, abbreviation
- the controller can learn the neighbors of the network device and the neighbor summary information, and realize the monitoring of the neighbors of the network device, as a follow-up basis
- the embodiments provided in the first aspect or the second aspect provide a data basis for monitoring routing information of the network device.
- the network device sends summary information of all neighbors, specifically: the network device sends a neighbor summary report Peer Summary Report message, which is a message extended by the BGP monitoring protocol BMP , Carrying summary information of all neighbors of the network device.
- a neighbor summary report Peer Summary Report message which is a message extended by the BGP monitoring protocol BMP , Carrying summary information of all neighbors of the network device.
- the Peer Summary Report message includes: a message header, a list of neighbor headers, and a timestamp; among them, the message header includes the number of neighbor headers, the Peer Header Number field and the Sequence Number field of the message;
- Each Peer Header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- this embodiment may further include: the network device sends summary information of the new neighbor. It is understandable that the summary information of the new neighbor may also be carried in the Peer Summary Report message sent by the network device.
- the embodiment of the present application may further include: the network device sends an initialization message to the controller for sending
- the controller advertises the supplier information and software version number of the network device.
- the software version number is used to identify the Peer Summary Report message. If the controller does not support the software version number, the controller can report the Peer Summary Report. The text is not processed.
- the method provided by the third aspect corresponds to part of the implementation of the method provided by the first aspect. Therefore, the various possible implementations and technical effects of the method provided by the third aspect can be referred to in the preceding paragraph. An introduction in the method provided on the one hand.
- a network device including: an acquiring unit, a determining unit, and a sending unit.
- the obtaining unit is used to obtain neighbor monitoring conditions
- a determining unit configured to determine a target neighbor that meets the neighbor monitoring condition among the neighbors of the network device according to the neighbor monitoring condition
- the sending unit is used to send the routing information of the target neighbor.
- the acquiring unit may be specifically configured to receive neighbor monitoring conditions from the controller.
- the acquiring unit may also be specifically used to: receive configuration information, and generate neighbor monitoring conditions based on the configuration information.
- the neighbor monitoring conditions include at least one of the following conditions: the border gateway protocol BGP neighbor of the public network among the neighbors of the network device, the BGP neighbor of the private network among the neighbors of the network device, and the IPv4 version 4 Internet Protocol among the neighbors of the network device BGP neighbor, the BGP neighbor of version 6 Internet Protocol IPv6 among the neighbors of network equipment, the BGP neighbor of internal Border Gateway Protocol iBGP among the neighbors of network equipment, the BGP neighbor of External Border Gateway Protocol eBGP among the neighbors of network equipment, or the network equipment A BGP neighbor whose neighbor address meets the target regular expression.
- the device further includes: a session establishment unit.
- the session establishment unit is used to establish a BGP monitoring protocol BMP session with the controller; then, the sending unit is also used to send summary information of all neighbors after establishing a BMP session with the controller.
- the summary information includes at least the Internet protocol of each neighbor IP address, route identifier RD, and autonomous system serial number AS Number. All neighbors refer to neighbors that have established a BGP neighbor relationship with network devices at the current moment.
- the sending unit is specifically configured to: after establishing a BMP session with the controller, send summary information of all neighbors through the BMP extended neighbor summary report Peer Summary Report message.
- the Peer Summary Report message includes: a message header, a list of neighbor headers Peer Header, and a timestamp; among them, the message header includes the number of neighbor headers Peer Header Number field and the sequence number field of the message; each Peer The header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- the sending unit is specifically configured to send the routing information of the target neighbor through the BMP.
- the sending unit is further configured to send updated routing information of the target neighbor when the route of the target neighbor is updated.
- the sending unit is specifically configured to: send routing information of the first target neighbor in the online state among the target neighbors; then, the sending unit is also used when the target neighbor is down When the second target neighbor in the online state goes online, the routing information of the second target neighbor is sent.
- the network device provided in the fourth aspect corresponds to the method provided in the first aspect. Therefore, for the various possible implementation modes and technical effects achieved by the network device provided in the fourth aspect, refer to the aforementioned first aspect Introduction in the provided method.
- an embodiment of the present application also provides a controller, including: a sending unit and a receiving unit.
- the sending unit is used to send the neighbor monitoring condition to the network device, and the neighbor monitoring condition is used to instruct the network device to determine the target neighbor meeting the neighbor monitoring condition among the neighbors of the network device according to the neighbor monitoring condition;
- the receiving unit is used to receive the routing information of the target neighbor sent by the network device.
- the neighbor monitoring condition includes at least one of the following conditions: the border gateway protocol BGP neighbor of the public network among the neighbors of the network device, the BGP neighbor of the private network among the neighbors of the network device, and the network device
- the BGP neighbor of the fourth version of the Internet Protocol IPv4 in the neighbor of the network device the BGP neighbor of the sixth version of the Internet Protocol IPv6 in the neighbor of the network device, the BGP neighbor of the internal border gateway protocol iBGP in the neighbor of the network device, and the external border gateway in the neighbor of the network device Protocol eBGP BGP neighbors, or BGP neighbors whose neighbor addresses of network devices meet the target regular expression.
- the device further includes: a session establishment unit.
- the session establishment unit is used to establish a BGP monitoring protocol BMP session with the network device; at this time, the receiving unit is also used to receive summary information of all neighbors of the network device when establishing a BMP session with the network device.
- the summary information includes the information of each neighbor Internet Protocol IP address, routing identifier RD, and autonomous system serial number AS Number, all neighbors refer to neighbors that have established a BGP neighbor relationship with network devices at the current moment.
- the receiving unit is specifically configured to: when establishing a BMP session with the network device, receive the neighbor summary report Peer Summary Report message sent by the network device.
- the Peer Summary Report message is a message extended by BMP and carries the network device Summary information of all neighbors.
- the Peer Summary Report message includes: a message header, a list of neighbor headers Peer Header, and a timestamp; among them, the message header includes the number of neighbor headers Peer Header Number field and the sequence number field of the message; each Peer The header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- the controller further includes: a determining unit.
- the determining unit is used to determine the neighbor monitoring condition according to the summary information; the neighbor monitoring condition is used to indicate the target neighbor to which the routing information is to be sent.
- neighbor monitoring conditions are specifically implemented through dynamic programming.
- the receiving unit is specifically configured to receive routing information of the target neighbor through BMP.
- the receiving unit is further configured to receive updated routing information of the target neighbor of the network device.
- the receiving unit is specifically configured to: receive routing information of the first target neighbor in the online state among the target neighbors; then, the receiving unit is also used when the target neighbor is in the online state.
- the second target neighbor in the offline state goes online and receives routing information of the second target neighbor.
- controller provided in the fifth aspect corresponds to the method provided in the second aspect. Therefore, the various possible implementation modes and technical effects of the controller provided in the fifth aspect can be referred to the aforementioned second aspect Introduction in the provided method.
- an embodiment of the present application also provides a network device, including: a session establishment unit and a sending unit.
- the session establishment unit is used to establish a border gateway protocol BGP monitoring protocol BMP session with the controller;
- the sending unit is used to send summary information of all neighbors.
- the summary information includes the Internet Protocol IP address, routing identifier RD, and autonomous system serial number AS Number of each neighbor; among them, all neighbors are those that have established a BGP neighbor relationship with the network device at the current moment neighbor.
- the sending unit is further configured to: when the network device has a new neighbor that establishes a BGP neighbor relationship, send the summary information of the new neighbor.
- the sending unit is specifically used to send a neighbor summary report Peer Summary Report message, which is a message extended by BMP and carries a summary of all neighbors of the network device information.
- the Peer Summary Report message includes: a message header, a list of neighbor headers Peer Header, and a timestamp; among them, the message header includes the number of neighbor headers Peer Header Number field and the sequence number field of the message; each Peer The header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- the network equipment provided in the sixth aspect corresponds to the method provided in the third aspect. Therefore, various possible implementation modes and technical effects of the network equipment provided in the sixth aspect can be referred to the aforementioned third aspect Introduction in the provided method.
- an embodiment of the present application also provides a network device, including a processor, a memory, and a transceiver.
- the memory stores at least one instruction.
- the processor is used to load the instruction and control the transceiver to execute The sending and receiving operations in the routing information monitoring method in any one of the foregoing first aspect or the third aspect, and the processor is further configured to load the instruction and execute the foregoing first or third aspect
- the operations other than the sending and receiving operations in the routing information monitoring method in any one of the implementation manners in the aspect for example: establishing a session, or for example: determining operation.
- an embodiment of the present application further provides a controller, including a processor, a memory, and a transceiver.
- the memory stores at least one instruction
- the processor is used to load the instruction and control the transceiver to execute The sending operation in the routing information monitoring method in any implementation manner of the above second aspect
- the processor is further configured to load the instruction and execute the routing in any implementation manner of the above second aspect
- an embodiment of the present application also provides a routing information monitoring system, which includes: a network device and a controller, wherein the network device is used to implement any one of the foregoing first aspect or third aspect The routing information monitoring method under the following; the controller is used to execute the routing information monitoring method in any one of the foregoing second aspects.
- the embodiments of the present application also provide a computer program product, which when running on a computer, causes the computer to execute the routing information monitoring method in any one of the foregoing first to third aspects .
- an embodiment of the present application also provides a computer-readable storage medium that stores instructions in the computer-readable storage medium, which when run on a computer, causes the computer to execute the first to third aspects above The routing information monitoring method in any one of the implementation manners.
- Fig. 1 is a signaling flowchart of a method for monitoring routing information in an embodiment of the application
- FIG. 2 is a schematic diagram of the framework of a network system involved in an application scenario in an embodiment of this application;
- FIG. 3 is a signaling flowchart of an example of a method for monitoring routing information in an embodiment of the application
- FIG. 4 is a schematic flowchart of a method for monitoring routing information in an embodiment of this application.
- FIG. 5 is a signaling flowchart of an example of a method for monitoring routing information in an embodiment of the application
- Fig. 6 is a schematic diagram of a general header of a Peer Summary Report message in an embodiment of the application.
- FIG. 7 is a schematic diagram of a Peer Summary Report message in an embodiment of the application.
- FIG. 8 is a schematic diagram of the Peer Header of the Peer Summary Report message in an embodiment of the application.
- FIG. 9 is a schematic flowchart of another method for monitoring routing information in an embodiment of the application.
- FIG. 10 is a schematic structural diagram of a network device in an embodiment of this application.
- FIG. 11 is a schematic structural diagram of a controller in an embodiment of the application.
- FIG. 12 is a schematic structural diagram of another network device in an embodiment of this application.
- FIG. 13 is a schematic structural diagram of a network device in an embodiment of this application.
- FIG. 14 is a schematic structural diagram of a controller in an embodiment of the application.
- Figure 15 is a schematic structural diagram of a routing information monitoring system in an embodiment of the application.
- Border Gateway Protocol (English: Border Gateway Protocol, abbreviated as: BGP), as the Internet border routing protocol standard, is used to exchange routing information between autonomous areas. With the expansion of the network scale and the increase in the number of routing tables, the amount of routing information exchanged between autonomous areas is increasing. Once network shocks cause frequent routing changes and other abnormal situations, a great deal will be initiated to the operation and maintenance of the network. challenge. Therefore, it is necessary to monitor the routing information on each network device in the network, so that the network can be analyzed through the monitored routing information so as to quickly find out the problem that causes the routing and forwarding abnormality.
- BGP Border Gateway Protocol
- the network devices to be monitored one by one that is, to perform BGP on the network devices to be monitored one by one.
- the monitoring protocol English: BGP Monitoring Protocol, BMP for short
- the network device to be monitored that is configured as BMP enabled is in the monitored state, and you can communicate with the monitoring server (English: Monitoring Station ) Send routing information of all neighbors of the network device to realize the monitoring of the routing information of the network device by the monitoring server.
- Fig. 1 shows an exemplary signaling flow chart for executing the foregoing routing information monitoring method between a network device and a monitoring server.
- the BMP protocol defines a method for effectively monitoring the BGP routing of network devices, and the monitoring server monitors and manages the BGP operation status of the network devices to be monitored in the network.
- the process of monitoring the routing information of the network device 20 by the monitoring server 10 may include: S11, the network device 20 establishes a BMP session with the monitoring server 10; S12, the network administrator manually enables monitoring on the network device 20; S13, the network The device 20 sends an initialization (English: Initiation) message to the monitoring server 10 to notify the monitoring server 10 of the vendor information, software version number, etc.
- the network device 20 sends a neighbor online notification (English) to the monitoring server 10 : Peer Up Notification message, used to send to the monitoring server 10 BGP neighbors that establish a neighbor relationship with the network device 20; S15, the network device 20 sends a route monitoring (English: Route Monitoring) message to the monitoring server 10 The server 10 sends all routing information received from the BGP neighbors; S16, the network device 20 sends completion indication information to the monitoring server 10 to inform the monitoring server 10 that the routing information of all BGP neighbors on the network device 20 has been sent; S17, when the BGP neighbors of the network device 20 undergo changes such as route addition or withdrawal, the network device 20 sends the latest routing information to the monitoring server 10; S18, the network device 20 sends statistical reports (English: Stats Reports) to the monitoring server 10 The message is used to send statistical information about the operating status of the network device 20 to the monitoring server 10; S19, the network device 20 sends a neighbor down/up notification (English: Peer Down/Up Notification) message to the
- the way of monitoring routing information shown in Figure 1 exemplarily is not convenient because the network administrator needs to configure and enable the network devices to be monitored one by one; moreover, the network device in the enabled monitoring state will all its neighbors All routing information is sent without filtering, and the routing information of some neighbors of the network device probably does not need to be paid attention at all. This leads to the problem of wasting network resources and not flexible enough to monitor the routing information.
- the network device can filter the neighbors that the network device needs to send routing information, flexibly select the target neighbor that meets the neighbor monitoring conditions, and send the The routing information of the target neighbor of the network device realizes flexible monitoring of the routing information of the network device.
- This scenario includes a network device 101, a network device 102, a network device 103, a software-defined network (English: Software Defined Network, SDN for short) controller 200, and a network administrator 300.
- the network device 102 may be a network device to be monitored, and the network device 101 and the network device 103 are BGP neighbors of the network device 102;
- the SDN controller 200 may include a policy analysis unit 201, a management unit 202, and a BMP monitoring unit 203.
- the analysis unit 201 is connected to the management unit 202 and the BMP monitoring unit 203 respectively.
- the routing information monitoring method provided by the embodiment of the present application can be specifically seen in FIG. 3, including the following S21 to S26: S21, the network administrator 300 can deploy BMP monitoring on the SDN controller 200 and set neighbor monitoring conditions ( For example: monitoring the public network BGP neighbor among the neighbors of the network device), the SDN controller 200 may store the neighbor monitoring condition on the policy analysis unit 201 therein.
- S23 Send the summary information of all BGP neighbors to the BMP monitoring unit 203 of the SDN controller 200.
- S24 Send the summary information of all BGP neighbors to the BMP monitoring unit 203 of the SDN controller 200.
- the policy analysis unit 201 reads the summary information of all BGP neighbors of the network device 102 received by the BMP monitoring unit 203, and determines the target neighbor list of the network device 102 according to the summary information and the neighbor monitoring conditions set by the network administrator 300 .
- S25 The policy analysis unit 201 sends the target neighbor list to the network device 102 through the management unit 202.
- the above S24 ⁇ S26 can be executed periodically to verify whether the route of the target neighbor on the network device 102 monitored by the SDN controller 200 has changed, and control the SDN The router 200 monitors and obtains the routing information of the target neighbor of the network device 102 for updating.
- the network administrator 300 can also reset the neighbor monitoring conditions on the SDN controller 200 according to changes in requirements, and re-execute the above S22-S26 according to the new neighbor monitoring conditions to monitor the routing information of the network device 102, so that the network The administrator 300 or other relevant technical personnel can see the new monitoring result through the display device connected to the SDN controller 200 after executing S26.
- One channel may be a BMP protocol channel for the network device 102 to send summary information of all BGP neighbors to the SDN control 200 and The routing information of the target BGP neighbor; the other channel can be a BMP monitoring channel, which is used by the SDN controller 200 to send information such as neighbor monitoring conditions to the network device 102.
- This channel can specifically be a network configuration protocol (English: Network Configuration Protocol, abbreviated as: NETCONF) ) Or command-line interface (English: Command-Line Interface, abbreviation: CLI), etc. It can also be implemented by extending the BMP protocol; its channel interface can adopt another generation (English: Yet Another Next Generation, abbreviation: YANG) data model Interface or NETCONF interface implementation.
- the above-mentioned network devices 101-103 may specifically be any devices with routing functions, such as routers, switches, gateways, etc., which are not specifically limited in the embodiment of the present application; the above-mentioned SDN controller 200 may also be other control devices. As long as the function of the SDN controller 200 in the embodiment of the present application can be realized, it is not specifically limited in the embodiment of the present application.
- FIG. 4 is a schematic flowchart of a routing information monitoring method in an embodiment of the application.
- the method may include the following steps 401 to 405, for example:
- Step 401 The controller sends neighbor monitoring conditions to the network device.
- Step 402 The network device obtains the neighbor monitoring condition.
- the neighbor monitoring condition is used to instruct the network device to select the target neighbor to send routing information from all of its neighbors, that is, the target neighbor needs to meet the neighbor monitoring condition.
- the neighbor monitoring condition may be a neighbor monitoring condition in the form of a filtering condition, and in another case, the neighbor monitoring condition may also be a neighbor monitoring condition in the form of a neighbor list.
- the neighbor monitoring conditions in the form of filtering conditions may refer to the conditions configured by the network administrator on the controller or network equipment according to requirements.
- the neighbor monitoring conditions in the form of filtering conditions may specifically include at least one of the following conditions: Condition 1.
- the neighbors of the network equipment are in the public network Border Gateway Protocol (English: Border Gateway Protocol, abbreviated as: BGP) neighbors, condition two, the neighbors of the network equipment are the BGP neighbors of the private network, and condition three, the network equipment’s neighbors are in the fourth version of the Internet Protocol ( English: Internet Protocol version 4 (abbreviation: IPv4) BGP neighbor, condition four, network equipment neighbors in the sixth version of the Internet Protocol (English: Internet Protocol version 6, abbreviation: IPv6) BGP neighbor, condition five, network equipment
- the BGP neighbor of the internal Border Gateway Protocol English: internal Border Gateway Protocol, abbreviated as: iBGP
- iBGP internal Border Gateway Protocol
- eBGP the BGP neighbor of the external Border Gateway Protocol
- the neighbor monitoring condition received by the network device is condition 1
- the neighbor monitoring condition is used to instruct the network device to select the BGP neighbor of the public network as the target neighbor to be monitored by the network device among all neighbors.
- the neighbor monitoring conditions received by the network device include condition 2, condition 3, and condition 5.
- the neighbor monitoring condition is used to instruct the network device to select BGP neighbors belonging to private networks, IPv4, and iBGP among all neighbors As the target neighbor to be monitored by the network device; another example: the neighbor monitoring conditions received by the network device include condition two, condition four, and conditions six and seven, then the neighbor monitoring condition is used to indicate that the network device is in all neighbors , Select the BGP neighbors that belong to the private network, IPv6, eBGP and meet the target regular expression as the target neighbors to be monitored by the network device.
- the neighbor monitoring conditions can be specifically implemented through dynamic programming. For example: It is necessary to monitor network devices except for the public network neighbors whose prefix IP addresses are 1.1.1.1 and 2.2.2.2. It is no longer necessary to query the public network neighbors in all neighbors on the network device, and then enable one by one the prefix IP address is not 1.1. Each of the public network neighbors of .1.1 and 2.2.2.2, especially when there are many public network neighbors of the network device, the workload of the configuration before monitoring the routing information is huge; and in the embodiment of this application, the technical personnel such as the network administrator only need to pass the dynamic Programmatically set the neighbor monitoring conditions in the form of filtering conditions.
- the neighbor monitoring condition sent by the controller to the network device may refer to: the neighbor monitoring condition in the form of a neighbor list determined by the controller according to the neighbor monitoring condition in the form of the filtering condition and the summary information of the neighbor; as another example, In step 401, the neighbor monitoring condition sent by the controller to the network device may also refer to: the neighbor monitoring condition in the form of filter condition.
- step 401 after the network device receives the neighbor monitoring condition in the filter condition, the network device
- the neighbor monitoring conditions in the filter condition form can be analyzed to determine the target neighbor; or, the network device can also determine the target neighbor based on the neighbor monitoring conditions in the filter condition form and the summary information of all neighbors known by itself.
- the network device obtains the neighbor monitoring conditions, specifically: the network device receives the network administrator or other technology Configuration information set by the personnel on the network device, and the configuration information includes the neighbor monitoring conditions.
- the neighbor monitoring condition in the form of a neighbor list may be used to indicate a target neighbor among all neighbors of the network device.
- the neighbor monitoring condition in the form of a neighbor list may be a target neighbor list.
- the controller can use the neighbor monitoring conditions in the form of filter conditions configured by the network administrator on the controller, and the summary information of neighbors received according to the corresponding embodiment in FIG.
- the neighbor monitoring condition in the form of a neighbor list ; at this time, the controller may use the neighbor monitoring condition in the form of a neighbor list as the "neighbor monitoring condition" in step 401 and step 402 and send it to the network device.
- the network administrator or other technical personnel can directly set the target neighbor list on the network device as a neighbor monitoring condition in the form of a neighbor list. Then, without performing step 401, the network device can directly obtain the form of the neighbor list
- the neighbor monitoring condition of is used as the "neighbor monitoring condition" in step 402, thereby directly determining the target neighbor.
- the controller can send the neighbor monitoring condition to the target device separately.
- the controller sends the neighbor monitoring condition 1 to network device A, network device B, and network device C, so that each target device can follow the neighbor
- the monitoring conditions realize the monitoring of the routing information provided in the embodiments of the present application.
- the controller can also send the identification of the target device while sending the neighbor monitoring conditions to all the network devices to be monitored.
- the controller sends the neighbor monitoring condition 1 and network device A, network device B, network
- the identification of device C is sent to multiple network devices to be monitored, such as network device A, network device B, network device C, etc., so that all the devices to be monitored determine whether they match the received target device's identification If it matches, it can be determined that it is a target device.
- the matched target device is used as a network device to perform the following steps 403 to 405 in this embodiment of the application to complete the monitoring of routing information, that is, network device A, Network device B and network device C respectively follow steps 403 to 405 to complete the monitoring of routing information; if they do not match, the following steps 403 to 405 in the embodiment of this application are not executed to complete the monitoring of routing information, that is, except for the network Device A, network device B, and other devices other than network device C that receive the information do not perform the following steps 403 to 405 to complete the monitoring of routing information.
- the identifier of the target device is used to indicate the object whose routing information needs to be monitored according to the neighbor monitoring condition.
- the controller may also send the neighbor monitoring condition and the identifier of the target device to a network device in the network connected to the controller, and the network device may use the neighbor monitoring condition based on the identifier of the target device.
- the identifier sent to the target device corresponds to each target device, such as: the controller sends neighbor monitoring condition 1 and the identifiers of network device A, network device B, and network device C to network device D.
- network device D can Determine whether it is one of the network devices A to C.
- the network device D performs the following steps 403 to 405 in the embodiment of this application to complete the monitoring of routing information, and the neighbor monitoring condition 1 and The identities of the other two network devices are sent to the other two network devices respectively; if not, the network device D sends neighbor monitoring condition 1 to the network according to the identities of network device A, network device B, and network device C.
- each target device serves as the network device in the embodiment of the present application, and performs the following steps 403 to 405 in the embodiment of the present application to complete the monitoring of routing information.
- the neighbor monitoring conditions sent by the controller to the network device can be carried in the monitoring instruction in one case. Then, when the network device receives the monitoring instruction, on the one hand, the network device can know the requirements of the controller Monitor the routing information of the network device; on the other hand, the network device can parse the monitoring instruction to obtain neighbor monitoring conditions, thereby determining the rules for routing information monitoring, that is, the conditions that the target neighbor needs to meet.
- the neighbor monitoring condition can also be sent to the network device first. The neighbor monitoring condition only informs the network device of the rules that the network device needs to follow to monitor routing information, and does not trigger the monitoring event; when the network device is required to send routing information, The controller then sends the monitoring start instruction associated with the neighbor monitoring condition to the network device.
- the embodiments of the present application may further include: after the network device establishes a BGP monitoring protocol BMP session with the controller, but before the controller has enabled monitoring of the network device, the network device sends summary information of all neighbors
- the summary information includes at least the Internet Protocol IP address of each neighbor, the routing identifier RD, and the autonomous system serial number AS Number.
- the all neighbors refer to neighbors that have established a BGP neighbor relationship with the network device at the current moment.
- the network device sends summary information of all neighbors, as shown in Figure 5.
- the specific process may include:
- Step 501 The network device establishes a BGP monitoring protocol BMP session with the controller;
- Step 502 The network device sends an initialization message to the controller, which is used to notify the controller of the vendor information, software version number, etc. of the network device;
- Step 503 The network device may send summary information of all neighbors of the network device through the Peer Summary Report extended by the BGP monitoring protocol BMP.
- step 503 the network device can be monitored according to the routing information monitoring method provided in the embodiment of the present application, which will not be repeated here.
- a BMP session can be established between the network device and the controller. Once the session is successfully established, the network device can send a BMP message to the controller.
- the initialization message which is used to notify the network equipment's vendor information and software version and other information.
- a new software version number is defined. If the controller receives the Peer Summary Report message and determines that it does not support the newly defined software version number, the controller can ignore the Peer Summary Report message and directly monitor the routing information through steps 401 to 405 .
- the newly added Peer Summary Report message after the BMP is extended in the embodiment of the present application may include: a message header, a set of neighbor header Peer Header lists, and a timestamp Timestamp.
- the message in the BGP format also includes a general message header.
- the Peer Summary Report message can be schematically shown in FIG. 7, where the message header includes: a 2-byte neighbor header number Peer Header Number field and a 2-byte message sequence number Sequence Number field.
- Peer Header Number represents the number of neighbor header Peer Headers carried in the message N;
- Sequence Number represents the sequence number of the message.
- the value in each Peer Summary Report message Sequence Number increases from 0.
- each Peer Header of the Peer Summary Report message may include: neighbor type Peer Type field, neighbor identifier Peer Flags field, RD field, local autonomous system Local AS field, neighbor address Peer Address field, neighbor autonomous system Peer The AS field and the Peer BGP ID field.
- the RD field can occupy 8 bytes
- the Peer Address field can occupy 16 bytes.
- the timestamp Timestamp of the Peer Summary Report message includes: a field corresponding to seconds and a field corresponding to microseconds.
- the network device may also send the summary information of the new neighbor to the controller. For example: as long as a network device has a new neighbor to establish a BGP neighbor relationship with it, the network device can send the summary information of the new neighbor to the controller; another example: the reporting period can also be preset, and the network device can periodically Report the summary information of new neighbors that have established a BGP neighbor relationship with the network device in the period. It is understandable that the network device may also carry the summary information of the new neighbor in a Peer Summary Report message and send it to the controller.
- the controller can learn the neighbors of the network device and neighbor information, and realize the monitoring of the neighbors of the network device. It provides a data basis for the subsequent implementation of the method corresponding to Figure 4 to monitor the routing information of the network device.
- the neighbor monitoring condition can be either a neighbor monitoring condition in the form of a filtering condition, or a neighbor monitoring condition in the form of a neighbor list.
- the neighbor monitoring conditions in step 401 and step 402 may be the neighbor monitoring conditions may be filtering Conditional neighbor monitoring conditions; where, if step 401 is not performed, that is, the neighbor monitoring conditions acquired by the network device are the neighbor monitoring conditions included in the configuration information it receives, then the neighbor monitoring conditions in step 402 can be It is a neighbor monitoring condition in the form of a filtering condition or a neighbor monitoring condition in the form of a neighbor list.
- the network device obtains neighbor monitoring conditions, which provides a data basis for implementing flexible and efficient routing information monitoring.
- Step 403 The network device determines a target neighbor that meets the neighbor monitoring condition among the neighbors of the network device according to the neighbor monitoring condition.
- the network device when the neighbor monitoring condition received by the network device is a neighbor monitoring condition in the form of a neighbor list, the network device can directly determine the target neighbor.
- the network device when the neighbor monitoring condition received by the network device is a neighbor monitoring condition in the form of a filter condition, the network device can analyze the neighbor monitoring condition in the form of a filter condition to determine the target neighbor, for example: The network device may determine a target neighbor meeting the neighbor monitoring condition of the filter condition form from all neighbors based on the neighbor monitoring condition of the filter condition form and the summary information of all neighbors known by itself.
- Step 404 The network device sends routing information of the target neighbor.
- the network device can send the routing information of the target neighbor through BMP.
- Step 405 The controller receives the routing information of the target neighbor sent by the network device.
- the network device can send the routing information of all target neighbors to the controller.
- the network device can first send the routing information of the target neighbors in the online state to the controller. Once other target neighbors in the offline state are online, the network device Then the routing information of the newly online target neighbor can be sent to the controller.
- the embodiment of the present application may further include: the network device sends the updated routing information of the target neighbor to the controller, so that the controller receives the updated target neighbor of the network device Routing information.
- the network device can send neighbor change information to the controller in real time to inform the controller of the change of the neighbor of the network device; Moreover, when the changed neighbor is the target neighbor of the network device, the network device can also autonomously send the changed summary information of the target neighbor and the updated routing information of the target neighbor to the controller. In this way, the network device can be The real-time monitoring of the status of the target neighbors of the equipment avoids the problem of poor timeliness of routing information monitoring that affects network operation and maintenance, and improves the reliability of the network.
- the network device can flexibly choose to meet the neighbor monitoring conditions according to the neighbor monitoring conditions.
- the conditional target neighbor solves the problem that the network device sends all the routing information of all its neighbors to the controller without filtering, and the routing information of some of its neighbors does not need to be paid attention to at all, which leads to the waste of routing information monitoring and improves The flexibility to monitor the routing information of network equipment.
- the embodiment of this application also provides a route monitoring method. Before the monitoring is enabled on the network device, the network device autonomously sends the summary information of all neighbors that have established BGP neighbor relationships with the network device at the current moment.
- the summary information includes at least: the Internet Protocol IP address of each neighbor, the routing identifier RD, and the autonomous system serial number AS Number. Referring to FIG. 9, this embodiment may specifically include:
- Step 901 The network device and the controller establish a BMP session of the Border Gateway Protocol BGP monitoring protocol.
- Step 902 The network device sends summary information of all neighbors.
- the summary information includes the Internet Protocol IP address, routing identifier RD, and autonomous system serial number AS Number of each neighbor; all neighbors have established BGP neighbors with the network device at the current moment. Relationship neighbors.
- this embodiment may also perform: the network device sends an initialization message to notify the controller of the vendor information and software version number of the network device.
- the network device may send the summary information of all neighbors through the Peer Summary Report extended by the BGP monitoring protocol BMP.
- the Peer Summary Report message includes: a message header, a set of neighbor header Peer Header lists, and a timestamp.
- the packet header includes the number of neighbor headers Peer Header Number field and the sequence number of the message Sequence Number field; each Peer Header includes the neighbor type Peer Type field, neighbor identifier Peer Flags field, RD field, local autonomous system Local AS field, neighbor address Peer Address field, neighbor autonomous system Peer AS field, and neighbor BGP identifier Peer BGP ID field.
- the summary information of all neighbors on the network device can be sent, and the routing information of all the neighbors of the network device can be changed.
- the network device when it is added or deleted When it is a neighbor, it triggers the execution of the above step 901 again, which provides an accurate data basis for the subsequent network monitoring shown in FIG. 4, improves the accuracy of routing information monitoring, and thereby improves network reliability.
- the sending period can be preset to periodically send the summary information of all neighbors that have established BGP neighbor relationships with the network device so as to monitor the network device more accurately and timely, thereby improving the controller sending neighbor monitoring conditions, etc. The accuracy of control and management decisions.
- the network device can send summary information of all neighbors.
- the controller can establish a session with the network device in the early stage , You can learn the neighbors and neighbor information of the network device, realize the monitoring of the neighbors of the network device, and provide a data basis for subsequent monitoring of other possible indicators.
- the controller can learn the neighbors and neighbor information of the network device without enabling the network device, and realize the monitoring of the neighbors of the network device.
- the embodiment provided by the aspect or the second aspect provides a data basis for monitoring routing information of the network device.
- FIG. 10 is a schematic structural diagram of a network device provided by an embodiment of this application.
- the network device 1000 includes: an acquiring unit 1001, a determining unit 1002, and a sending unit 1003.
- the obtaining unit 1001 is used to obtain neighbor monitoring conditions
- the determining unit 1002 is configured to determine a target neighbor that meets the neighbor monitoring condition among the neighbors of the network device according to the neighbor monitoring condition;
- the sending unit 903 is configured to send routing information of the target neighbor.
- the obtaining unit 1001 may be specifically used to receive neighbor monitoring conditions from the controller.
- the obtaining unit 1001 may also be specifically used to: receive configuration information, and generate neighbor monitoring conditions based on the configuration information.
- the neighbor monitoring conditions include at least one of the following conditions: the border gateway protocol BGP neighbor of the public network among the neighbors of the network device, the BGP neighbor of the private network among the neighbors of the network device, and the IPv4 version 4 Internet Protocol among the neighbors of the network device BGP neighbor, the BGP neighbor of version 6 Internet Protocol IPv6 among the neighbors of network equipment, the BGP neighbor of internal Border Gateway Protocol iBGP among the neighbors of network equipment, the BGP neighbor of External Border Gateway Protocol eBGP among the neighbors of network equipment, or the network equipment A BGP neighbor whose neighbor address meets the target regular expression.
- the network device 1000 further includes: a session establishment unit.
- the session establishment unit is used to establish a BGP monitoring protocol BMP session with the controller; then, the sending unit 1003 is also used to send summary information of all neighbors after establishing a BMP session with the controller, and the summary information includes at least the Internet of each neighbor Protocol IP address, routing identifier RD, and autonomous system serial number AS Number, all neighbors refer to neighbors that have established BGP neighbor relationships with network devices at the current moment.
- the sending unit 1003 is specifically configured to: after establishing a BMP session with the controller, send summary information of all neighbors through a BMP extended neighbor summary report Peer Summary Report message.
- the Peer Summary Report message includes: a message header, a list of neighbor headers Peer Header, and a timestamp; among them, the message header includes the number of neighbor headers Peer Header Number field and the sequence number field of the message; each Peer The header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- the sending unit 1003 is specifically configured to send the routing information of the target neighbor through the BMP.
- the sending unit 1003 is further configured to send updated routing information of the target neighbor when the route of the target neighbor is updated.
- the sending unit 1003 is specifically configured to: send the routing information of the first target neighbor in the online state among the target neighbors; then, the sending unit 1003 is also configured to: When the second target neighbor of is online, the routing information of the second target neighbor is sent.
- FIG. 11 is a schematic structural diagram of a controller provided by an embodiment of the application.
- the controller 1100 includes a sending unit 1101 and a receiving unit 1102.
- the sending unit 1101 is configured to send the neighbor monitoring condition to the network device, and the neighbor monitoring condition is used to instruct the network device to determine the target neighbor meeting the neighbor monitoring condition among the neighbors of the network device according to the neighbor monitoring condition;
- the receiving unit 1102 is configured to receive routing information of the target neighbor sent by the network device.
- the neighbor monitoring condition includes at least one of the following conditions: the border gateway protocol BGP neighbor of the public network among the neighbors of the network device, the BGP neighbor of the private network among the neighbors of the network device, and the BGP neighbor of the private network among the neighbors of the network device.
- BGP neighbors of the fourth version of Internet Protocol IPv4 network equipment’s neighbors of the sixth version of Internet Protocol IPv6 BGP neighbors, network equipment’s neighbors of internal Border Gateway Protocol iBGP BGP neighbors, network equipment’s neighbors of external Border Gateway Protocol eBGP BGP neighbors, or BGP neighbors whose neighbor addresses of network devices meet the target regular expression.
- the controller 1100 further includes: a session establishment unit.
- the session establishment unit is used to establish a BGP monitoring protocol BMP session with the network device; at this time, the receiving unit 1102 is also used to receive summary information of all neighbors of the network device when establishing a BMP session with the network device.
- the summary information includes each neighbor The Internet Protocol IP address, route identifier RD, and autonomous system serial number AS Number. All neighbors refer to neighbors that have established BGP neighbor relationships with network devices at the current moment.
- the receiving unit is specifically configured to: when establishing a BMP session with the network device, receive the neighbor summary report Peer Summary Report message sent by the network device.
- the Peer Summary Report message is a message extended by BMP and carries the network device Summary information of all neighbors.
- the Peer Summary Report message includes: a message header, a list of neighbor headers Peer Header, and a timestamp; among them, the message header includes the number of neighbor headers Peer Header Number field and the sequence number field of the message; each Peer The header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- the controller 1100 further includes: a determining unit.
- the determining unit is used to determine the neighbor monitoring condition according to the summary information; the neighbor monitoring condition is used to indicate the target neighbor to which the routing information is to be sent.
- neighbor monitoring conditions are specifically implemented through dynamic programming.
- the receiving unit 1102 is specifically configured to receive the routing information of the target neighbor through the BMP.
- the receiving unit 1102 is also configured to receive updated routing information of the target neighbor of the network device.
- the receiving unit 1102 is specifically configured to: receive routing information of the first target neighbor in the online state among the target neighbors; then, the receiving unit 1102 is also configured to: The second target neighbor in the online state goes online and receives routing information of the second target neighbor.
- controller 1100 can be referred to the introduction in the method provided by the embodiment shown in FIG. 4.
- FIG. 12 is a schematic structural diagram of another network device provided by an embodiment of this application.
- the network device 1200 includes: a session establishment unit 1201 and a sending unit 1202.
- the session establishment unit 1201 is used to establish a border gateway protocol BGP monitoring protocol BMP session with the controller;
- the sending unit 1202 is configured to send summary information of all neighbors.
- the summary information includes the Internet Protocol IP address, routing identifier RD, and autonomous system serial number AS Number of each neighbor; among them, all neighbors have established BGP neighbor relationships with network devices at the current moment Neighbors.
- the sending unit 1202 is further configured to: when the network device has a new neighbor that establishes a BGP neighbor relationship, send the summary information of the new neighbor.
- the sending unit 1202 is specifically configured to send a neighbor summary report Peer Summary Report message, which is a message extended by BMP and carries summary information of all neighbors of the network device.
- the Peer Summary Report message includes: a message header, a list of neighbor headers Peer Header, and a timestamp; among them, the message header includes the number of neighbor headers Peer Header Number field and the sequence number field of the message; each Peer The header includes a neighbor type Peer Type field, a neighbor identifier Peer Flags field, an RD field, a local autonomous system Local AS field, a neighbor address Peer Address field, a neighbor autonomous system Peer AS field, and a neighbor BGP identifier Peer BGP ID field.
- the network device 1300 includes a processor 1301, a memory 1302, and a transceiver 1303.
- the memory 1302 stores at least one instruction
- the processor 1301 is used to load the instruction, and control the transceiver 1303 to execute the routing information monitoring method in any implementation manner in the corresponding embodiment in FIG. 4 or FIG. 9, for example, the receiving operation in step 402, the sending operation in step 404, and The sending operation of step 902, etc.
- the processor 1301 is further configured to load the instruction and execute the routing information monitoring method in any implementation manner in the corresponding embodiment in FIG. 4 or FIG. Operations other than the sending and receiving operations, such as the determining operation in step 403.
- the processor 1301 in the network device 1300 is configured to load the instruction and execute the following steps: the network device obtains neighbor monitoring conditions; the network device determines that the neighbors of the network device meet the neighbor monitoring conditions according to the neighbor monitoring conditions The target neighbor of the monitoring condition; moreover, the processor 1301 is also used to load the instruction and control the transceiver 1303 to perform the following steps: the network device sends the routing information of the target neighbor.
- the processor 1301 in the network device 1300 is configured to load the instruction and execute the following steps: the network device establishes a Border Gateway Protocol BGP monitoring protocol BMP session with the controller; and the processor 1301 is also configured to load The instructions and control the transceiver 1303 to perform the following steps: the network device sends summary information of all neighbors, the summary information includes the Internet Protocol IP address of each neighbor, the routing identifier RD, and the autonomous system serial number AS Number; where the All neighbors are neighbors that have established a BGP neighbor relationship with the network device at the current moment.
- the controller 1400 includes a processor 1401, a memory 1402, and a transceiver 1403.
- the memory 1402 stores at least one instruction.
- 1401 is used to load the instructions and control the transceiver 1403 to execute the routing information monitoring method in any one of the implementations in the corresponding embodiment in FIG. 4 or FIG. 9, for example, the sending operation in step 401, the receiving operation in step 405, and
- the processor 1401 is further configured to load the instruction and execute the routing information monitoring method in any implementation manner in the embodiment corresponding to FIG. 9, for example: step 901
- the processor 1401 in the controller 1400 is used to load the instructions and control the transceiver 1303 to perform the following steps: the controller sends neighbor monitoring conditions to the network device, and the neighbor monitoring conditions are used to instruct the The network device determines a target neighbor meeting the neighbor monitoring condition among the neighbors of the network device according to the neighbor monitoring condition; the controller receives routing information of the target neighbor sent by the network device.
- an embodiment of the present application also provides a routing information monitoring system.
- the system 1500 includes: a network device 1501 and a controller 1502, wherein the network device 1501 is configured to execute the foregoing FIG. 4 and FIG. 5 And the routing information monitoring method in any implementation manner in FIG. 9; the controller 1502 is configured to execute the routing information monitoring method in any implementation manner in FIG. 4, FIG. 5, and FIG. 9.
- the embodiment of the present application also provides a computer program product, which when it runs on a computer, causes the computer to execute the routing information monitoring method in any one of the foregoing implementation modes of FIG. 4, FIG. 5, and FIG. 9.
- embodiments of the present application also provide a computer-readable storage medium that stores instructions in the computer-readable storage medium, which when run on a computer, causes the computer to execute any of the above figures 4, 5 and 9 The routing information monitoring method in an implementation manner.
- the computer software product can be stored in a storage medium, such as read-only memory (English: read-only memory, ROM)/RAM, magnetic disk, An optical disc, etc., includes a number of instructions to enable a computer device (which may be a personal computer, a server, or a network communication device such as a router) to execute the method described in each embodiment of the application or some parts of the embodiment.
- a computer device which may be a personal computer, a server, or a network communication device such as a router
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本申请公开了一种路由信息监控方法和装置,网络设备获取邻居监控条件;该网络设备从所有邻居中确定满足该邻居监控条件的邻居,作为目标邻居,从而将目标邻居的路由信息发送给控制器,实现控制器对该网络设备的监控。可见,通过本申请实施例提供的路由信息监控方法,网络设备获取邻居监控条件后,该网络设备可以根据该邻居监控条件灵活的选择符合该邻居监控条件的目标邻居,解决了网络设备将其所有邻居的路由信息不加筛选的全部发送给控制器,而其部分邻居的路由信息根本不需要被关注,导致路由信息的监控浪费的问题,提高了对网络设备的路由信息监控的灵活性。
Description
本申请要求于2019年7月29日提交中国专利局、申请号为201910691270.4、申请名称为“一种路由信息监控方法和装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请涉及通信技术领域,特别是涉及一种路由信息监控方法和装置。
随着通信技术的飞速发展,边界网关协议(英文:Border Gateway Protocol,简称:BGP)已经成为Internet边界路由协议的标准,用于交换自治区域间的路由信息。但随着网络规模的扩大和路由表数目的增加,自治区域间路由信息的交换量越来越大,逐渐影响了网络的性能,尤其是网络震荡导致路由频繁变更,向网络的运维发起了极大的挑战。因此,需要监控各网络设备上的BGP路由信息,以使得可以通过监控到的路由信息对网络进行分析从而迅速找出导致路由转发异常的问题。
目前,监控各网络设备的BGP路由信息的方法,除了通过人工查询方式获得各网络设备上BGP的路由信息外,还可以通过逐个配置使能待监控的网络设备的BGP监控协议(英文:BGP Monitoring Protocol,简称:BMP)(也称为“使能监控”),由被配置为BMP使能的待监控网络设备向与监视服务器(英文:Monitoring Station)发送该网络设备的所有BGP邻居的路由信息,实现对网络设备的BGP路由信息的监控。但是,该监控路由信息的方式,待监控网络设备在被使能监控后,不加筛选的对其所有邻居的路由信息均进行发送,发送的路由信息中很可能包括了很多根本就不需要被关注的邻居的路由信息,导致监控不够灵活且浪费监控资源,从而难以实现对网络设备的路由信息进行灵活监控的问题。
发明内容
基于此,本申请实施例提供了一种路由信息监控方法和装置,可以通过设置监控目标邻居的筛选条件,以使得网络设备向控制器上报符合筛选条件的目标邻居的路由信息,实现对各待监控网络设备的路由信息的更加灵活的监控。
第一方面,在本申请实施例中,对待监控的网络设备进行路由信息监控,具体过程可以包括:网络设备获取邻居监控条件;该网络设备从该网络设备的所有邻居中确定符合该邻居监控条件的邻居,作为目标邻居;网络设备可以将目标邻居的路由信息进行发送,实现对该待监控的网络设备按照邻居监控条件的监控。可见,通过本申请实施例提供的路由信息监控方法,网络设备获取邻居监控条件后,该网络设备可以根据该邻居监控条件灵活的选择符合该邻居监控条件的目标邻居,解决了网络设备将其所有邻居的路由信息不加筛选的全部发送给控制器,而其部分邻居的路由信息根本不需要被关注,导致路由信息的监控浪费的问题,提高了对网络设备的路由信息监控的 灵活性。
结合第一方面的一种具体实现方式,网络设备发送目标邻居的路由信息,具体可以是:网络设备发送目标邻居中处于上线状态的第一目标邻居的路由信息;该实施例中,具体还可以包括:当目标邻居中处于下线状态的第二目标邻居上线,该网络设备发送第二目标邻居的路由信息。
结合第一方面的又一种具体实现方式,该网络设备获取邻居监控条件,一种情况下,可以是:该网络设备从控制器接收的邻居监控条件;另一种情况下,邻居监控条件也可以是:网络设备接收的配置信息中包括邻居监控条件。这样,通过灵活的获取邻居监控条件,使得后续可以有效的筛选出需要被关注的目标邻居,的路由信息,并将所筛选出的目标邻居的路由信息发送给控制器,实现路由信息的灵活监控,为提高对网络设备的路由信息监控的灵活性提供了数据基础。
可以理解的是,该邻居监控条件包括下述条件中的至少一个:条件一、网络设备的邻居中公网的BGP邻居,条件二、网络设备的邻居中私网的BGP邻居,条件三、网络设备的邻居中第四版互联网协议(英文:Internet Protocol version 4,简称:IPv4)的BGP邻居,条件四、网络设备的邻居中第六版互联网协议(英文:Internet Protocol version 6,简称:IPv6)的BGP邻居,条件五、网络设备的邻居中内部边界网关协议(英文:internal Border Gateway Protocol,简称:iBGP)的BGP邻居,条件六、网络设备的邻居中外部边界网关协议(英文:external Border Gateway Protocol,简称:eBGP)的BGP邻居,条件七、所述网络设备的邻居地址满足目标正则表达式的BGP邻居。如此,通过设置上述邻居监控条件中的任意一个或多个的组合,实现路由信息的灵活监控,为提高对网络设备的路由信息监控的灵活性提供了数据基础。
结合第一方面的另一种具体实现方式,该邻居监控条件具体可以通过动态编程实现,这样,提高了动态监控网络设备的灵活性。
结合第一方面的又一种具体实现方式,例如在网络设备被使能监控之前,本申请实施例还可以包括:网络设备与控制器建立BGP监控协议BMP会话;网络设备发送所有邻居的摘要信息,该摘要信息至少包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,该所有邻居指当前时刻已经与网络设备建立BGP邻居关系的邻居。作为一个示例,该网络设备发送所有邻居的摘要信息,具体可以是:网络设备通过BMP扩展的邻居汇总报告Peer Summary Report报文发送所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。这样,在对网络设备使能监控之前,控制器即可获取到该网络设备的所有邻居的摘要信息,可以为后续更加精准的确定邻居监控条件提供了数据基础。
需要说明的是,本申请实施例中,网络设备发送目标邻居的路由信息,具体可以是:该网络设备通过BMP发送目标邻居的路由信息。如此,可以实现在BMP场景下对网络设备的目标邻居的路由信息的灵活的监控。
结合第一方面的再一种具体实现方式,若目标邻居的路由发生更新,该实施例还可以包括:网络设备发送目标邻居更新后的路由信息。这样,可以实现对网络设备的目标邻居的实时监控,避免了对路由信息监控的时效性差导致影响网络运维的问题,提高了网络的可靠性。
需要说明的是,当网络设备除了获取到邻居监控条件外,还可以获取到目标设备列表,那么,该网络设备可以判断自身是否在目标设备列表中,若在,则,该网络设备可以根据所获取到的邻居监控条件,确定该网络设备的邻居中满足该邻居监控条件的目标邻居。此外,该网络设备也可以作为一个中转设备,根据该目标设备列表将该邻居监控条件分别转发给该目标设备列表中除了自身之外的其他目标设备。
第二方面,在本申请实施例中,对待监控的网络设备进行路由信息监控,具体过程可以包括:控制器发送邻居监控条件至网络设备,该邻居监控条件用于指示接收方的网络设备根据该邻居监控条件确定该网络设备的目标邻居;接着,该控制器即可接收到网络设备发送的目标邻居的路由信息。可见,通过本申请实施例提供的路由信息监控方法,控制器向网络设备发送邻居监控条件后,该网络设备可以根据该邻居监控条件灵活的选择符合该邻居监控条件的目标邻居,解决了网络设备将其所有邻居的路由信息不加筛选的全部发送给控制器,而其部分邻居的路由信息根本不需要被关注,导致路由信息的监控浪费的问题,提高了对网络设备的路由信息监控的灵活性。
可以理解的是,控制器还可以向网络设备发送目标设备列表,使得该网络设备可以作为中转设备,根据该目标设备列表将该邻居监控条件分别转发给该目标设备列表中的其他目标设备,以减少控制器和各网络设备之间的数据交互。
结合第二方面的一种具体实现方式,控制器接收目标邻居的路由信息,具体可以是:控制器接收目标邻居中处于上线状态的第一目标邻居的路由信息;该实施例中,具体还可以包括:当目标邻居中处于下线状态的第二目标邻居上线,该控制器接收第二目标邻居的路由信息。
结合第二方面的又一种具体实现方式,邻居监控条件具体通过动态编程实现。
结合第二方面的另一种具体实现方式,例如在所述网络设备被使能监控之前,该实施例还可以包括:控制器与网络设备建立BGP监控协议BMP会话,控制器接收网络设备所有邻居的摘要信息,摘要信息至少包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所有邻居指当前时刻已经与网络设备建立BGP邻居关系的邻居。作为一个示例,控制器接收网络设备所有邻居的摘要信息,具体为:控制器接收网络设备发送的邻居汇总报告Peer Summary Report报文,Peer Summary Report报文为通过BGP监控协议BMP扩展的报文,携带网络设备所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
可以理解的是,作为一个示例,该邻居监控条件包括下述条件中的至少一个:网络设备的邻居中公网的BGP邻居,网络设备的邻居中私网的BGP邻居,网络设备的 邻居中IPv4的BGP邻居,网络设备的邻居中IPv6的BGP邻居,网络设备的邻居中iBGP的BGP邻居,网络设备的邻居中eBGP的BGP邻居,或者,网络设备的邻居地址满足目标正则表达式的BGP邻居。或者,作为另一个示例,该实施例还可以包括:控制器根据摘要信息确定邻居监控条件,该邻居监控条件用于指示待发送路由信息的所述目标邻居,例如:该邻居摘要条件为目标邻居的标识列表。
结合第二方面的再一种具体实现方式,控制器接收网络设备发送的目标邻居的路由信息,具体为:控制器通过BGP监控协议BMP接收目标邻居的路由信息。
结合第二方面的又一种具体实现方式,若目标邻居的路由发生更新,该实施例还可以包括:控制器接收网络设备的目标邻居更新后的路由信息。
需要说明的是,第二方面提供的方法,与第一方面提供的方法对应,故,第二方面提供的方法的各种可能的实现方式以及达到的技术效果,可以参照前述第一方面提供的方法的介绍。
第三方面,在本申请实施例中,对待监控的网络设备进行路由信息监控,具体过程可以包括:当网络设备与控制器建立边界网关协议BGP监控协议BMP会话,该网络设备可以发送所有邻居的摘要信息,该摘要信息至少包括各邻居的互联网协议(英文:Internet Protocol,简称:IP)地址、路由标识(英文:Route Distinguisher,简称:RD)和自治系统序列号(英文:Autonomous System Number,简称:AS Number),该所有邻居为当前时刻已经与所述网络设备建立BGP邻居关系的邻居。可见,通过本申请实施例提供的路由信息监控方法,无需对网络设备使能监控,控制器即可获知该网络设备的邻居以及邻居摘要信息,实现对该网络设备的邻居的监控,为后续根据第一方面或第二方面提供的实施例对该网络设备进行路由信息的监控提供了数据基础。
结合第三方面的一种具体实现方式,网络设备发送所有邻居的摘要信息,具体为:网络设备发送邻居汇总报告Peer Summary Report报文,Peer Summary Report报文为通过BGP监控协议BMP扩展的报文,携带网络设备所有邻居的摘要信息。可以理解的是,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
结合第三方面的另一种具体实现方式,当该网络设备有建立所述BGP邻居关系的新邻居,则,该实施例还可以包括:网络设备发送新邻居的摘要信息。可以理解的是,该新邻居的摘要信息也可以是被网络设备携带在Peer Summary Report报文中发送的。
可以理解的是,在网络设备与控制器建立BGP监控协议BMP会话之后,在网络设备发送所有邻居的摘要信息之前,本申请实施例还可以包括:网络设备向控制器发送初始化消息,用于向控制器通告网络设备的供应商信息、软件版本号,该软件版本号用于标识支持Peer Summary Report报文,若控制器不支持该软件版本号,则,该控制器可以对该Peer Summary Report报文不作处理。
需要说明的是,第三方面提供的方法,与第一方面提供的方法中部分实现方式对应,故,第三方面提供的方法的各种可能的实现方式以及达到的技术效果,可以参照 前述第一方面提供的方法中的介绍。
第四方面,在本申请实施例中,还提供了一种网络设备,包括:获取单元、确定单元和发送单元。
其中,获取单元,用于获取邻居监控条件;
确定单元,用于根据所述邻居监控条件,确定所述网络设备的邻居中满足所述邻居监控条件的目标邻居;
发送单元,用于发送所述目标邻居的路由信息。
结合第四方面的一种具体实现方式,该获取单元,具体可以用于:从控制器接收邻居监控条件。
结合第四方面的另一种具体实现方式,该获取单元,具体也可以用于:接收配置信息,并基于配置信息生成邻居监控条件。
其中,邻居监控条件包括下述条件中的至少一个:网络设备的邻居中公网的边界网关协议BGP邻居,网络设备的邻居中私网的BGP邻居,网络设备的邻居中第四版互联网协议IPv4的BGP邻居,网络设备的邻居中第六版互联网协议IPv6的BGP邻居,网络设备的邻居中内部边界网关协议iBGP的BGP邻居,网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,网络设备的邻居地址满足目标正则表达式的BGP邻居。
可以理解的是,邻居监控条件具体通过动态编程实现。
结合第四方面的再一种具体实现方式,该装置还包括:建立会话单元。该建立会话单元,用于与控制器建立BGP监控协议BMP会话;那么,发送单元,还用于在与控制器建立BMP会话后,发送所有邻居的摘要信息,摘要信息至少包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所有邻居指当前时刻已经与网络设备建立BGP邻居关系的邻居。
结合第四方面的另一种具体实现方式,该发送单元,具体用于:在与控制器建立BMP会话后,通过BMP扩展的邻居汇总报告Peer Summary Report报文发送所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
结合第四方面的再一种具体实现方式,该发送单元,具体用于:通过BMP发送目标邻居的路由信息。
结合第四方面的又一种具体实现方式,该发送单元,还用于在目标邻居的路由发生更新时,发送目标邻居更新后的路由信息。
结合第四方面的再一种具体实现方式,该发送单元,具体用于:发送目标邻居中处于上线状态的第一目标邻居的路由信息;那么,发送单元,还用于当目标邻居中处于下线状态的第二目标邻居上线时,发送第二目标邻居的路由信息。
需要说明的是,第四方面提供的网络设备,与第一方面提供的方法对应,故,第四方面提供的网络设备的各种可能的实现方式以及达到的技术效果,可以参照前述第 一方面提供的方法中的介绍。
第五方面,本申请实施例还提供了一种控制器,包括:发送单元和接收单元。
其中,发送单元,用于发送邻居监控条件至网络设备,邻居监控条件用于指示网络设备根据邻居监控条件确定网络设备的邻居中满足邻居监控条件的目标邻居;
接收单元,用于接收网络设备发送的目标邻居的路由信息。
结合第五方面的一种具体实现方式,该邻居监控条件包括下述条件中的至少一个:网络设备的邻居中公网的边界网关协议BGP邻居,网络设备的邻居中私网的BGP邻居,网络设备的邻居中第四版互联网协议IPv4的BGP邻居,网络设备的邻居中第六版互联网协议IPv6的BGP邻居,网络设备的邻居中内部边界网关协议iBGP的BGP邻居,网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,网络设备的邻居地址满足目标正则表达式的BGP邻居。
结合第五方面的另一种具体实现方式,该装置还包括:建立会话单元。该建立会话单元,用于与网络设备建立BGP监控协议BMP会话;此时,接收单元,还用于在与网络设备建立BMP会话时,接收网络设备所有邻居的摘要信息,摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所有邻居指当前时刻已经与网络设备建立BGP邻居关系的邻居。作为一个示例,该接收单元,具体用于:与网络设备建立BMP会话时,接收网络设备发送的邻居汇总报告Peer Summary Report报文,Peer Summary Report报文为通过BMP扩展的报文,携带网络设备所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
该实现方式下,作为一个示例,该控制器还包括:确定单元。该确定单元,用于根据摘要信息确定邻居监控条件;邻居监控条件用于指示待发送路由信息的目标邻居。
结合第五方面的再一种具体实现方式,邻居监控条件具体通过动态编程实现。
结合第五方面的另一种具体实现方式,该接收单元,具体用于:通过BMP接收目标邻居的路由信息。
结合第五方面的再一种具体实现方式,该接收单元,还用于接收网络设备的目标邻居更新后的路由信息。
结合第五方面的另一种具体实现方式,该接收单元,具体用于:接收目标邻居中处于上线状态的第一目标邻居的路由信息;那么,该接收单元,还用于当目标邻居中处于下线状态的第二目标邻居上线,接收第二目标邻居的路由信息。
需要说明的是,第五方面提供的控制器,与第二方面提供的方法对应,故,第五方面提供的控制器的各种可能的实现方式以及达到的技术效果,可以参照前述第二方面提供的方法中的介绍。
第六方面,本申请实施例还提供了一种网络设备,包括:建立会话单元和发送单元。
其中,建立会话单元,用于与控制器建立边界网关协议BGP监控协议BMP会话;
发送单元,用于发送所有邻居的摘要信息,摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number;其中,所有邻居为当前时刻已经与网络设备建立BGP邻居关系的邻居。
结合第六方面的一种具体实现方式,该发送单元,还用于:当网络设备有建立BGP邻居关系的新邻居,则,发送新邻居的摘要信息。
结合第六方面的再一种具体实现方式,该发送单元,具体用于:发送邻居汇总报告Peer Summary Report报文,Peer Summary Report报文为通过BMP扩展的报文,携带网络设备所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
需要说明的是,第六方面提供的网络设备,与第三方面提供的方法对应,故,第六方面提供的网络设备的各种可能的实现方式以及达到的技术效果,可以参照前述第三方面提供的方法中的介绍。
第七方面,本申请实施例还提供了一种网络设备,包括:处理器、存储器以及收发器,该存储器中存储有至少一条指令,该处理器用于加载所述指令,并控制该收发器执行上述第一方面或者第三方面中任意一种实现方式下的路由信息监控方法中的发送和接收操作,且,所述该处理器还用于加载所述指令并执行上述第一方面或者第三方面中任意一种实现方式下的路由信息监控方法中的除所述发送和接收操作以外的其他操作,例如:建立会话操作,又例如:确定操作。
第八方面,本申请实施例还提供了一种控制器,包括:处理器、存储器以及收发器,该存储器中存储有至少一条指令,该处理器用于加载所述指令,并控制该收发器执行上述第二方面中任意一种实现方式下的路由信息监控方法中的发送操作,且,所述该处理器还用于加载所述指令并执行上述第二方面中任意一种实现方式下的路由信息监控方法中的建立会话操作。
第九方面,本申请实施例还提供了一种路由信息监控系统,该系统包括:网络设备和控制器,其中,网络设备,用于执行上述第一方面或者第三方面中任意一种实现方式下的路由信息监控方法;控制器,用于执行上述第二方面中任意一种实现方式下的路由信息监控方法。
第十方面,本申请实施例还提供了一种计算机程序产品,当其在计算机上运行时,使得计算机执行前述第一方面~第三方面中任意一种实现方式下的所述路由信息监控方法。
第十一方面,本申请实施例还提供了一种计算机可读存储介质,该计算机可读存储介质中存储有指令,当其在计算机上运行时,使得计算机执行以上第一方面~第三方面中任意一种实现方式下的所述路由信息监控方法。
图1为本申请实施例中实现路由信息监控的方法的信令流程图;
图2为本申请实施例中一应用场景所涉及的网络系统的框架示意图;
图3为本申请实施例中实现路由信息监控的方法的一实例的信令流程图;
图4为本申请实施例中一种路由信息监控的方法的流程示意图;
图5为本申请实施例中一种路由信息监控的方法的一示例的信令流程图;
图6为本申请实施例中Peer Summary Report报文的通用报文头的示意图;
图7为本申请实施例中Peer Summary Report报文的示意图;
图8为本申请实施例中Peer Summary Report报文的Peer Header的示意图;
图9为本申请实施例中另一种路由信息监控的方法的流程示意图;
图10为本申请实施例中一种网络设备的结构示意图;
图11为本申请实施例中一种控制器的结构示意图;
图12为本申请实施例中又一种网络设备的结构示意图;
图13为本申请实施例中一种网络设备的结构示意图;
图14为本申请实施例中一种控制器的结构示意图;
图15为本申请实施例中一种路由信息监控系统的结构示意图。
边界网关协议(英文:Border Gateway Protocol,简称:BGP),作为Internet边界路由协议的标准,用于交换自治区域间的路由信息。随着网络规模的扩大和路由表数目的增加,自治区域间路由信息的交换量越来越大,一旦发生网络震荡导致路由频繁变更等异常情况,就向该网络的运维发起了极大的挑战。因此,需要监控网络中各网络设备上的路由信息,以使得可以通过监控到的路由信息对网络进行分析从而迅速找出导致路由转发异常的问题。
目前,除了通过人工查询方式获得网络中各网络设备的路由信息实现对该网络设备路由信息的监控外,通常还可以对待监控的网络设备进行逐个手动配置,即,逐个对待监控的网络设备进行BGP监控协议(英文:BGP Monitoring Protocol,简称:BMP)使能,那么,被配置为BMP使能的待监控网络设备就处于被监控状态,即可向与之建立会话的监视服务器(英文:Monitoring Station)发送该网络设备的所有邻居的路由信息,实现监视服务器对该网络设备的路由信息的监控。
例如:图1示出了网络设备和监视服务器之间执行上述路由信息监控方法的一示例性的信令流程图。该示例中,BMP协议定义了一种有效监控网络设备BGP路由的方法,由监视服务器对网络中待监控的网络设备的BGP运行状态进行监控和管理。具体实现时,监视服务器10对网络设备20的路由信息监控过程可以包括:S11,网络设备20与监视服务器10建立BMP会话;S12,网络管理员在网络设备20上手动使能监控;S13,网络设备20向监视服务器10发送初始化(英文:Initiation)消息,用于向监视服务器10通告该网络设备的供应商信息、软件版本号等;S14,网络设备20向监视服务器10发送邻居上线通知(英文:Peer Up Notification)消息,用于向监视服务器10发送与该网络设备20建立邻居关系的BGP邻居;S15,网络设备20向监视服务器10发送路由监控(英文:Route Monitoring)消息,用于向监视服务器10发送 从BGP邻居收到的所有路由信息;S16,网络设备20向监视服务器10发送完成指示信息,用于告知监视服务器10已经对该网络设备20上的所有BGP邻居的路由信息发送完成;S17,当网络设备20的BGP邻居发生路由新增或撤销等变化情况,网络设备20向监视服务器10发送的最新路由信息;S18,网络设备20向监视服务器10发送统计报告(英文:Stats Reports)消息,用于向监视服务器10发送该网络设备20运行状态的统计信息;S19,网络设备20向监视服务器10发送邻居下线/上线通知(英文:Peer Down/Up Notification)消息,告知监视服务器10与该网络设备20中断邻居关系的BGP邻居或新建立邻居关系的BGP邻居;S20,网络设备20向监视服务器10发送结束(英文:Termination)消息,用于向监视服务器10通告关闭BMP会话,也可以告知关闭该BMP会话的原因。需要说明的是,上述网络设备20可以是支持BMP功能的网络设备,即,在S11之前,监视服务器10可以对网络设备20使能BMP能力。
但是,图1示例性的示出的该监控路由信息的方式,因为网管人员需要对待监控的网络设备进行逐个配置使能,不够方便;而且,处于被使能监控状态的网络设备将其所有邻居的路由信息不加筛选的全部发送,而该网络设备的部分邻居的路由信息很可能根本就不需要被关注,导致该路由信息的监控方法存在浪费网络资源且不够灵活的问题。
基于此,在本申请实施例中,只要网络设备可以获取到邻居监控条件,即可对该网络设备需要发送路由信息的邻居进行筛选,灵活的选择符合该邻居监控条件的目标邻居,并发送该网络设备的目标邻居的路由信息,实现对该网络设备的路由信息进行灵活的监控。
举例来说,本申请实施例的场景之一,可以是应用到如图2所示的场景中。该场景中包括网络设备101、网络设备102、网络设备103、软件定义网络(英文:Software Defined Network,简称:SDN)控制器200和网络管理员300。其中,网络设备102可以是待监控的网络设备,网络设备101和网络设备103为网络设备102的BGP邻居;SDN控制器200可以包括策略分析单元201、管理单元202和BMP监视单元203,该策略分析单元201分别与管理单元202和BMP监视单元203连接。
作为一个示例,本申请实施例提供的路由信息监控方法具体可以参见图3,包括下述S21~S26:S21,网络管理员300可以在SDN控制器200上部署BMP监控,并设置邻居监控条件(例如:监控网络设备的邻居中的公网BGP邻居),SDN控制器200可以将该邻居监控条件保存在其中的策略分析单元201上。S22,网络设备102与SDN控制器200之间建立BMP会话。S23,发送所有BGP邻居的摘要信息给SDN控制器200的BMP监视单元203。S24,策略分析单元201读取BMP监视单元203接收到的网络设备102的所有BGP邻居的摘要信息,并根据该摘要信息和网络管理员300设置的邻居监控条件,确定网络设备102的目标邻居列表。S25,策略分析单元201通过管理单元202向网络设备102发送目标邻居列表。S26,网络设备102发送目标邻居列表中的目标邻居的路由信息给SDN控制器200的BMP监视单元203。如此,即可实现按照需求动态、灵活的对网络设备的路由信息进行监控的目的。
需要说明的是,为了确保网络的可靠性和安全性,可以周期性的执行上述S24~S26,校验SDN控制器200上监控得到的网络设备102上目标邻居的路由是否发生变化,对 SDN控制器200上监控得到该网络设备102的目标邻居的路由信息进行更新。而且,网络管理员300也可以按照需求的变化在SDN控制器200上重新设置邻居监控条件,并按照新的邻居监控条件重新执行上述S22~S26,进行网络设备102的路由信息监控,从而,网络管理员300或其他相关技术人员可以在执行完S26后,通过连接SDN控制器200的显示设备看到新的监控结果。
可以理解的是,SDN控制器200与待监控的网络设备102之间,可以存在两个通道,一个通道可以是BMP协议通道,用于网络设备102向SDN控制200发送所有BGP邻居的摘要信息以及目标BGP邻居的路由信息;另一个通道可以是BMP监控通道,用于SDN控制器200向网络设备102发送邻居监控条件等信息,该通道具体可以网络配置协议(英文:Network Configuration Protocol,简称:NETCONF)或命令行接口(英文:Command-Line Interface,简称:CLI)等方式实现,也可以通过扩展BMP协议实现;其通道接口可以采用又一代(英文:Yet Another Next Generation,简称:YANG)数据模型接口或NETCONF接口实现。
需要说明的是,上述网络设备101~103具体可以任意具有路由功能的设备,例如:路由器、交换机、网关等设备,在本申请实施例中不作具体限定;上述SDN控制器200也可以是其他控制器,只要可以实现该SDN控制器200在本申请实施例中的功能即可,在本申请实施例中不作具体限定。
可以理解的是,上述场景仅是本申请实施例提供的一个场景示例,本申请实施例并不限于此场景。
下面结合附图,通过实施例来详细说明本申请实施例中一种路由信息监控方法的具体实现方式。
图4为本申请实施例中的一种路由信息监控方法的流程示意图。参见图4,该方法例如可以包括下述步骤401~步骤405:
步骤401,控制器发送邻居监控条件至网络设备。
步骤402,网络设备获取该邻居监控条件。
可以理解的是,该邻居监控条件,用于指示网络设备从其所有邻居中选择待发送路由信息的目标邻居,即,目标邻居需要满足该邻居监控条件。一种情况下,该邻居监控条件可以是筛选条件形式的邻居监控条件,另一种情况下,该邻居监控条件也可以是邻居列表形式的邻居监控条件。
对于筛选条件形式的邻居监控条件,可以是指网络管理员在控制器或网络设备上根据需求配置的条件,该筛选条件形式的邻居监控条件具体可以包括下述条件中的至少一个:条件一、网络设备的邻居中公网边界网关协议(英文:Border Gateway Protocol,简称:BGP)邻居,条件二、网络设备的邻居中私网的BGP邻居,条件三、网络设备的邻居中第四版互联网协议(英文:Internet Protocol version 4,简称:IPv4)的BGP邻居,条件四、网络设备的邻居中第六版互联网协议(英文:Internet Protocol version 6,简称:IPv6)的BGP邻居,条件五、网络设备的邻居中内部边界网关协议(英文:internal Border Gateway Protocol,简称:iBGP)的BGP邻居,条件六、网络设备的邻居中外部边界网关协议(英文:external Border Gateway Protocol,简称:eBGP)的BGP邻居,条件七、所述网络设备的邻居地址满足目标正则表达式的BGP邻居。例如:网络设备 接收到的邻居监控条件为条件一,那么,该邻居监控条件用于指示该网络设备在所有的邻居中,选择公网的BGP邻居作为该网络设备待监控的目标邻居。又例如:网络设备接收到的邻居监控条件包括条件二、条件三和条件五,那么,该邻居监控条件用于指示该网络设备在所有的邻居中,选择属于私网、IPv4和iBGP的BGP邻居作为该网络设备待监控的目标邻居;再例如:网络设备接收到的邻居监控条件包括条件二、条件四和条件六和七,那么,该邻居监控条件用于指示该网络设备在所有的邻居中,选择属于私网、IPv6、eBGP且满足目标正则表达式的BGP邻居作为该网络设备待监控的目标邻居。
可以理解的是,为了可以根据不同时刻的不同监控需求方便的进行调整,该邻居监控条件具体可以通过动态编程实现。例如:需要监控网络设备上除了前缀IP地址为1.1.1.1和2.2.2.2的公网邻居,不再需要到网络设备上查询出来所有邻居中的公网邻居,再逐个使能前缀IP地址不是1.1.1.1和2.2.2.2的各个公网邻居,尤其当网络设备的公网邻居众多时,监控路由信息之前的配置工作量巨大;而本申请实施例中,网络管理员等技术人员只需要通过动态编程的方式设置该筛选条件形式的邻居监控条件,对应到该实例,可以通过动态编程实现:监控网络设备的公网邻居,且通过deny语句过滤前缀IP地址为1.1.1.1和2.2.2.2的公网邻居,如此,通过简单、方便的动态编程体现该筛选条件形式的邻居监控条件,使得灵活的路由信息监控成为可能。
具体实现时,若网络管理员或者其他技术人员在控制器上设置筛选条件形式的邻居监控条件,那么,若控制器按照下述图5对应实施例接收到邻居的摘要信息,则,作为一个示例,步骤401中,控制器向网络设备发送的邻居监控条件可以是指:控制器根据该筛选条件形式的邻居监控条件和邻居的摘要信息确定的邻居列表形式的邻居监控条件;作为另一个示例,步骤401中,控制器向网络设备发送的邻居监控条件还可以是指:筛选条件形式的邻居监控条件,此时,步骤401中,网络设备接收到该筛选条件形式的邻居监控条件后,网络设备可以对该筛选条件形式的邻居监控条件进行解析,确定目标邻居;或者,该该网络设备还可以根据该筛选条件形式的邻居监控条件以及自身已知的所有邻居的摘要信息,确定目标邻居。
若网络管理员或者其他技术人员在网络设备上设置筛选条件形式的邻居监控条件,则,无需执行步骤401,步骤402中网络设备获取邻居监控条件,具体为:网络设备接收网络管理员或者其他技术人员在网络设备上设置的配置信息,该配置信息包括该邻居监控条件。
对于邻居列表形式的邻居监控条件,可以用于指示网络设备的所有邻居中的目标邻居,例如:该邻居列表形式的邻居监控条件可以是目标邻居列表。
作为一个示例,控制器可以根据网络管理员在控制器上配置的筛选条件形式的邻居监控条件,以及按照下述图5对应实施例接收到邻居的摘要信息,共同确定的目标邻居列表,作为该邻居列表形式的邻居监控条件;此时,该控制器可以将该邻居列表形式的邻居监控条件作为步骤401及步骤402中的“邻居监控条件”,发送给网络设备。
作为另一个示例,网络管理员或者其他技术人员可以直接在网络设备上设置目标邻居列表,作为邻居列表形式的邻居监控条件,那么,无需执行步骤401,网络设备 即可直接获取到的邻居列表形式的邻居监控条件作为步骤402中的“邻居监控条件”,从而直接确定出目标邻居。
在一些可能的实现方式中,当邻居监控条件适用多个目标设备时,例如,邻居监控条件1适用于网络设备A、网络设备B和网络设备C。一种情况下,控制器可以将该邻居监控条件分别发送给目标设备,如:控制器分别将邻居监控条件1发送给网络设备A、网络设备B和网络设备C,以便各目标设备根据该邻居监控条件实现本申请实施例提供的路由信息的监控。另一种情况下,控制器还可以在向所有待监控的网络设备发送邻居监控条件的同时,发送目标设备的标识,如:控制器将邻居监控条件1以及网络设备A、网络设备B、网络设备C的标识,分别发送给网络设备A、网络设备B、网络设备C、……等多个待监控的网络设备,如此,所有待监控设备判断自身是否和所接收到的目标设备的标识匹配,若匹配,则可以确定自身即为一个目标设备,此时,该匹配的目标设备作为网络设备执行本申请实施例中下述步骤403~步骤405完成路由信息的监控,即,网络设备A、网络设备B和网络设备C分别下述步骤403~步骤405完成路由信息的监控;若不匹配,则不执行本申请实施例中下述步骤403~步骤405完成路由信息的监控,即,除网络设备A、网络设备B和网络设备C之外的其他接收到该信息的设备均不执行下述步骤403~步骤405完成路由信息的监控。其中,该目标设备的标识用于指示需要按照该邻居监控条件被监控路由信息的对象。再一种情况下,该控制器也可以将该邻居监控条件和目标设备的标识发送给该网络中的与控制器相连的一个网络设备,该网络设备基于目标设备的标识,将该邻居监控条件发送给目标设备的标识对应的各个目标设备,如:控制器将邻居监控条件1以及网络设备A、网络设备B、网络设备C的标识,发送给网络设备D,此时,该网络设备D可以判断自身是否为网络设备A~C中的一个网络设备,若是,则,该网络设备D执行本申请实施例中下述步骤403~步骤405完成路由信息的监控,且将该邻居监控条件1以及另外两个网络设备的标识,分别发送给另外两个网络设备;若不是,则,该网络设备D根据网络设备A、网络设备B、网络设备C的标识,分别将邻居监控条件1发送给网络设备A、网络设备B和网络设备C,由各目标设备分别作为本申请实施例中的网络设备,执行本申请实施例中下述步骤403~步骤405完成路由信息的监控。
需要说明的是,控制器向网络设备发送的邻居监控条件,一种情况下,可以携带在监控指令中,那么,当网络设备接收到监控指令后,一方面,该网络设备可以知晓控制器要求监控该网络设备的路由信息;另一方面,该网络设备可以解析该监控指令,获得邻居监控条件,从而确定出路由信息监控遵循的规则,即,目标邻居需要满足的条件。另一种情况下,也可以先向网络设备发送邻居监控条件,该邻居监控条件只是告知网络设备该次监控路由信息需要遵循的规则,并不触发监控事件;当需要网络设备发送路由信息时,再由控制器向该网络设备发送与该邻居监控条件关联的监控开始指示。
在一些实现方式中,本申请实施例还可以包括:在网络设备与控制器建立BGP监控协议BMP会话之后,但控制器还未对网络设备进行使能监控之前,网络设备发送所有邻居的摘要信息,该摘要信息至少包括:各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,该所有邻居是指当前时刻已经与该网络设备建立 BGP邻居关系的邻居。
具体实现时,网络设备发送所有邻居的摘要信息,如图5所示,具体过程可以包括:
步骤501,网络设备与控制器建立BGP监控协议BMP会话;
步骤502,该网络设备向控制器发送初始化消息,用于向控制器通告该网络设备的供应商信息、软件版本号等;
步骤503,网络设备可以通过BGP监控协议BMP扩展的邻居汇总报告Peer Summary Report报文向发送该网络设备的所有邻居的摘要信息。
需要说明的是,步骤503之后,可以按照本申请实施例提供的路由信息监控方法对该网络设备进行监控,在此不再赘述。
可以理解的是,基于BMP协议,网络设备和控制器之间可以建立BMP会话,会话一旦建立成功,网络设备即可向控制器发送BMP消息。由于BMP协议规定,首先需要向控制器发送的第一个消息是初始化消息,用于通告网络设备的供应商信息和软件版本等信息,在此,为了标识该扩展的BMP协议支持Peer Summary Report报文,新定义了一个软件版本号。若控制器接收到该Peer Summary Report报文后,确定其不支持该新定义的软件版本号,则,该控制器可以忽略Peer Summary Report报文,直接通过步骤401~步骤405进行路由信息的监控。
作为一个实例,本申请实施例中扩展BMP后新增的Peer Summary Report报文的可以包括:报文头、一组邻居头Peer Header列表和时间戳Timestamp。其中,该BGP格式的报文还包括通用报文头,具体可以如图6所示,采用通用报文头的格式,定义报文头类型Msg.Type=7,指示该报文为Peer Summary Report报文;此外,该报文头中还携带版本Version和报文长度Message Length。
该Peer Summary Report报文的可以示意性的参见图7所示,其中,报文头包括:2个字节的邻居头数目Peer Header Number字段和2个字节的报文序列号Sequence Number字段。其中,Peer Header Number表示该报文中携带的邻居头Peer Header的数目N;Sequence Number表示报文序列号,当网络设备的邻居数目较少,可以通过一个Peer Summary Report报文携带所有邻居的摘要信息时,该Peer Summary Report报文中的Sequence Number=0,当网络设备的邻居数量较多,需要通过多个Peer Summary Report报文携带所有邻居的摘要信息时,各Peer Summary Report报文中的Sequence Number从0开始递增。
参见图8,该Peer Summary Report报文的每个Peer Header可以包括:邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。其中,RD字段可以占用8个字节,Peer Address字段可以占用16字节。
该Peer Summary Report报文的时间戳Timestamp,如图7,包括:秒seconds对应的字段和微秒microseconds对应的字段。
作为一个示例,当网络设备有与之建立BGP邻居关系的新邻居,则,该网络设备还可以将该新邻居的摘要信息发送给控制器。例如:只要网络设备有一个新邻居与之建立BGP邻居关系,该网络设备就可以将该新邻居的摘要信息发送给控制器;又例如: 也可以预设上报周期,该网络设备可以周期性的上报该周期内与该网络设备建立BGP邻居关系的新邻居的摘要信息。可以理解的是,网络设备也可以将该新邻居的摘要信息携带在Peer Summary Report报文中,发送给控制器。
可见,通过在步骤401之前执行图5对应的路由信息监控方法,即使未对网络设备进行使能监控,控制器也可以获知该网络设备的邻居以及邻居信息,实现对该网络设备的邻居的监控,为后续实施图4对应的方法,对该网络设备进行路由信息的监控提供了数据基础。
需要说明的是,当网络设备在未被使能监控之前,执行了上述步骤501~步骤503,即,该控制器接收到网络设备上当前所有邻居的摘要信息,那么,步骤401和步骤402中的邻居监控条件既可以是筛选条件形式的邻居监控条件,也可以是邻居列表形式的邻居监控条件。或者,若未执行上述步骤501~步骤503,即,该控制器未接收到网络设备上当前所有邻居的摘要信息,那么,步骤401和步骤402中邻居监控条件可以是的邻居监控条件可以是筛选条件形式的邻居监控条件;其中,若未执行步骤401,即,网络设备获取的邻居监控条件是自身接收到的配置信息中包括的邻居监控条件,那么,该步骤402中的邻居监控条件既可以是筛选条件形式的邻居监控条件,也可以是邻居列表形式的邻居监控条件。
可以理解的是,通过步骤401~步骤402,网络设备获取到了邻居监控条件,为实现灵活、高效的路由信息监控提供了数据基础。
步骤403,网络设备根据该邻居监控条件,确定该网络设备的邻居中满足该邻居监控条件的目标邻居。
具体实现时,作为一个示例,当网络设备接收到的邻居监控条件为邻居列表形式的邻居监控条件,该网络设备即可直接确定出目标邻居。作为另一个示例,当网络设备接收到的邻居监控条件为筛选条件形式的邻居监控条件,则,该网络设备可以对该筛选条件形式的邻居监控条件进行解析,从而确定出目标邻居,例如:该网络设备可以基于该筛选条件形式的邻居监控条件,以及自身已知的所有邻居的摘要信息,从所有邻居中确定符合该筛选条件形式的邻居监控条件的目标邻居。
步骤404,该网络设备发送目标邻居的路由信息。
可以理解的是,网络设备可以通过BMP发送该目标邻居的路由信息。
步骤405,控制器接收该网络设备发送的目标邻居的路由信息。
可以理解的是,当确定的目标邻居均为上线状态时,则,该网络设备可以将所有的目标邻居的路由信息发送给控制器。当确定的目标邻居中,部分目标邻居处于上线状态,则,该网络设备可以先将处于上线状态的目标邻居的路由信息发送给控制器,一旦其他处于下线状态的目标邻居上线,该网络设备就可以将新上线的目标邻居的路由信息再发送给控制器。
在一些具体的实现方式中,当目标邻居的路由发生更新,本申请实施例还可以包括:网络设备发送目标邻居更新后的路由信息给控制器,从而控制器接收该网络设备的目标邻居更新后的路由信息。
作为一个实例,当网络设备的邻居发生变化例如:新增或删除该网络设备上的邻居时,该网络设备可以实时发送邻居变化信息给控制器,告知控制器该网络设备的邻 居的变化情况;而且,当发生变化的邻居为该网络设备的目标邻居时,该网络设备还可以自主发送目标邻居变化后的摘要信息、以及该目标邻居更新后的路由信息给控制器,如此,可以实现对网络设备的目标邻居状况的实时监控,避免了对路由信息监控的时效性差导致影响网络运维的问题,提高了网络的可靠性。
可见,通过本申请实施例提供的路由信息监控方法,通过本申请实施例提供的路由信息监控方法,网络设备获取邻居监控条件后,该网络设备可以根据该邻居监控条件灵活的选择符合该邻居监控条件的目标邻居,解决了网络设备将其所有邻居的路由信息不加筛选的全部发送给控制器,而其部分邻居的路由信息根本不需要被关注,导致路由信息的监控浪费的问题,提高了对网络设备的路由信息监控的灵活性。
需要说明的是,本申请实施例还提供了一种路由监控方法,在还未对网络设备使能监控之前,网络设备自主发送当前时刻已经与该网络设备建立BGP邻居关系的所有邻居的摘要信息,该摘要信息至少包括:各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number。参见图9,该实施例具体可以包括:
步骤901,网络设备与控制器建立边界网关协议BGP监控协议BMP会话。
步骤902,网络设备发送所有邻居的摘要信息,该摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number;该所有邻居为当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
作为一个示例,在步骤901和步骤902之间,本实施例还可以执行:网络设备发送初始化消息,用于向控制器通告该网络设备的供应商信息、软件版本号。
具体实现时,该网络设备可以通过BGP监控协议BMP扩展的邻居总结报告Peer Summary Report发送所述所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳。该报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
可以理解的是,为了确保路由信息监控的准确性,关于发送网络设备上所有邻居的摘要信息,可以在网络设备的所有邻居的路由信息发生变化,例如:当新增或删除该网络设备上的邻居时,触发再次执行上述步骤901,为后续图4所示的网络监控提供准确的数据基础,提高路由信息监控的准确性,从而提高网络可靠性。或者,也可以预设发送周期,周期性的发送当前已经与该网络设备建立BGP邻居关系的所有邻居的摘要信息,以便对该网络设备的监控更加准确及时,从而提高控制器发送邻居监控条件等控制、管理决策的准确性。
需要说明的是,上述步骤901~步骤902,网络设备与控制器建立边界网关协议BGP监控协议BMP会话后,网络设备即可发送所有邻居的摘要信息,这样,控制器在与网络设备建立会话初期,就可以获知该网络设备的邻居以及邻居信息,实现对该网络设备的邻居的监控,也可以为其他可能的指标的后续监控提供数据基础。
需要说明的是,该实施例的具体实现方式以及达到的效果,可以参见上述图5对应实施例部分的相关描述。
可见,通过本申请实施例提供的路由信息监控方法,无需对网络设备使能,控制器即可获知该网络设备的邻居以及邻居信息,实现对该网络设备的邻居的监控,为后续根据第一方面或第二方面提供的实施例对该网络设备进行路由信息的监控提供了数据基础。
图10为本申请实施例提供的一种网络设备的结构示意图。该网络设备1000包括:获取单元1001、确定单元1002和发送单元1003。
其中,获取单元1001,用于获取邻居监控条件;
确定单元1002,用于根据邻居监控条件,确定网络设备的邻居中满足邻居监控条件的目标邻居;
发送单元903,用于发送目标邻居的路由信息。
在一种具体实现方式中,该获取单元1001,具体可以用于:从控制器接收邻居监控条件。
在另一种具体实现方式中,该获取单元1001,具体也可以用于:接收配置信息,并基于配置信息生成邻居监控条件。
其中,邻居监控条件包括下述条件中的至少一个:网络设备的邻居中公网的边界网关协议BGP邻居,网络设备的邻居中私网的BGP邻居,网络设备的邻居中第四版互联网协议IPv4的BGP邻居,网络设备的邻居中第六版互联网协议IPv6的BGP邻居,网络设备的邻居中内部边界网关协议iBGP的BGP邻居,网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,网络设备的邻居地址满足目标正则表达式的BGP邻居。
可以理解的是,邻居监控条件具体通过动态编程实现。
在再一种具体实现方式中,该网络设备1000还包括:建立会话单元。该建立会话单元,用于与控制器建立BGP监控协议BMP会话;那么,发送单元1003,还用于在与控制器建立BMP会话后,发送所有邻居的摘要信息,摘要信息至少包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所有邻居指当前时刻已经与网络设备建立BGP邻居关系的邻居。
在另一种具体实现方式中,该发送单元1003,具体用于:在与控制器建立BMP会话后,通过BMP扩展的邻居汇总报告Peer Summary Report报文发送所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
在再一种具体实现方式中,该发送单元1003,具体用于:通过BMP发送目标邻居的路由信息。
在又一种具体实现方式中,该发送单元1003,还用于在目标邻居的路由发生更新时,发送目标邻居更新后的路由信息。
在再一种具体实现方式,该发送单元1003,具体用于:发送目标邻居中处于上线状态的第一目标邻居的路由信息;那么,发送单元1003,还用于当目标邻居中处于下 线状态的第二目标邻居上线时,发送第二目标邻居的路由信息。
需要说明的是,该网络设备1000的各种可能的实现方式以及达到的技术效果,可以参照前述图4所示实施例对应方法中的介绍。
图11为本申请实施例提供的一种控制器的结构示意图。该控制器1100,包括:发送单元1101和接收单元1102。
其中,发送单元1101,用于发送邻居监控条件至网络设备,邻居监控条件用于指示网络设备根据邻居监控条件确定网络设备的邻居中满足邻居监控条件的目标邻居;
接收单元1102,用于接收网络设备发送的目标邻居的路由信息。
在一种具体实现方式中,该邻居监控条件包括下述条件中的至少一个:网络设备的邻居中公网的边界网关协议BGP邻居,网络设备的邻居中私网的BGP邻居,网络设备的邻居中第四版互联网协议IPv4的BGP邻居,网络设备的邻居中第六版互联网协议IPv6的BGP邻居,网络设备的邻居中内部边界网关协议iBGP的BGP邻居,网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,网络设备的邻居地址满足目标正则表达式的BGP邻居。
在另一种具体实现方式中,该控制器1100还包括:建立会话单元。该建立会话单元,用于与网络设备建立BGP监控协议BMP会话;此时,接收单元1102,还用于在与网络设备建立BMP会话时,接收网络设备所有邻居的摘要信息,摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所有邻居指当前时刻已经与网络设备建立BGP邻居关系的邻居。作为一个示例,该接收单元,具体用于:与网络设备建立BMP会话时,接收网络设备发送的邻居汇总报告Peer Summary Report报文,Peer Summary Report报文为通过BMP扩展的报文,携带网络设备所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
该实现方式下,作为一个示例,该控制器1100还包括:确定单元。该确定单元,用于根据摘要信息确定邻居监控条件;邻居监控条件用于指示待发送路由信息的目标邻居。
在再一种具体实现方式中,邻居监控条件具体通过动态编程实现。
在另一种具体实现方式中,该接收单元1102,具体用于:通过BMP接收目标邻居的路由信息。
在再一种具体实现方式中,该接收单元1102,还用于接收网络设备的目标邻居更新后的路由信息。
在另一种具体实现方式中,该接收单元1102,具体用于:接收目标邻居中处于上线状态的第一目标邻居的路由信息;那么,该接收单元1102,还用于当目标邻居中处于下线状态的第二目标邻居上线,接收第二目标邻居的路由信息。
需要说明的是,该控制器1100的各种可能的实现方式以及达到的技术效果,可以参照前述图4所示实施例提供的方法中的介绍。
图12为本申请实施例提供的另一种网络设备的结构示意图。该网络设备1200,包括:建立会话单元1201和发送单元1202。
其中,建立会话单元1201,用于与控制器建立边界网关协议BGP监控协议BMP会话;
发送单元1202,用于发送所有邻居的摘要信息,摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number;其中,所有邻居为当前时刻已经与网络设备建立BGP邻居关系的邻居。
在一种具体实现方式中,该发送单元1202,还用于:当网络设备有建立BGP邻居关系的新邻居,则,发送新邻居的摘要信息。
在再一种具体实现方式中,该发送单元1202,具体用于:发送邻居汇总报告Peer Summary Report报文,Peer Summary Report报文为通过BMP扩展的报文,携带网络设备所有邻居的摘要信息。其中,该Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
需要说明的是,该网络设备1200的各种可能的实现方式以及达到的技术效果,可以参照前述图5或图9所示实施例提供的方法中的介绍。
此外,本申请实施例还提供了一种网络设备,如图13所示,该网络设备1300包括:处理器1301、存储器1302以及收发器1303,该存储器1302中存储有至少一条指令,该处理器1301用于加载所述指令,并控制该收发器1303执行上述图4或图9对应实施例中任意一种实现方式下的路由信息监控方法中例如步骤402的接收操作、步骤404的发送操作以及步骤902的发送操作等,且,所述该处理器1301还用于加载所述指令并执行上述图4或图9对应实施例中任意一种实现方式下的路由信息监控方法中的除所述发送和接收操作以外的其他操作,例如步骤403的确定操作。
示例性的,该网络设备1300中的处理器1301用于加载所述指令,并执行下述步骤:网络设备获取邻居监控条件;网络设备根据该邻居监控条件,确定网络设备的邻居中满足该邻居监控条件的目标邻居;而且,处理器1301还用于加载所述指令,并控制该收发器1303执行下述步骤:网络设备发送目标邻居的路由信息。
示例性的,该网络设备1300中的处理器1301用于加载所述指令,并执行下述步骤:网络设备与控制器建立边界网关协议BGP监控协议BMP会话;而且,处理器1301还用于加载所述指令,并控制该收发器1303执行下述步骤:网络设备发送所有邻居的摘要信息,该摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number;其中,该所有邻居为当前时刻已经与该网络设备建立BGP邻居关系的邻居。
此外,本申请实施例还提供了一种控制器,如图14所示,该控制器1400包括:处理器1401、存储器1402以及收发器1403,该存储器1402中存储有至少一条指令,该处理器1401用于加载所述指令,并控制该收发器1403执行上述图4或图9对应实施例中任意一种实现方式下的路由信息监控方法中例如步骤401的发送操作、步骤405 的接收操作以及步骤902的接收操作等的发送操作,且,所述该处理器1401还用于加载所述指令并执行上述图9对应实施例中任意一种实现方式下的路由信息监控方法中例如:步骤901的建立会话操作。
示例性的,该控制器1400中的处理器1401用于加载所述指令,并控制该收发器1303执行下述步骤:控制器发送邻居监控条件至网络设备,该邻居监控条件用于指示所述网络设备根据所述邻居监控条件确定所述网络设备的邻居中满足所述邻居监控条件的目标邻居;该控制器接收网络设备发送的目标邻居的路由信息。
此外,本申请实施例还提供了一种路由信息监控系统,如图15所示,该系统1500包括:网络设备1501和控制器1502,其中,网络设备1501,用于执行上述图4、图5和图9中任意一种实现方式下的路由信息监控方法;控制器1502,用于执行上述图4、图5和图9中任意一种实现方式下的路由信息监控方法。
此外,本申请实施例还提供了一种计算机程序产品,当其在计算机上运行时,使得计算机执行前述图4、图5和图9中任意一种实现方式下的所述路由信息监控方法。
此外,本申请实施例还提供了一种计算机可读存储介质,该计算机可读存储介质中存储有指令,当其在计算机上运行时,使得计算机执行以上图4、图5和图9中任意一种实现方式下的所述路由信息监控方法。
本申请实施例中提到的“第一目标邻居”等名称中的“第一”只是用来做名字标识,并不代表顺序上的第一。该规则同样适用于“第二”等。
通过以上的实施方式的描述可知,本领域的技术人员可以清楚地了解到上述实施例方法中的全部或部分步骤可借助软件加通用硬件平台的方式来实现。基于这样的理解,本申请的技术方案可以以软件产品的形式体现出来,该计算机软件产品可以存储在存储介质中,如只读存储器(英文:read-only memory,ROM)/RAM、磁碟、光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者诸如路由器等网络通信设备)执行本申请各个实施例或者实施例的某些部分所述的方法。
本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于装置实施例和系统实施例而言,由于其基本相似于方法实施例,所以描述得比较简单,相关之处参见方法实施例的部分说明即可。以上所描述的装置及系统实施例仅仅是示意性的,其中作为分离部件说明的模块可以是或者也可以不是物理上分开的,作为模块显示的部件可以是或者也可以不是物理模块,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。
以上所述仅是本申请示例性的实施方式,并非用于限定本申请的保护范围。
以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以所述权利要求的保护范围为准。
Claims (52)
- 一种路由信息监控方法,其特征在于,包括:网络设备获取邻居监控条件;所述网络设备根据所述邻居监控条件,确定所述网络设备的邻居中满足所述邻居监控条件的目标邻居;所述网络设备发送所述目标邻居的路由信息。
- 根据权利要求1所述的方法,其特征在于,所述网络设备获取邻居监控条件,具体为:所述网络设备从控制器接收所述邻居监控条件。
- 根据权利要求1所述的方法,其特征在于,所述网络设备获取邻居监控条件,具体为:所述网络设备接收配置信息,所述配置信息包括所述邻居监控条件。
- 根据权利要求1至3任一项所述的方法,其特征在于,所述邻居监控条件包括下述条件中的至少一个:所述网络设备的邻居中公网的边界网关协议BGP邻居,所述网络设备的邻居中私网的BGP邻居,所述网络设备的邻居中第四版互联网协议IPv4的BGP邻居,所述网络设备的邻居中第六版互联网协议IPv6的BGP邻居,所述网络设备的邻居中内部边界网关协议iBGP的BGP邻居,所述网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,所述网络设备的邻居地址满足目标正则表达式的BGP邻居。
- 根据权利要求1至4任一项所述的方法,其特征在于,所述邻居监控条件具体通过动态编程实现。
- 根据权利要求1至5任一项所述的方法,其特征在于,还包括:所述网络设备与所述控制器建立BGP监控协议BMP会话;所述网络设备发送所有邻居的摘要信息,所述摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所述所有邻居指当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
- 根据权利要求6所述的方法,其特征在于,所述网络设备发送所有邻居的摘要信息,具体为:所述网络设备通过BMP扩展的邻居汇总报告Peer Summary Report报文发送所述所有邻居的摘要信息。
- 根据权利要求7所述的方法,其特征在于,所述Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,所述报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个所述Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
- 根据权利要求1所述的方法,其特征在于,所述网络设备发送所述目标邻居的路由信息,具体为:所述网络设备通过BMP发送所述目标邻居的路由信息。
- 根据权利要求1至9任一项所述的方法,其特征在于,若所述目标邻居的路由发生更新,所述方法还包括:所述网络设备发送所述目标邻居更新后的路由信息。
- 根据权利要求1至10任一项所述的方法,其特征在于,所述网络设备发送所述目标邻居的路由信息,具体为:所述网络设备发送所述目标邻居中处于上线状态的第一目标邻居的路由信息;所述方法还包括:当所述目标邻居中处于下线状态的第二目标邻居上线,所述网络设备发送所述第二目标邻居的路由信息。
- 一种路由信息监控方法,其特征在于,包括:控制器发送邻居监控条件至网络设备,所述邻居监控条件用于指示所述网络设备根据所述邻居监控条件确定所述网络设备的邻居中满足所述邻居监控条件的目标邻居;所述控制器接收所述网络设备发送的所述目标邻居的路由信息。
- 根据权利要求12所述的方法,其特征在于,所述邻居监控条件包括下述条件中的至少一个:所述网络设备的邻居中公网的边界网关协议BGP邻居,所述网络设备的邻居中私网的BGP邻居,所述网络设备的邻居中第四版互联网协议IPv4的BGP邻居,所述网络设备的邻居中第六版互联网协议IPv6的BGP邻居,所述网络设备的邻居中内部边界网关协议iBGP的BGP邻居,所述网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,所述网络设备的邻居地址满足目标正则表达式的BGP邻居。
- 根据权利要求12所述的方法,其特征在于,还包括:所述控制器与所述网络设备建立BGP监控协议BMP会话;所述控制器接收所述网络设备发送的所有邻居的摘要信息,所述摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所述所有邻居指当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
- 根据权利要求14所述的方法,其特征在于,所述控制器接收所述网络设备发送的所有邻居的摘要信息,具体为:所述控制器接收所述网络设备发送的邻居汇总报告Peer Summary Report报文,所述Peer Summary Report报文为通过BMP扩展的报文,携带所述网络设备所有邻居的摘要信息。
- 根据权利要求15所述的方法,其特征在于,所述Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,所述报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个所述Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
- 根据权利要求14至16任一项所述的方法,其特征在于,还包括:所述控制器根据所述摘要信息确定所述邻居监控条件;所述邻居监控条件用于指 示待发送路由信息的所述目标邻居。
- 根据权利要求12至17任一项所述的方法,其特征在于,所述邻居监控条件具体通过动态编程实现。
- 根据权利要求12所述的方法,其特征在于,所述控制器接收所述网络设备发送的所述目标邻居的路由信息,具体为:所述控制器通过BMP接收所述网络设备发送的所述目标邻居的路由信息。
- 根据权利要求12至19任一项所述的方法,其特征在于,若所述目标邻居的路由发生更新,所述方法还包括:所述控制器接收所述网络设备发送的所述目标邻居更新后的路由信息。
- 根据权利要求12至20任一项所述的方法,其特征在于,所述控制器接收所述网络设备发送的所述目标邻居的路由信息,具体为:所述控制器接收所述目标邻居中处于上线状态的第一目标邻居的路由信息;所述方法还包括:当所述目标邻居中处于下线状态的第二目标邻居上线,所述控制器接收所述第二目标邻居的路由信息。
- 一种路由信息监控方法,其特征在于,包括:网络设备与控制器建立边界网关协议BGP监控协议BMP会话;所述网络设备发送所有邻居的摘要信息,所述摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number;其中,所述所有邻居为当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
- 根据权利要求22所述的方法,其特征在于,还包括:当所述网络设备有与该网络设备建立BGP邻居关系的新邻居,则,所述网络设备发送所述新邻居的摘要信息。
- 根据权利要求22所述的方法,其特征在于,所述网络设备发送所有邻居的摘要信息,具体为:所述网络设备发送邻居汇总报告Peer Summary Report报文,所述Peer Summary Report报文为通过BMP扩展的报文,携带所述网络设备所有邻居的摘要信息。
- 根据权利要求24所述的方法,其特征在于,所述Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,所述报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个所述Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
- 一种网络设备,其特征在于,包括:获取单元,用于获取邻居监控条件;确定单元,用于根据所述邻居监控条件,确定所述网络设备的邻居中满足所述邻居监控条件的目标邻居;发送单元,用于发送所述目标邻居的路由信息。
- 根据权利要求26所述的网络设备,其特征在于,所述获取单元,具体用于:从控制器接收所述邻居监控条件。
- 根据权利要求26所述的网络设备,其特征在于,所述获取单元,具体用于:接收配置信息,所述配置信息包括所述邻居监控条件。
- 根据权利要求26至28任一项所述的网络设备,其特征在于,所述邻居监控条件包括下述条件中的至少一个:所述网络设备的邻居中公网的边界网关协议BGP邻居,所述网络设备的邻居中私网的BGP邻居,所述网络设备的邻居中第四版互联网协议IPv4的BGP邻居,所述网络设备的邻居中第六版互联网协议IPv6的BGP邻居,所述网络设备的邻居中内部边界网关协议iBGP的BGP邻居,所述网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,所述网络设备的邻居地址满足目标正则表达式的BGP邻居。
- 根据权利要求26至29任一项所述的网络设备,其特征在于,所述邻居监控条件具体通过动态编程实现。
- 根据权利要求26至30任一项所述的网络设备,其特征在于,还包括:建立会话单元,用于与所述控制器建立BGP监控协议BMP会话;所述发送单元,还用于在与所述控制器建立所述BMP会话后,发送所有邻居的摘要信息,所述摘要信息至少包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所述所有邻居指当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
- 根据权利要求31所述的网络设备,其特征在于,所述发送单元,具体用于:在与所述控制器建立所述BMP会话后,通过BMP扩展的邻居汇总报告Peer Summary Report报文发送所述所有邻居的摘要信息。
- 根据权利要求32所述的网络设备,其特征在于,所述Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,所述报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个所述Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
- 根据权利要求26所述的网络设备,其特征在于,所述发送单元,具体用于:通过BMP发送所述目标邻居的路由信息。
- 根据权利要求26至34任一项所述的网络设备,其特征在于,所述发送单元,还用于在所述目标邻居的路由发生更新时,发送所述目标邻居更新后的路由信息。
- 根据权利要求26至35任一项所述的网络设备,其特征在于,所述发送单元,具体用于:发送所述目标邻居中处于上线状态的第一目标邻居的路由信息;所述发送单元,还用于当所述目标邻居中处于下线状态的第二目标邻居上线时,发送所述第二目标邻居的路由信息。
- 一种控制器,其特征在于,包括:发送单元,用于发送邻居监控条件至网络设备,所述邻居监控条件用于指示所述 网络设备根据所述邻居监控条件确定所述网络设备的邻居中满足所述邻居监控条件的目标邻居;接收单元,用于接收所述网络设备发送的所述目标邻居的路由信息。
- 根据权利要求37所述的控制器,其特征在于,所述邻居监控条件包括下述条件中的至少一个:所述网络设备的邻居中公网的边界网关协议BGP邻居,所述网络设备的邻居中私网的BGP邻居,所述网络设备的邻居中第四版互联网协议IPv4的BGP邻居,所述网络设备的邻居中第六版互联网协议IPv6的BGP邻居,所述网络设备的邻居中内部边界网关协议iBGP的BGP邻居,所述网络设备的邻居中外部边界网关协议eBGP的BGP邻居,或者,所述网络设备的邻居地址满足目标正则表达式的BGP邻居。
- 根据权利要求37所述的控制器,其特征在于,还包括:建立会话单元,用于与所述网络设备建立BGP监控协议BMP会话;所述接收单元,还用于在与所述网络设备建立所述BMP会话后,接收所述网络设备所有邻居的摘要信息,所述摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number,所述所有邻居指当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
- 根据权利要求39所述的控制器,其特征在于,所述接收单元,具体用于:与所述网络设备建立所述BMP会话后,接收所述网络设备发送的邻居汇总报告Peer Summary Report报文,所述Peer Summary Report报文为通过BMP扩展的报文,携带所述网络设备所有邻居的摘要信息。
- 根据权利要求40所述的控制器,其特征在于,所述Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,所述报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个所述Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
- 根据权利要求39至41任一项所述的控制器,其特征在于,还包括:确定单元,用于根据所述摘要信息确定所述邻居监控条件;所述邻居监控条件用于指示待发送路由信息的所述目标邻居。
- 根据权利要求37至42任一项所述的控制器,其特征在于,所述邻居监控条件具体通过动态编程实现。
- 根据权利要求37所述的控制器,其特征在于,所述接收单元,具体用于:通过BMP接收所述目标邻居的路由信息。
- 根据权利要求37至44任一项所述的控制器,其特征在于,所述接收单元,还用于在所述目标邻居的路由发生更新时,接收所述网络设备发送所述目标邻居更新后的路由信息。
- 根据权利要求37至45任一项所述的控制器,其特征在于,所述接收单元,具体用于:接收所述目标邻居中处于上线状态的第一目标邻居的路由信息;所述接收单元,还用于当所述目标邻居中处于下线状态的第二目标邻居上线,接收所述第二目标邻居的路由信息。
- 一种网络设备,其特征在于,包括:建立会话单元,用于与控制器建立边界网关协议BGP监控协议BMP会话;发送单元,用于发送所有邻居的摘要信息,所述摘要信息包括各邻居的互联网协议IP地址、路由标识RD和自治系统序列号AS Number;其中,所述所有邻居为当前时刻已经与所述网络设备建立BGP邻居关系的邻居。
- 根据权利要求47所述的网络设备,其特征在于,所述发送单元,还用于:当所述网络设备有与该网络设备建立BGP邻居关系的新邻居,则,发送所述新邻居的摘要信息。
- 根据权利要求47所述的网络设备,其特征在于,所述发送单元,具体用于:发送邻居汇总报告Peer Summary Report报文,所述Peer Summary Report报文为通过BMP扩展的报文,携带所述网络设备所有邻居的摘要信息。
- 根据权利要求49所述的网络设备,其特征在于,所述Peer Summary Report报文包括:报文头、一组邻居头Peer Header列表和时间戳;其中,所述报文头包括邻居头数目Peer Header Number字段和报文序列号Sequence Number字段;每个所述Peer Header包括邻居类型Peer Type字段、邻居标识Peer Flags字段、RD字段、本地自治系统Local AS字段、邻居地址Peer Address字段、邻居自治系统Peer AS字段和邻居BGP标识Peer BGP ID字段。
- 一种路由信息监控系统,其特征在于,包括:网络设备和控制器,其中,所述网络设备,用于执行上述权利要求1至11以及权利要求22至25任一项所述的路由信息监控方法;所述控制器,用于执行上述权利要求12至21任一项所述的路由信息监控方法。
- 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质中存储有指令,当其在计算机上运行时,使得所述计算机执行以上权利要求1至25任一项所述的路由信息监控方法。
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910691270.4A CN110191059B (zh) | 2019-07-29 | 2019-07-29 | 一种路由信息监控方法和装置 |
CN201910691270.4 | 2019-07-29 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2021018155A1 true WO2021018155A1 (zh) | 2021-02-04 |
Family
ID=67725875
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2020/105297 WO2021018155A1 (zh) | 2019-07-29 | 2020-07-28 | 一种路由信息监控方法和装置 |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN110191059B (zh) |
WO (1) | WO2021018155A1 (zh) |
Families Citing this family (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110191059B (zh) * | 2019-07-29 | 2019-12-13 | 华为技术有限公司 | 一种路由信息监控方法和装置 |
CN112822103B (zh) * | 2019-11-15 | 2022-09-23 | 华为技术有限公司 | 一种信息上报方法和信息处理方法及设备 |
CN113132227A (zh) * | 2019-12-30 | 2021-07-16 | 华为技术有限公司 | 更新路由信息的方法、装置、计算机设备和存储介质 |
CN113572685B (zh) * | 2020-04-29 | 2023-03-10 | 华为技术有限公司 | 一种信息上报方法、信息处理方法、装置及设备 |
CN116016315A (zh) * | 2020-05-25 | 2023-04-25 | 华为技术有限公司 | 一种路由管理方法、设备及系统 |
CN112671654B (zh) * | 2020-12-28 | 2022-09-27 | 北京东土军悦科技有限公司 | 路由信息更新方法、装置、设备、介质及ospf网络 |
CN114244734B (zh) * | 2021-11-19 | 2024-02-09 | 新华三技术有限公司合肥分公司 | 报文发送方法及装置 |
CN116437158B (zh) * | 2023-06-13 | 2023-09-01 | 浙江大华技术股份有限公司 | 视频传输方法、视频传输装置以及计算机可读存储介质 |
CN116760830B (zh) * | 2023-08-14 | 2024-03-01 | 腾讯科技(深圳)有限公司 | 路由信息的处理方法、装置、计算机可读介质及电子设备 |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102137002A (zh) * | 2010-12-01 | 2011-07-27 | 华为技术有限公司 | 边际网关协议负载分担的方法和装置 |
CN106487709A (zh) * | 2015-08-28 | 2017-03-08 | 中兴通讯股份有限公司 | 一种报文发送方法及系统 |
WO2018109536A1 (en) * | 2016-12-17 | 2018-06-21 | Telefonaktiebolaget Lm Ericsson (Publ) | Method and apparatus for monitoring virtual extensible local area network (vxlan) tunnel with border gateway protocol (bgp)-ethernet virtual private network (evpn) infrastructure |
CN110191059A (zh) * | 2019-07-29 | 2019-08-30 | 华为技术有限公司 | 一种路由信息监控方法和装置 |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100413290C (zh) * | 2005-11-11 | 2008-08-20 | 清华大学 | 设置边界网关协议路由选择通知功能的方法 |
JP4249210B2 (ja) * | 2006-08-24 | 2009-04-02 | 日本電信電話株式会社 | 経路数監視装置及び経路数監視方法ならびに経路数監視プログラム |
CN101056270B (zh) * | 2007-05-18 | 2010-10-06 | 华为技术有限公司 | 一种路由收敛的方法及路由设备 |
CN101076029B (zh) * | 2007-07-12 | 2011-05-11 | 中兴通讯股份有限公司 | 一种边界网关协议递归路由更新的方法 |
CN103581013B (zh) * | 2012-07-25 | 2017-02-15 | 杭州华三通信技术有限公司 | 实现路由协议的不中断路由的方法和装置 |
CN109246008B (zh) * | 2014-07-23 | 2021-08-20 | 华为技术有限公司 | 网络设备、系统和发送bgp信息的方法 |
CN106161256B (zh) * | 2016-07-26 | 2019-08-23 | 新华三技术有限公司 | 一种边界网关协议bgp路由的处理方法及装置 |
-
2019
- 2019-07-29 CN CN201910691270.4A patent/CN110191059B/zh active Active
-
2020
- 2020-07-28 WO PCT/CN2020/105297 patent/WO2021018155A1/zh active Application Filing
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102137002A (zh) * | 2010-12-01 | 2011-07-27 | 华为技术有限公司 | 边际网关协议负载分担的方法和装置 |
CN106487709A (zh) * | 2015-08-28 | 2017-03-08 | 中兴通讯股份有限公司 | 一种报文发送方法及系统 |
WO2018109536A1 (en) * | 2016-12-17 | 2018-06-21 | Telefonaktiebolaget Lm Ericsson (Publ) | Method and apparatus for monitoring virtual extensible local area network (vxlan) tunnel with border gateway protocol (bgp)-ethernet virtual private network (evpn) infrastructure |
CN110191059A (zh) * | 2019-07-29 | 2019-08-30 | 华为技术有限公司 | 一种路由信息监控方法和装置 |
Non-Patent Citations (1)
Title |
---|
J.SCUDDER.ED: "BGP Monitoring Protocol", IETF, 30 June 2016 (2016-06-30), XP055776440 * |
Also Published As
Publication number | Publication date |
---|---|
CN110191059B (zh) | 2019-12-13 |
CN110191059A (zh) | 2019-08-30 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2021018155A1 (zh) | 一种路由信息监控方法和装置 | |
EP4099631A1 (en) | Method for configuring performance test indication information, and related device | |
US11134009B2 (en) | Packet processing method and apparatus | |
WO2021093465A1 (zh) | 发送报文、接收报文以进行oam的方法、装置及系统 | |
CN113114509B (zh) | 一种在sdn网络环境中进行报文转发仿真的方法及设备 | |
KR20140106235A (ko) | 오픈플로우 스위치 및 그 패킷 처리 방법 | |
US11882037B2 (en) | Entry processing method, network device, and control device | |
US10404544B2 (en) | Network topology determining method and apparatus, and centralized network status information storage device | |
JP5368473B2 (ja) | インターネットプロトコルサービス品質保証型ルータの自動設定 | |
US11805011B2 (en) | Bulk discovery of devices behind a network address translation device | |
CN107645394B (zh) | 一种sdn网络中的交换机配置方法 | |
EP4080850A1 (en) | Onboarding virtualized network devices to cloud-based network assurance system | |
CN112751701B (zh) | 用于管理网络装置的系统、方法及计算机可读介质 | |
WO2018177003A1 (zh) | 一种计费方法、相关设备和系统 | |
CN115801674A (zh) | 双栈的sdn控制方法、装置、介质以及系统 | |
CN114531392A (zh) | 组播业务设计方法、服务器及存储介质 | |
CN105765903A (zh) | 一种拓扑发现方法及设备 | |
EP4213457A1 (en) | Determining an organizational level network topology | |
CN104967539A (zh) | 一种无线mesh网络管理信息数据的获取方法 | |
EP2890053B1 (en) | Ds domain generating method and system | |
CN114024895B (zh) | 一种基于tr069的网络路线优化方法和系统 | |
JP6932118B2 (ja) | パケット処理方法および装置 | |
WO2021238699A1 (zh) | 一种配置网络设备ip地址的方法及相关设备 | |
CN116455759A (zh) | 确定组织级网络拓扑 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 20847497 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 20847497 Country of ref document: EP Kind code of ref document: A1 |