Disclosure of Invention
Aiming at the defects that network fault troubleshooting and solution can be carried out only by means of network sniffing, exchanger log checking and the like and early warning cannot be carried out in advance to avoid loss in the prior art, the invention provides the following technical scheme:
one aspect of the present invention provides a network fault early warning method, including:
acquiring operation data of a target switching network node in a current network;
training an artificial neural network model according to the operation data of the target switching network node;
and predicting the fault probability of the target switching network node according to the trained artificial neural network model and the real-time collected operation data of the current network.
Optionally, the obtaining operation data of the target switching network node in the current network includes:
and acquiring the running log of the target switching network node and the network flow data of the terminal node in the current network.
Optionally, the training an artificial neural network model according to the operation data of the target switching network node includes:
and respectively training an artificial neural network model of each target switching network node, an artificial neural network model of each area network of the current network and a whole artificial neural network model of the current network according to the operation data of the target switching network nodes.
Optionally, the method further comprises:
and displaying the predicted fault probability of the target switching network node through a display device so as to realize key monitoring on the target switching network node predicted to have a fault.
Optionally, the training an artificial neural network model according to the operation data of the target switching network node includes:
and updating the artificial neural network prediction model according to the real-time acquired operation data of the target switching network node in the current network.
On the other hand, the invention also provides a network fault early warning device, which comprises:
the data acquisition unit is used for acquiring the operation data of the target switching network node in the current network;
the model training unit is used for training an artificial neural network model according to the operation data of the target switching network nodes;
and the fault prediction unit is used for predicting the fault probability of the target switching network node according to the trained artificial neural network model and the real-time acquired operation data of the current network.
Optionally, the data obtaining unit is specifically configured to obtain an operation log of the target switching network node and network traffic data of the terminal node in the current network.
Optionally, the model training unit is specifically configured to respectively train an artificial neural network model of each target switching network node, an artificial neural network model of each area network of the current network, and an artificial neural network model of a whole network of the current network according to the operation data of the target switching network node.
Optionally, the apparatus further comprises:
and the device display unit is used for displaying the predicted failure probability of the target switching network node through a display device so as to realize key monitoring on the target switching network node with the predicted failure.
Optionally, the model training unit is further configured to:
and updating the artificial neural network prediction model according to the real-time acquired operation data of the target switching network node in the current network.
According to the network fault early warning method and device, the operation data of the target switching network node in the current network is obtained, the artificial neural network model is trained according to the operation data of the target switching network node, the fault probability of the target switching network node is predicted according to the trained artificial neural network model and the operation data of the current network collected in real time, the fault of the switching node can be predicted according to the operation data of each node in the network, the artificial neural network model is trained and updated through a self-adaptive method, the prediction precision of the fault rate of each switching node in the current network can be improved, early fault early warning is achieved, and loss is avoided.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some embodiments, but not all embodiments, of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a schematic flow chart of a network fault early warning method according to an embodiment of the present invention; as shown in fig. 1, the method includes:
s1: acquiring operation data of a target switching network node in a current network;
specifically, the processor may obtain an operation log file of all network nodes in the current network, where the log file may include an operation log of the terminal node, an operation log of the switching node, and other information for recording the operation state of the device.
The collected log files can be stored in a non-cached and permanent storage area of the corresponding node or a preset log server, and the log information of the whole network is permanently stored.
S2: training an artificial neural network model according to the operation data of the target switching network node;
specifically, the processor trains an artificial neural network model according to the operation data of the target switching network node, and the specific method includes:
and respectively training an artificial neural network model of each target switching network node, an artificial neural network model of each area network of the current network and a whole artificial neural network model of the current network according to the operation data of the target switching network nodes.
The feedforward part adopts two layers of networks to approximate;
it is understood that the above trained neural network models of various types may include a prediction model for a single switching node outputting a failure probability of a target switching node in a state; the system also comprises a prediction model used for outputting the fault probability of a certain local network; and a prediction model for outputting the state that the whole network fails, and the like.
It should be noted that the method of this embodiment includes updating all the prediction models adaptively, that is, updating all the prediction models periodically according to data such as a continuously accumulated historical log file.
S3: and predicting the fault probability of the target switching network node according to the trained artificial neural network model and the real-time collected operation data of the current network.
Specifically, the processor predicts the failure probability of the target switching network node according to the trained artificial neural network model and the real-time collected operation data of the current network.
Specifically, the processor may perform weighted calculation on the prediction results of the various types of artificial neural network prediction models, so as to obtain the operation state of the switching node that needs to be monitored intensively through comprehensive calculation. Further, as a preference of this embodiment, the method may further include:
and displaying the predicted fault probability of the target switching network node through a display device so as to realize key monitoring on the target switching network node predicted to have a fault.
For example, the processor may display the predicted failure probability of the target switching network node through a display device of a terminal through functions of mail push, mobile app push, and the like.
According to the network fault early warning method, the operation data of the target switching network node in the current network is obtained, the artificial neural network model is trained according to the operation data of the target switching network node, the fault probability of the target switching network node is predicted according to the trained artificial neural network model and the operation data of the current network collected in real time, the fault of the switching node can be predicted according to the operation data of each node in the network, the artificial neural network model is trained and updated through a self-adaptive method, the prediction precision of the fault rate of each switching node in the current network can be improved, early fault early warning is achieved, and loss is avoided.
Fig. 2 is a schematic structural diagram of a network fault early warning apparatus according to an embodiment of the present invention; as shown in fig. 2, the apparatus includes a data acquisition unit 11, a model training unit 12, and a failure prediction unit 13, wherein:
the data obtaining unit 11 is configured to obtain operation data of a target switching network node in a current network;
the model training unit 12 is configured to train an artificial neural network model according to the operation data of the target switching network node;
the fault prediction unit 13 is configured to predict a fault probability of the target switching network node according to the trained artificial neural network model and the operation data of the current network collected in real time.
Specifically, the data obtaining unit 11 obtains operation data of a target switching network node in a current network; the model training unit 12 trains an artificial neural network model according to the operation data of the target switching network node; the fault prediction unit 13 predicts the fault probability of the target switching network node according to the trained artificial neural network model and the real-time collected operation data of the current network.
The apparatus described in this embodiment may be used to implement the above method embodiments, and the principle and technical effect are similar, which are not described herein again.
Further, as a preferable example of the foregoing apparatus, the data obtaining unit 11 may be specifically configured to obtain an operation log of the target switching network node and network traffic data of the terminal node in the current network.
Further, as a preferred embodiment of the foregoing apparatus, the model training unit 12 is specifically configured to train, according to the operation data of the target switching network nodes, the artificial neural network models of the area networks of the current network, and the artificial neural network model of the whole network of the current network, respectively.
Further, as a preference of the above-mentioned apparatus embodiment, the apparatus may further include:
and the device display unit 14 is configured to display the predicted failure probability of the target switching network node through a display device, so as to implement key monitoring on the target switching network node predicted to have a failure.
Further, as a preferable example of the foregoing apparatus, the model training unit 12 may be further configured to update the artificial neural network prediction model according to operation data of a target switching network node in the current network, which is acquired in real time.
The apparatus described in this embodiment may be used to implement the above method embodiments, and the principle and technical effect are similar, which are not described herein again.
It should be noted that, for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and for the relevant points, reference may be made to part of the description of the method embodiment.
The present invention is described below with reference to a specific example, but the scope of the present invention is not limited thereto.
Fig. 3 is a schematic flowchart of a process of training a neural network model in a network fault early warning method according to another embodiment of the present invention, as shown in fig. 3, the process includes:
step 1: collecting data and training an artificial neural network model;
step 2: collecting network state data in real time, and inputting the data into a trained model to obtain the probability that all the switching nodes possibly have faults;
and step 3: the fixed point carries out key monitoring on the exchange node obtained by calculation and takes possible measures to avoid the influence on the whole network;
and 4, continuously updating various neural network prediction models.
Fig. 4 is a schematic structural diagram of a network fault warning apparatus according to another embodiment of the present invention; as shown in fig. 4, the apparatus includes: log collection unit 21, network traffic statistics unit 22, preprocessing unit 23, prediction calculation unit 24 and monitoring unit 25, wherein:
the log collection unit 21 may be configured to pull log files of all network nodes to the preprocessing unit 23; the log file can include running logs of the terminal node, running logs of the exchange node and other information of running states of all recording devices; the collected log files can be stored in a non-cached and permanent storage area of the node or a special log server is additionally arranged, and the log information of the whole network can be permanently stored;
the network traffic statistic unit 22 may be configured to record characteristics of network traffic of all terminal nodes, such as size and type, and separately store the recording result in a permanent storage area of all terminal nodes or an additional special log server;
the preprocessing unit 23 may be configured to calculate and process all data collected by the log collecting unit 21 and the network traffic statistical unit 22 into an input data matrix of the neural network, provide a training and testing sample data set for the above steps 1 and 4, and provide a prediction data set for the step 2;
specifically, the preprocessing unit 23 can re-encode all available data to obtain a data set format with balanced performance and speed.
The mode of pushing data to the neural network model by the preprocessing unit 23 supports a real-time processing mode, an offline processing mode, and the like.
The prediction computation unit 24 may be used to train an artificial neural network model (see fig. 5) and predict the failure rate of the switching node using the artificial neural network model.
Specifically, the prediction calculation unit 24 establishes respective neural network models for all the switching nodes to perform prediction;
further, the feedforward network of the neural network model uses a continuous function to characterize all possible output states, and the feedforward part uses a two-layer network to perform approximation.
Specifically, fig. 6 shows a prediction flow in the network fault early warning method according to another embodiment of the present invention, as shown in fig. 6, the prediction calculation unit 24 may train multiple types of neural network models, for example, a prediction model of a single switching node for outputting a fault probability of a switching node as an output state; the prediction model is used for outputting the fault probability of a local network in a state; and a prediction model for outputting the state that the whole network fails, and the like.
Preferably, the prediction calculation unit 24 may dynamically and adaptively update all trained prediction models, that is, periodically update all the prediction models according to the continuously accumulated historical log files and the network traffic statistical information.
The monitoring unit 25 may be configured to perform weighted calculation on the results of the various types of prediction models to obtain the switching nodes that need to be monitored intensively and monitor the operating states of the unit modules.
Preferably, the monitoring unit 25 has functions of platform display, mail pushing, mobile app pushing, and the like.
According to the network fault early warning method and device provided by the embodiment of the invention, communication faults of network switching nodes such as switches and routers under normal equipment conditions are early warned according to log files and network flow information, characteristic scale transformation can be carried out after equipment and communication network data are obtained, the probability of the communication faults of the switching nodes and the network can be predicted by training various types of neural network prediction models, and key equipment or network areas which are possible to have faults can be obtained through joint calculation.
The above examples are only for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.