A network troubleshooting method and device based on SDN

By using the SDN controller for service monitoring and connectivity analysis, the problem of low efficiency in traditional network fault diagnosis has been solved, achieving the effect of quickly locating fault points and improving troubleshooting efficiency.

CN119383112BActive Publication Date: 2025-12-12INSPUR NETWORK TECH (SHANDONG) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411501506.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-25
Publication Date
2025-12-12
Estimated Expiration
2044-10-25

AI Technical Summary

Technical Problem

Traditional network fault diagnosis methods lack full-network, real-time monitoring, resulting in low diagnosis efficiency, inability to quickly locate fault points, and excessively long fault duration.

Method used

An SDN-based network fault diagnosis method is adopted. The service monitoring function is enabled through the SDN controller, the service path information is obtained by using the track operation, and the connectivity analysis is performed by combining the ping operation. The service status is monitored in real time and fault prompt information is generated when a fault occurs.

Benefits of technology

It enables rapid and accurate location of network faults, improves troubleshooting efficiency, reduces manpower consumption, and shortens fault recovery time.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119383112B_ABST
    Figure CN119383112B_ABST
Patent Text Reader

Abstract

The application discloses a network troubleshooting method and device based on SDN, and the method comprises the following steps: enabling the service monitoring function of a specified service by an SDN controller, and searching for the mounting switch of the service IP of the specified service; acquiring the per-hop information returned by the track operation between the source host and the destination host according to the mounting switch, performing path analysis on the per-hop information, and determining the service path information of the specified service; performing the ping operation between the source host and the destination host according to the mounting switch within a preset service monitoring period; acquiring the ping operation results of the source host and the destination host within a set time length, performing connectivity analysis on the ping operation results, and determining whether the specified service has network failure; and determining the fault prompt information of the specified service according to the service path information when the specified service has network failure. Through the steps, the fault point can be quickly located, and the troubleshooting efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of network fault, and particularly relates to a network fault locating method and device based on SDN. BACKGROUND

[0002] In the wave of digital era, the rapid progress of network technology brings about the proliferation of data centers. These data centers not only are numerous in quantity, but also run increasingly complex businesses, which puts forward higher requirements on manpower and technical level of operation and maintenance team.

[0003] Nowadays, the traditional network fault locating method lacks full-network and full-time monitoring, and the user-side problem is prominent, which leads to low efficiency of troubleshooting. The method cannot assist operation and maintenance personnel to quickly locate the fault point when a sudden event occurs, thereby leading to too long fault time. SUMMARY

[0004] Embodiments of the present application provide a network fault locating method and device based on SDN, which are used to solve the problem of how to quickly locate the fault point when a sudden event occurs.

[0005] Embodiments of the present application adopt the following technical solutions:

[0006] In one aspect, the embodiments of the present application provide a network fault locating method based on SDN, which comprises: enabling a specified business service monitoring function by an SDN controller, finding a mounting switch of a business IP of a specified business; acquiring each hop information returned by a track operation between a source host and a destination host according to the mounting switch, performing path analysis on the each hop information, and determining business path information of the specified business; performing a ping operation between the source host and the destination host according to the mounting switch within a preset business monitoring period; acquiring multiple ping operation results of the source host and the destination host within a set time length, performing connectivity analysis on the multiple ping operation results, and determining whether the specified business appears network fault; and determining fault prompt information of the specified business according to the business path information when the specified business appears network fault.

[0007] In one example, the path analysis on the each hop information and the determination of the business path information of the specified business specifically comprises: determining a target switch IP, an interface and a port number of the target switch of each hop path; querying physical state and configuration parameter information of the interface of the target switch to obtain interface information; and determining the business path information of the specified business according to the target switch IP, the port number and the interface information of each hop path.

[0008] In one example, the determining the fault information of the specified service according to the service path information specifically comprises: extracting a target switch IP of each hop path from the service path information; obtaining a latest IP, latest interface information and latest port number of the target switch at a fault time according to the target switch IP; judging whether a latest interface physical state of each hop path is normal according to the latest interface information; if yes, comparing the latest IP of the target switch with the target switch IP to obtain an IP comparison result, comparing latest interface configuration parameter information with the interface configuration parameter information to obtain an interface configuration comparison result, and comparing the latest port number with the port number to obtain a port comparison result; and determining the fault prompt information of the specified service according to the IP comparison result, the interface configuration comparison result and the port comparison result.

[0009] In one example, the connectivity analysis on the multiple ping operation results to determine whether the specified service has network failure specifically comprises: determining whether the specified service has network failure according to whether a packet loss number of the multiple ping operation results is greater than a first preset number threshold; or determining whether the specified service has network failure according to whether a continuous packet loss number of the ping operation results exceeds a second preset number threshold.

[0010] In one example, after the determining the fault prompt information of the specified service according to the service path information, the method further comprises: generating the fault prompt information of the specified service, sending the fault prompt information to a user display interface; retrieving historical log information of a fault target switch within a historical time period before a fault time when receiving a log information query; highlighting a fault position in the historical log information; the fault position comprises at least one of a fault target switch IP, a fault interface and a fault port number; and sending the historical log information to the user display interface.

[0011] In one example, after the determining the fault prompt information of the specified service according to the service path information, the method further comprises: enabling a device monitoring function of a switch in a network environment, detecting a device state and log information of a monitored switch within a device monitoring period; generating device fault information of the monitored switch when the device state or the log information is abnormal, and sending the device fault information to a user display interface.

[0012] In one example, after the determination of the fault prompt information of the specified service according to the service path information, the method further comprises: enabling a link monitoring function of a switch in a network environment, detecting a link state of the corresponding switch in a link monitoring period; and determining the fault prompt information of the link when the link state changes, and sending the link fault prompt information to a user display interface.

[0013] In one example, the SDN controller enables the service monitoring function of the specified service, specifically comprising: the SDN controller receives service network information of the specified service, and sets service monitoring information of the specified service according to the service network information; the service network information comprises a service IP, a source host IP, a destination host IP and a port number; in the switches in the network environment, the network location of the mounted switch is closest to the destination host; in the network environment, the connectivity of the specified service is tested to determine whether the specified service is in an address reachable state; and when the specified service is in the address reachable state, the service monitoring function of the specified service is enabled.

[0014] In one example, before the SDN controller enables the service monitoring function of the specified service, the method further comprises: the SDN controller receives management information of a to-be-managed switch related to the specified service; the management information comprises switch basic configuration information and network topology structure information; the management information is verified, and after the verification is passed, the switch is managed according to the management information.

[0015] On the other hand, the embodiment of the present application provides a network troubleshooting device based on SDN, comprising: at least one processor; and a memory in communication connection with the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute any one of the above-mentioned network troubleshooting methods based on SDN.

[0016] The above-mentioned at least one technical solution adopted by the embodiment of the present application can achieve the following beneficial effects:

[0017] By enabling the service monitoring function of the specified service, the running state of the service can be monitored in real time or periodically, and by finding the mounted switch of the service IP, the specific location of the service in the network can be quickly determined, which facilitates quick positioning. Further, by track and ping operations, the service path information and whether the service path is reachable can be obtained, the network fault can be quickly determined when the service network is not reachable, and then the fault point can be located according to the path information of the service, so that the network troubleshooting efficiency can be improved. BRIEF DESCRIPTION OF DRAWINGS

[0018] In order to more clearly illustrate the technical solutions of the present application, some embodiments of the present application will be described in detail below with reference to the accompanying drawings, in which:

[0019] Figure 1 A flowchart of a network troubleshooting method based on SDN provided by an embodiment of the present application;

[0020] Figure 2 An architecture diagram of a network troubleshooting system based on SDN provided by an embodiment of the present application;

[0021] Figure 3 A structure diagram of a network troubleshooting device based on SDN provided by an embodiment of the present application. DETAILED DESCRIPTION

[0022] In order to make the purpose, technical solutions and advantages of the present application more clear, the technical solutions of the present application will be described clearly and completely below with reference to specific embodiments and corresponding drawings. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without making creative efforts fall within the scope of protection of the present application.

[0023] Some embodiments of the present application will be described in detail below with reference to the accompanying drawings.

[0024] Figure 1 A flowchart of a network troubleshooting method based on SDN provided by an embodiment of the present application. The method can be applied to different business fields, and some input parameters or intermediate results in the flow allow manual intervention to adjust to help improve accuracy.

[0025] In the wave of digital era, the rapid progress of network technology has brought about an explosive increase in the number of data centers. These data centers not only have a large number, but also have increasingly complex internal operations, which puts higher requirements on the manpower and technical level of the operation and maintenance team. In order to improve the operation and maintenance efficiency of the data center, most data centers have begun to use software-defined network (SDN) controllers. The SDN controller realizes the automation of operation and maintenance through software means, greatly reducing the work burden of operation and maintenance personnel. However, the introduction of the SDN controller is not only for automation, but also for intelligence. By integrating more SDN-related components, the SDN controller can further realize intelligent operation and maintenance on the basis of automation. This means that in the event of a sudden event, the SDN controller can assist the operation and maintenance personnel to quickly locate the fault point and collect the necessary information, thereby shortening the troubleshooting time and accelerating the recovery speed of the business. How to effectively realize this transformation has become an urgent problem faced by the operation and maintenance personnel of the data center.

[0026] The embodiment of the present application provides a network troubleshooting method and system based on SDN. The SDN controller is deployed in a data center, and a switch system is managed according to switch access information set in the SDN controller. A user can set service monitoring in the SDN controller, and performs real-time monitoring on a specific IP service. When detecting service abnormity, the SDN controller queries switch information, and gives corresponding fault prompt information. The user can quickly find log information related to the fault cause in the switch according to the fault prompt information in the SDN controller page. In addition, the user can also set device monitoring and link monitoring in the SDN controller, and the SDN gives corresponding fault prompt information according to the fault type, and assists the user to complete troubleshooting.

[0027] Figure 1 The flow in the method comprises the following steps:

[0028] S101: The SDN controller enables service monitoring function of a specified service, and finds a mounting switch of a service IP of the specified service.

[0029] In some embodiments of the present application, the SDN controller needs to complete the management of the switch. The management process is as follows: the SDN controller receives management information of a to-be-managed switch related to the specified service. The management information comprises switch basic configuration information and network topology structure information. Then, the management information is verified, and after verification, the switch is managed according to the management information.

[0030] Further, when the service monitoring function of the specified service is enabled, the connectivity of the specified service needs to be tested, that is, ping operation, so that the service monitoring function is enabled only when the address is reachable.

[0031] Therefore, the SDN controller receives service network information of the specified service, and sets service monitoring information of the specified service according to the service network information. The service network information comprises service IP, source host IP, destination host IP and port number. In the managed network environment, the network position of the mounting switch is closest to the destination host. In the managed network environment, the connectivity of the specified service is tested, and whether the specified service is in the address reachable state is judged. When the address is reachable, the service monitoring function of the specified service is enabled.

[0032] It should be noted that, to troubleshoot network, the core lies in deploying a powerful SDN controller in the data center, which can comprehensively and finely manage the switch system based on the preset switch access information. In order to achieve this goal, it is necessary to first establish a stable and efficient information channel between the SDN controller and the switch, which requires a series of preparatory work before the SDN controller starts to manage the switch devices in the data center, including but not limited to:

[0033] First, the statistics of switch management information is carried out, and the management addresses and management information (such as IP address, port number, management username and password, etc.) of all switches to be managed by the SDN controller are comprehensively counted to ensure the accuracy of the information; secondly, the physical link and management network are built, and the physical link and management network are built according to the statistical management information to ensure that the SDN controller and the switch can communicate smoothly; finally, the switch initialization configuration is carried out, and the necessary initialization configuration is completed on the switch: configuring the management IP, enabling the SSH or SNMP protocol, so that the SDN controller can securely and reliably connect to the switch through these protocols.

[0034] Since the switch does not have a switch IP, the switch closest to the destination host is used as the mounting switch, and in the data transmission process, even if the switch does not have a switch IP, the business path of the switch can be tracked. Conversely, if the mounting host is in the middle of the network position of the switch, the switches in front and behind which do not have switch IPs may be ignored, resulting in an incomplete business path. In addition, the relationship between interfaces, ports and IPs, a switch has multiple interfaces, an interface has multiple ports, and an IP is in a port.

[0035] After the above preparatory work is completed, the user can access the web management page of the SDN controller through the PC. In this page, the user can conveniently input the management information of the switch previously counted, including the management network IP reachable by the SDN controller, the management username and password, the SNMP related configuration, etc. After receiving this information, the SDN controller will immediately verify the input information through SSH or SNMP, and once the verification is passed, the SDN controller will save the management information of these switches to its own database. In this way, in the subsequent use process, the SDN controller can flexibly regulate the network according to the saved device management information, and real-time obtain the state information of the switch. At this time, the SDN controller has completed the management of the switch in the data center.

[0036] The business monitoring function is a key function of the SDN controller. When there is a part of key business in the network, the business monitoring function can be set to ensure that the business can be found and quickly repaired to restore the business when the business fails. The user can set the business monitoring function according to the actual business information, such as the business access device, source IP, destination IP and port number information through the front-end interface of the SDN controller. The steps of setting the business monitoring are as follows: the user needs to log in to the management interface of the SDN controller through a browser or other client tools. In the management interface of the SDN controller, find and click the "business monitoring" or similar configuration item, enter the setting page of the business monitoring, and then set the business monitoring rule. First, the ID or name of the network device accessed by the business to be monitored needs to be selected or input. The source IP address needs to be specified. The source IP address of the business to be monitored can be a single IP address or an IP address segment. The destination IP address needs to be specified. The destination IP address of the business to be monitored can be a single IP address or an IP address segment. The port number needs to be specified. The network port number used by the business can be a single port number or a port range. Then, a monitoring threshold is set. According to the business demand, the threshold of monitoring is set, such as bandwidth utilization, delay time, packet loss rate, etc. When these indicators exceed the preset threshold, the system will trigger an alarm. After the above settings are completed, click the save or apply button to save the business monitoring rule to the SDN controller. After the business monitoring is set, the SDN controller will detect the connectivity of the business information. If the current set business information is in the address reachable state, the monitoring of the business is enabled.

[0037] When determining the business monitoring rule, the following key factors need to be considered: first, the business demand. According to the importance and sensitivity of the business, the indicators and thresholds to be monitored are determined. For example, for a business with extremely high real-time requirements, lower delay and packet loss rate thresholds may need to be set. Second, the network status. The actual running status of the network, such as bandwidth capacity and device performance, is considered to ensure that the monitoring rule set is neither too loose to detect potential problems in time nor too strict to cause frequent false alarms. Then, historical data can also be considered. If possible, the running data of similar businesses in the past can be referred to in combination with historical data to set reasonable monitoring thresholds. Finally, dynamic adjustment can also be considered. As the network environment and business demand change, the monitoring rule also needs to be dynamically adjusted. The SDN controller should support the user to modify and update the monitoring rule at any time to adapt to the changing network environment.

[0038] S102: According to the mounting switch, the per-hop information returned by the track operation between the source host and the destination host is obtained, the per-hop information is analyzed, and the business path information of the specified business is determined.

[0039] In some embodiments of the present application, the SDN controller adopts a track technology to obtain path information between services. Through a track operation initiated by an access device, the SDN controller can collect information of each hop through which traffic passes, thereby accurately depicting the traffic path of the service. The information includes not only the IP address of each hop, but also further refines to the specific device interface type (such as a router interface or a VLAN interface), and the physical state and configuration details of the interface. The SDN controller stores all the information in its own database for use in subsequent fault analysis.

[0040] Based on this, first, the target switch IP to which each hop path belongs, the interface of the target switch, and the port number are determined. Then, the physical state and configuration parameter information of the interface where the target switch is located are queried to obtain the interface information. Finally, according to the target switch IP, the port number, and the interface information of each hop path, the service path information of the specified service is determined.

[0041] S103: In a preset service monitoring period, according to the mounting switch, a ping operation between the source host and the destination host is controlled.

[0042] In some embodiments of the present application, a user sets up service monitoring based on the access device IP, source IP, destination IP, and port number information of a service. After service monitoring, the SDN controller initiates a ping operation periodically according to the location information of the service access device, using the preset source IP address, destination IP address, and port number.

[0043] S104: Obtain multiple ping operation results of the source host and the destination host within a set time length, perform connectivity analysis on the multiple ping operation results, and determine whether the specified service has a network fault.

[0044] When determining whether the specified service has a network fault, whether the number of packet loss in the multiple ping operation results is greater than a first preset number threshold is determined to determine whether the specified service has a network fault. That is, when greater, it is determined that a network fault occurs. Or, when the number of consecutive packet loss in the ping operation result is greater than a second preset number threshold, it is determined whether the specified service has a network fault. That is, when greater, it is determined that a network fault occurs.

[0045] It should be noted that the connectivity of the service is continuously detected by periodically initiating the ping operation, that is, the SDN controller connects to the access device (the managed switch) set in the service monitoring through ssh and the like, the periodicity of the ping operation is set as 1 second by default, and the parameters thereof include the source and destination addresses and the specific port number used, thereby ensuring the real-time and effectiveness of the monitoring. The SDN controller also sets strict fault determination criteria in the ping operation. It should be further noted that if there are more than 5 packet losses within 1 minute or no response is received for 5 consecutive seconds, the SDN controller determines that the service has failed and records the time at which the failure occurs. Such a design ensures the sensitivity of fault detection and avoids false positives due to occasional network fluctuations.

[0046] S105: When the specified service has a network failure, determining the fault prompt information of the specified service according to the service path information.

[0047] In some embodiments of the present application, when the monitoring service set in the service monitoring function of the SDN controller has a failure, that is, the ping detection is abnormal, the SDN controller will query the vlan and routing interface state in the path according to the service path information saved in advance, confirm whether the state is normal, and compare whether the interface configuration is changed. In addition, if the interface is a vlan interface, it will also query whether the vlan configuration and the vlan corresponding physical interface state are changed, and whether the configuration is changed. If the device enables the spanning tree function, it will also query whether the vlan spanning tree interface state is in the forwarding state.

[0048] As described above, if the port state is abnormal, the configuration information is changed, or the spanning tree corresponding interface state is not in the forwarding state, the corresponding information is returned according to the corresponding situation, and the corresponding prompt is given in the front-end interface of the SDN controller, prompting the user that the state, configuration or spanning tree of the specific device in the path is abnormal, and the corresponding prompt information is given.

[0049] The specific steps are as follows: from the determined service path information, the IP address of the target switch passed through by each hop (i.e. each step of transmission) is extracted. These IP addresses represent the switches involved in the service path; for each extracted target switch IP, the latest state information of the switch at the time of the fault is queried. This includes the latest IP address (although the IP address usually does not change frequently, this step is to ensure the accuracy of the information), the latest interface information (including the physical state and configuration parameters), and the latest port number; according to the obtained latest interface information, first, it is judged whether the interface physical state of the switch on each hop path is normal. If the physical state of an interface is abnormal (such as disconnected, fault, etc.), the point can be directly taken as one of the fault points; if the interface physical state is normal, further comparison is made as follows: the latest IP address of the target switch is compared with the IP address recorded in the service path information to obtain the IP comparison result. The latest interface configuration parameter information is compared with the interface configuration parameter information recorded in the service path information to obtain the interface configuration comparison result; the latest port number is compared with the port number recorded in the service path information to obtain the port comparison result; according to the analysis result, the fault prompt information is generated, which should clearly indicate the fault reason of the fault point.

[0050] The user can understand the monitoring service fault reason of the current fault to some extent according to the prompt information given by the front-end interface of the SDN controller. If more fault information is needed, the user can select the fault prompt information item on the front-end interface of the SDN controller and click the log information query.

[0051] When the SDN controller receives the log information query, the historical log information of the fault target switch within a historical time length before the fault time is searched. In the historical log information, the fault position is highlighted; wherein the fault position includes at least one of the fault target switch IP, the fault interface, and the fault port number. The historical log information is sent to the user display interface.

[0052] For example, the SDN controller displays the switch log information from 5 minutes before the recorded fault occurrence time to the query on the front-end page according to the selected fault information, and highlights the fault IP, VLAN, interface number and other information, so as to facilitate the user to check the fault according to the fault information. The user can also customize the time period to collect the required log information.

[0053] In addition, the user can also configure the device monitoring and link monitoring functions in the troubleshooting assistant function of the SDN controller according to the actual needs.

[0054] The SDN controller enables the device monitoring function of the switches in the network environment. In the device monitoring period, the device state and log information of the monitored switch are detected. When the device state or the log information is abnormal, the device fault information of the monitored switch is generated, and the device fault information is sent to the user display interface.

[0055] It should be noted that the user sets the managed switch device as the device monitoring object in the front-end interface of the SDN controller. The SDN controller obtains the device state and log information through the managed information. When a high-priority log or device state abnormality (such as failure to connect) occurs, the SDN controller generates corresponding prompt information according to the log information or the current abnormal device state, to assist the user in completing troubleshooting.

[0056] In addition, the SDN controller enables the link monitoring function of the switches in the network environment. In the link monitoring period, the link state of the corresponding switch is detected. Then, when the link state changes, the link fault prompt information is determined, and the link fault prompt information is sent to the user display interface.

[0057] It should be noted that after the switches in the network are managed, the SDN controller enables the LLDP related function in the switches, and obtains the LLDP neighbor information. According to the LLDP information, the network topology diagram is generated in the front-end interface. When the user needs to monitor some key links, the link information obtained by the LLDP can be selected in the front-end interface of the SDN controller, and the link is set as the link monitoring object. The SDN controller connects the two end switch devices of the link through the managed information, and periodically detects the link state. If the link state changes, corresponding prompt information is generated, and the related log information during the change is collected, which is displayed in the front-end interface of the SDN controller, to assist the user in completing troubleshooting.

[0058] It should be noted that although the embodiments of the present application are introduced and described in sequence with reference to Figure 1 steps S101 to S105, this does not mean that steps S101 to S105 must be executed in strict sequence. The embodiments of the present application introduce and describe steps S101 to S105 in sequence as shown in Figure 1 in order to facilitate the understanding of the technical solution of the embodiments of the present application by those skilled in the art. In other words, in the embodiments of the present application, the sequence of steps S101 to S105 can be adjusted as needed.

[0059] Through Figure 1The method can set service monitoring in the SDN controller, determine service path information and ping threshold according to per-hop information returned by the track operation, and determine whether the service has network failure, so as to greatly improve the speed and accuracy of locating the fault point, and greatly reduce the consumption of manpower compared with other traditional methods.

[0060] In addition, the device monitoring and the link monitoring are configured, device abnormalities can be found in time, so that potential network failures can be quickly located and solved, the influence of the failures is avoided from being expanded, and possible failures can be predicted by analyzing device states and log information, and measures can be taken in advance for prevention.

[0061] The link monitoring function can quickly locate the fault link, generate fault prompt information, help the operation and maintenance personnel to quickly eliminate the fault, and understand the change of the network topology, so as to optimize the network structure and improve the efficiency and reliability of the network.

[0062] More intuitively, Figure 2 An architecture schematic diagram of a network troubleshooting system based on SDN is provided for the embodiments of the present application.

[0063] In Figure 2 , the SDN controller is used to manage the switches, the SDN controller includes an SDN web front-end interface, an SDN controller, and an SDN database.

[0064] The SDN database is used to store per-hop information, the front-end interface is used to display fault information, the SDN controller is used to centrally manage and control the devices, links and other resources in the network, monitor the state and traffic of the network in real time, and provide rich troubleshooting tools and functions.

[0065] Figure 3 An architecture schematic diagram of a network troubleshooting device based on SDN is provided for the embodiments of the present application, which includes:

[0066] at least one processor; and

[0067] a memory in communication connection with the at least one processor; wherein

[0068] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the network troubleshooting method based on SDN according to any one of the above.

[0069] Some embodiments of the present application provide a non-volatile computer storage medium based on SDN, which stores computer executable instructions, and the computer executable instructions can execute the network troubleshooting method based on SDN according to any one of the above.

[0070] The various embodiments in this application are described in a progressive manner, and the same or similar parts among the various embodiments can be referred to each other. Each embodiment focuses on the difference from other embodiments. In particular, the device and medium embodiments are described simply because they are basically similar to the method embodiments, and the relevant parts can be referred to the description of the method embodiments.

[0071] The device and medium provided by the embodiments of the present application are one-to-one corresponding to the method, and therefore, the device and medium also have the similar beneficial technical effects as the method. Since the beneficial technical effects of the method have been described in detail above, the beneficial technical effects of the device and medium will not be described here.

[0072] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROMs, optical storage media, etc.) containing computer-usable program code.

[0073] The present application is described with reference to flowcharts and / or block diagrams of the method, device (system), and computer program product according to the embodiments of the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of the flows and / or blocks in the flowcharts and / or block diagrams can be implemented by computer program instructions. These computer program instructions can be provided to a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing apparatus to produce a machine, so that the instructions executed by the computer or other programmable data processing apparatus produce the functions described in the flowcharts and / or block diagrams. Figure 1 The functions specified in one or more flows and / or blocks Figure 1 The means for performing the functions specified in one or more blocks.

[0074] These computer program instructions can also be stored in a computer-readable memory that can direct the computer or other programmable data processing apparatus to work in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including instruction means, which implements the functions described in the flowcharts and / or block diagrams. Figure 1 The functions specified in one or more flows and / or blocks Figure 1 The means for performing the functions specified in one or more blocks.

[0075] These computer program instructions can also be loaded into a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart block or blocks. Figure 1 Figure 1

[0076] In one typical configuration, the computing device includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.

[0077] The memory can include non-persistent memory and / or volatile memory, such as random access memory (RAM) about which the processor can execute instructions. The memory can also include non-volatile memory, such as read only memory (ROM), electrically programmable read only memory (EPROM), electrically erasable programmable read only memory (EEPROM), programmable read only memory (PROM), erasable programmable read only memory (EPROM), flash memory, or a combination of non-volatile memories in different types. The memory is an example of computer readable storage media.

[0078] Computer readable media includes permanent and non-permanent, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), electrically programmable read only memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital versatile disc (DVD), or other optical storage, magnetic cassette, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information accessible to computing devices. According to the definition herein, computer readable media does not include transitory media, such as modulated data signals and carrier waves.

[0079] It should also be noted that the terms "comprising", "containing", or any other variant thereof are intended to encompass a non-exclusive inclusion, such that a process, method, article or apparatus that comprises a list of elements does not include only those elements recited, but can also include other elements not expressly listed or inherent to such process, method, article or apparatus. Without further limitation, an element defined by the statement "comprising a" does not exclude the presence of additional identical elements in the process, method, article or apparatus that includes the element.

[0080] ​​The above merely provides an example of the present application, and is not intended to limit the present application. Any modification, equivalent replacement, improvement, etc. within the technical principles of the present application should fall into the protection scope of the present application.

Claims

1. A method for network troubleshooting based on SDN, characterized in that, The method comprises: The SDN controller enables the service monitoring function of the specified service, and finds the mounting switch of the service IP of the specified service; in the switches of the network environment, the network location of the mounting switch is closest to the destination host; According to the mounting switch, the per-hop information returned by the track operation between the source host and the destination host is obtained, the per-hop information is analyzed, and the service path information of the specified service is determined; In a preset service monitoring period, according to the mounting switch, the ping operation between the source host and the destination host is controlled; The multiple ping operation results of the source host and the destination host within a set time length are obtained, the connectivity of the multiple ping operation results is analyzed, and whether the specified service has network failure is determined; When the specified service has network failure, the fault prompt information of the specified service is determined according to the service path information; The per-hop information is analyzed, and the service path information of the specified service is determined, specifically comprising: Determine the target switch IP, interface and port number of each hop path; Query the physical state and configuration parameter information of the interface of the target switch to obtain the interface information; According to the target switch IP, port number and interface information of each hop path, the service path information of the specified service is determined; According to the service path information, the fault information of the specified service is determined, specifically comprising: Extract the target switch IP of each hop path from the service path information; According to the target switch IP, the latest IP, latest interface information and latest port number of the target switch at the fault time are obtained; According to the latest interface information, it is judged whether the latest interface physical state of each hop path is normal; If yes, compare the target switch latest IP with the target switch IP to obtain the IP comparison result, compare the latest interface configuration parameter information with the interface configuration parameter information to obtain the interface configuration comparison result, and compare the latest port number with the port number to obtain the port comparison result; According to the IP comparison result, interface configuration comparison result and port comparison result, the fault prompt information of the specified service is determined; According to whether the packet loss number of the multiple ping operation results is greater than a first preset number threshold, whether the specified service has network failure is determined; or According to whether the continuous packet loss number of the ping operation result exceeds a second preset number threshold, whether the specified service has network failure is determined. After determining the fault prompt information of the specified service according to the service path information, the method further comprises:

2. The method of claim 1, wherein, Generate the fault prompt information of the specified service, and send the fault prompt information to the user display interface; When receiving the log information query, retrieve the historical log information of the fault target switch within a historical time length before the fault time; ​ The history log information is highlighted to show a fault position, and the fault position includes at least one of a fault target switch IP, a fault interface, and a fault port number. The history log information is sent to the user display interface.

3. The method of claim 1, wherein, After the fault prompt information of the specified service is determined according to the service path information, the method further includes: Enabling a device monitoring function of a switch in a network environment, detecting a device state and log information of the monitored switch in a device monitoring period; When the device state or the log information is abnormal, generating device fault information of the monitored switch, and sending the device fault information to a user display interface.

4. The method of claim 1, wherein, After the fault prompt information of the specified service is determined according to the service path information, the method further includes: Enabling a link monitoring function of a switch in a network environment, detecting a link state of the corresponding switch in a link monitoring period; When the link state changes, determining link fault prompt information, and sending the link fault prompt information to a user display interface.

5. The method of claim 1, wherein, The SDN controller enables a service monitoring function of a specified service, and specifically includes: The SDN controller receives service network information of the specified service, and sets service monitoring information of the specified service according to the service network information; the service network information includes a service IP, a source host IP, a destination host IP, and a port number; In a network environment, connectivity of the specified service is tested to determine whether the specified service is in an address reachable state; When the specified service is in the address reachable state, the service monitoring function of the specified service is enabled.

6. The method of claim 1, wherein, Before the SDN controller enables the service monitoring function of the specified service, the method further includes: The SDN controller receives management information of a to-be-managed switch related to the specified service; the management information includes switch basic configuration information and network topology structure information; The management information is verified, and after verification, the switch is managed according to the management information.

7. An SDN-based network troubleshooting device, characterized by, It includes: At least one processor; And A memory connected in communication with the at least one processor; wherein The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the network troubleshooting method based on the SDN in any one of claims 1-6.

Citation Information

Patent Citations

  • Network failure positioning method and device

    CN101931982A