Data pre-synchronization method and device for network controller switching and electronic equipment
The data pre-synchronization method addresses network controller switching delays and inconsistencies by using AI to predict status changes and perform synchronized data transfer, enhancing network stability and reliability.
Patent Information
- Application Number
- CN202411526992.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-30
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-10-30
AI Technical Summary
Current redundant network controller systems experience delays in data synchronization during status changes, leading to data inconsistency and affecting network stability and reliability, with traditional switching methods triggered only after faults occur.
A data pre-synchronization method that predicts network status changes using historical data analysis and AI models to trigger early synchronization and rollback mechanisms, reducing delays and inconsistencies by intelligently synchronizing data before actual switching occurs.
The method improves network stability and reliability by predicting network status changes and performing synchronization in advance, ensuring data consistency and stability through intelligent pre-synchronization and rollback mechanisms.
Smart Images

Figure CN119254597A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of network controllers, and in particular to a data pre-synchronization method, device and electronic equipment for switching of network controllers. Background Art
[0002] In the current redundant network controller system, when the network status changes and the controller needs to be switched, there is often a delay in data synchronization, which may lead to the risk of data inconsistency and affect the stability and reliability of the network. At the same time, the switching of traditional network controllers is usually triggered after a fault occurs. This method cannot effectively reduce the delay and data inconsistency problems during switching. Summary of the invention
[0003] Based on this, it is necessary to provide a data pre-synchronization method, device and electronic device for network controller switching to address the problem that when the network status changes and the controller needs to be switched, there is often a delay in data synchronization, which may lead to the risk of data inconsistency and affect the stability and reliability of the network.
[0004] The present invention provides a data pre-synchronization method for network controller switching, the method comprising:
[0005] Obtain historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status, wherein the historical data includes information on network traffic patterns, data transmission delays, and error rates;
[0006] Based on the feature set, identify the network status and output the prediction result of the network status;
[0007] In response to the prediction result reaching the switching threshold, an early warning signal is output and a pre-synchronization mechanism is triggered;
[0008] In response to the network status being within a normal range or the controller switching not actually occurring, a rollback mechanism is triggered.
[0009] In one embodiment, the acquisition of historical data of network operation and extraction of features including traffic peak periods and node failure history include:
[0010] Obtain performance indicator data of key network nodes under monitoring;
[0011] Clean and format the historical data to obtain pre-processed historical data;
[0012] Analyze traffic patterns and identify peak traffic periods based on pre-processed historical data;
[0013] Analyze node failure history and output possible future failure points;
[0014] Perform mathematical transformation on the preprocessed historical data.
[0015] In one embodiment, the mathematical transformation of the pre-processed historical data includes:
[0016] Identify periodic signals of pre-processed historical data based on Fourier transform technology;
[0017] Or, basic statistics of the preprocessed historical data are calculated, where the basic statistics include a mean and a variance.
[0018] In one embodiment, the identifying the network state based on the feature set and outputting the prediction result of the network state includes:
[0019] Obtain a feature set representing the network state;
[0020] The feature set is input into an AI prediction model, and a prediction result of the network status is output. The AI prediction model is trained using samples of network status in normal operation and samples of network status in abnormal operation as training data.
[0021] In one embodiment, the AI prediction model is a time series model or a deep learning model, wherein the time series model is used to process data with strong linearity and periodicity, and the deep learning model is used to process complex data with long-term dependencies and nonlinear relationships.
[0022] In one embodiment, the triggering pre-synchronization mechanism includes:
[0023] Determine the data and status information that need to be synchronized;
[0024] Perform data synchronization, the calculation formula is as follows:
[0025] Data synchronization = f(primary node data, backup node),
[0026] Among them, f represents the synchronization function;
[0027] Verify the data of the backup node.
[0028] In one embodiment, the triggering rollback mechanism includes:
[0029] Stop the data synchronization process and roll back the backup database to the specified time point;
[0030] Update internal state management information and mark the data on the backup node as invalid or inactive;
[0031] Instruct the relevant network components and controllers to undo any switching actions triggered by the misprediction;
[0032] Record detailed information of the rollback operation, including triggering reasons, execution steps, and results;
[0033] Update the AI prediction model based on the cause of the error.
[0034] The present invention also provides a data pre-synchronization device for network controller switching, comprising:
[0035] An acquisition module is used to acquire historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status. The historical data includes information on network traffic patterns, data transmission delays, and error rates.
[0036] The recognition module is used to identify the network state based on the feature set and output the prediction result of the network state;
[0037] A response module, used to output a warning signal and trigger a pre-synchronization mechanism in response to the prediction result reaching the switching threshold;
[0038] The trigger module is used to trigger the rollback mechanism in response to the network status being within a normal range or the controller switching not actually occurring.
[0039] The present invention also provides an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, it implements the data pre-synchronization method for network controller switching as described in any one of the above.
[0040] The present invention also provides a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the data pre-synchronization method for switching a network controller as described in any one of the above is implemented.
[0041] The data pre-synchronization method, device and electronic device for network controller switching described above can reduce the risk of delay and data inconsistency during network controller switching by intelligently predicting changes in network status and performing data synchronization in advance, thereby improving the stability and reliability of the network. At the same time, by determining whether the network controller switching actually occurs and providing a remedial rollback mechanism, the status of the backup controller can be restored to the state before synchronization, thereby ensuring the data consistency and stability of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] In order to more clearly illustrate the technical solutions in the present invention or the prior art, a brief introduction is given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0043] Figure 1 A schematic flow chart of a data pre-synchronization method for network controller switching in one embodiment;
[0044] Figure 2 A schematic diagram of a feature extraction process in one embodiment;
[0045] Figure 3 A schematic diagram of a process of performing mathematical conversion on historical data in one embodiment;
[0046] Figure 4 A schematic diagram of a flow chart of identifying a network status in an embodiment;
[0047] Figure 5 A schematic diagram of a process of triggering a pre-synchronization mechanism in an embodiment;
[0048] Figure 6 A schematic diagram of a process of triggering a rollback mechanism in an embodiment;
[0049] Figure 7 A schematic diagram of the structure of a data pre-synchronization device for network controller switching in one embodiment;
[0050] Figure 8 The figure is a diagram showing the internal structure of an electronic device according to an embodiment. DETAILED DESCRIPTION
[0051] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0052] Combine the following Figure 1-Figure 8 The invention describes a data pre-synchronization method, device and electronic device for network controller switching.
[0053] like Figure 1 As shown, in one embodiment, a data pre-synchronization method for network controller switching includes the following steps:
[0054] Step S110, obtain historical data of network operation, and extract features including traffic peak period and node failure history to form a feature set representing the network status. The historical data includes information on network traffic pattern, data transmission delay and error rate.
[0055] Among them, network traffic patterns make it easy to understand the patterns of data flow within a specific time period, while data transmission delays and error rates can reflect the real-time health of the network.
[0056] Step S120, identifying the network status based on the feature set, and outputting the prediction result of the network status.
[0057] By intelligently predicting changes in network status, data synchronization can be performed in advance.
[0058] Step S130, in response to the prediction result reaching the switching threshold, outputting a warning signal and triggering a pre-synchronization mechanism.
[0059] By monitoring the prediction results, it is easier to react in advance, thereby reducing the delay when the network controller switches.
[0060] Step S140 , in response to the network status being within a normal range or the controller switching not actually occurring, triggering a rollback mechanism.
[0061] By determining whether the network controller switch actually occurs and providing a remedial rollback mechanism, the state of the backup controller is restored to the state before synchronization, thereby ensuring the data consistency and stability of the system.
[0062] The data pre-synchronization method for network controller switching can reduce the risk of delay and data inconsistency during network controller switching by intelligently predicting network status changes and performing data synchronization in advance, thereby improving the stability and reliability of the network. At the same time, by determining whether the network controller switching actually occurs and providing a remedial rollback mechanism, the state of the backup controller can be restored to the state before synchronization, thereby ensuring the data consistency and stability of the system.
[0063] In this embodiment, see Figure 2 , obtain the historical data of network operation and extract the features including the peak traffic period and node failure history, including the following steps:
[0064] Step S111, obtaining performance indicator data of key network nodes under monitoring.
[0065] By monitoring key nodes in the network, a series of performance indicator data can be collected, including but not limited to network traffic patterns, data transmission delays and error rates. Network traffic patterns make it easy to understand the patterns of data flow in a specific time period, while data transmission delays and error rates can reflect the real-time health of the network.
[0066] Step S112, cleaning and formatting the historical data to obtain pre-processed historical data.
[0067] By preprocessing historical data, it is convenient to ensure the quality of data input into the AI prediction model.
[0068] Step S113, analyzing the traffic pattern based on the pre-processed historical data and identifying the peak traffic period.
[0069] This helps predict cyclical changes in network load.
[0070] Step S114, analyzing the node failure history and outputting possible future failure points.
[0071] By using historical fault data to predict possible future fault points, the delay in network controller switching can be effectively reduced.
[0072] Step S115, performing mathematical transformation on the pre-processed historical data.
[0073] It is convenient to convert raw data into a format that can be recognized and learned by AI prediction models.
[0074] It is necessary to add that, see Figure 3 , mathematical transformation of the preprocessed historical data includes the following steps:
[0075] Step S116, identifying the periodic signal of the pre-processed historical data based on Fourier transform technology.
[0076] Fourier transform is a mathematical transformation that can convert a function from the time domain to the frequency domain. The Fourier transform technique decomposes a complex time domain signal into the sum of sine and cosine functions of different frequencies. Through Fourier transform, the distribution of the signal at different frequencies can be analyzed, which is very important for signal processing and image processing. For example, in signal processing, Fourier transform can help identify the noise components in the signal and remove them through filtering.
[0077] Or, step S117, calculating basic statistics of the preprocessed historical data, the basic statistics including mean and variance.
[0078] In the feature extraction process, we need to pay attention not only to the amount of data, but also to the quality and representativeness of the data. Through the above feature extraction method, we can get a set of feature sets that can represent the network status. These feature sets will be used as inputs of AI prediction models for training and predicting changes in network status.
[0079] For example, suppose that hourly traffic data of a network has been collected over the past month. By performing time series analysis on this data, it can be identified that the weekly traffic peak usually occurs on Wednesday and Friday afternoons. At the same time, by analyzing the node failure history, it is found that the failure of a specific node is usually associated with the peak traffic period. This information will be converted into features and input into the AI prediction model to improve the model's prediction accuracy for potential network status changes.
[0080] In this embodiment, see Figure 4 , based on the feature set, identify the network state and output the prediction result of the network state, including the following steps:
[0081] Step S121, obtaining a feature set representing a network state.
[0082] It should be noted that these feature sets are pre-processed historical data.
[0083] Step S122, input the feature set into the AI prediction model, and output the prediction result of the network status. The AI prediction model is trained using normal operating network status samples and abnormal operating network status samples as training data.
[0084] It should be noted that the AI prediction model is a time series model or a deep learning model. The time series model is used to process data with strong linearity and periodicity, while the deep learning model is used to process complex data with long-term dependencies and nonlinear relationships.
[0085] Time series models can capture trends and patterns of data changes over time, while deep learning models can learn complex data relationships through their multi-level feature extraction and abstraction capabilities. The key to selecting these models lies in their predictive capabilities, that is, their ability to accurately predict future network state changes based on historical data, thereby providing decision support for subsequent data pre-synchronization and controller switching.
[0086] According to the characteristics of network data, the applicability and prediction accuracy of different models are evaluated to select the appropriate AI prediction model.
[0087] Time series models: such as ARIMA (AutoRegressive Integrated Moving Average) and SARIMA (Seasonal AutoRegressive Integrated Moving Average), are suitable for linear and highly cyclical data.
[0088] Deep learning models: such as LSTM (Long Short-Term Memory) and GRU (Gated Recurrent Unit), are suitable for processing complex data with long-term dependencies and nonlinear relationships.
[0089] Taking the ARIMA model as an example, the ARIMA model is a classic statistical model for time series forecasting, which consists of three parts: autoregression (AR), difference (I) and moving average (MA).
[0090] Autoregressive (AR): The model uses past values of a time series to predict future values. The AR part specifies the number of past values that the model should consider and the impact of these values.
[0091] Difference (I): This step is to make a non-stationary time series stationary. A non-stationary time series is a series whose statistical properties (such as mean and variance) change over time. By differencing the series, it can be made more stationary and thus easier to predict.
[0092] Moving Average (MA): The model predicts future values using past forecast errors. The MA part specifies the impact of past forecast errors.
[0093] The ARIMA model is usually expressed as ARIMA(p,d,q), where p is the order of the autoregressive term, d is the number of differences, and q is the order of the moving average term.
[0094] Choosing appropriate values of p, d, and q is crucial to building an effective ARIMA model and is usually determined through a model identification process, which involves analyzing time series data using statistical methods (such as ACF and PACF plots) to determine the model parameters.
[0095]
[0096] Where: y t Represents the value of the time series at time point t; L is the lag operator, that is, L k y t =y t-k ; is the coefficient of the autoregressive term; p is the order of the autoregressive term; d is the number of differences, which is used to make the time series stable; θ1, θ2, …, θ q is the coefficient of the moving average term; q is the order of the moving average term; ∈ t is the white noise error term; c is the constant term.
[0097] The following is an example of an ARIMA model for predicting time series data (e.g., monthly peak traffic):
[0098] Data collection: Collect monthly peak traffic data over a period of time, for example, collect monthly peak traffic data for the past 3 years.
[0099] Data preprocessing: Make sure the time series data is stationary. If the data is not stationary, you can perform differentiation by following the steps below:
[0100] Compute the first difference: y t ′=y t -y t-1 If the data is still not stationary after the first-order difference, you can continue to calculate the second-order or higher-order difference.
[0101] Model Identification: Use the autocorrelation function (ACF) and partial autocorrelation function (PACF) to determine the parameters (p, d, q) of the ARIMA model.
[0102] Model establishment: The model is established according to the following ARIMA model formula:
[0103]
[0104] Parameter estimation: Use maximum likelihood estimation or other statistical methods to estimate model parameters θ1,θ2,…,θ q and c.
[0105] Model testing: The validity of the model is verified by performing a white noise test on the model residuals.
[0106] Forecasting: Use the established ARIMA model to make predictions of future values, for example:
[0107] Assuming there is an ARIMA(1,1,1) model, the prediction formula might be:
[0108]
[0109] Among them, y t ′ is the data after first-order difference, ∈ t is the error term for the previous period.
[0110] Results Evaluation: Evaluate the predictive performance of the model by comparing the predicted values with the actual observed values.
[0111] To ensure that the AI prediction model can reliably predict network controller switching scenarios, the following detailed training and validation process is required:
[0112] The model training is as follows:
[0113] Dataset preparation: First, the collected historical data of network operation is divided into a training set and a validation set after data preprocessing. The training set is used for the model training process, while the validation set is used to evaluate the prediction performance of the model.
[0114] Model configuration: According to the characteristics of the network data, configure the parameters of the AI prediction model, including the learning rate, batch size, and number of network layers, to optimize the training effect of the model. The following are the specific steps for model training:
[0115] Input feature processing: standardize or normalize feature data to meet the input requirements of the model.
[0116] Model iterative training: Use the following formula to iteratively train the model:
[0117]
[0118] Among them, θ represents the model parameters, α is the learning rate, and J(θ) is the loss function. is the gradient of the loss function with respect to the model parameters.
[0119] Loss function optimization: The loss function is used for iterative model training. If the iterative training is not good, you can choose other appropriate loss functions (such as mean square error MSE or cross entropy loss) to measure the difference between the predicted value and the actual value, and optimize the model parameters to minimize the loss.
[0120] The model validation is as follows:
[0121] Prediction performance evaluation: Use the validation set to validate the trained model.
[0122] The steps of the assessment are as follows:
[0123] Model prediction: Use the trained model to predict the data in the validation set.
[0124] Performance Indicator Calculation: The following performance indicators are calculated to evaluate the accuracy of the model:
[0125] Accuracy = number of correct predictions / total number of predictions,
[0126] Recall rate = number of correctly predicted positive samples / number of actual positive samples,
[0127] F1 score = 2(precision·recall) / (precision+recall).
[0128] Result analysis: Analyze the prediction results of the model to ensure that the model's accuracy, recall, and F1 score reach the predetermined thresholds to confirm the reliability of the model.
[0129] For example, a deep learning model is trained using a training set containing network status data from the past year. During the model training process, the learning rate is adjusted to 0.001, and the mean square error is used as the loss function. After 100 training cycles, the performance of the model is evaluated on the validation set. The results show that the model has an accuracy of 95%, a recall rate of 90%, and an F1 score of 92%, which indicates that the model has a high prediction reliability and can be used for actual network status prediction.
[0130] After completing the training and verification of the AI prediction model, the model is deployed in the network environment to achieve real-time monitoring of the network status and prediction of future status changes. The following are the specific implementation steps for real-time monitoring and prediction:
[0131] Model deployment: Integrate the trained AI prediction model into the network monitoring system to ensure that the model can continuously receive and process real-time network data streams.
[0132] Data flow monitoring: Real-time capture of data flows in the network, including but not limited to key performance indicators such as traffic, latency, and error rate.
[0133] Status analysis: The AI prediction model analyzes the captured data stream and makes status predictions through the following process:
[0134] Real-time data feature extraction: Extract key features from real-time data, including preprocessing of real-time data. These features should be consistent with the features used when training the model.
[0135] State prediction: Use the following formula to make predictions:
[0136]
[0137] in, is the network state predicted by the model, x is the feature vector of real-time data, and θ is the parameter of the model.
[0138] Prediction result processing: The model outputs the prediction result and determines whether there is a potential controller switching demand based on the preset threshold.
[0139] For example, an AI prediction model receives data updates of network performance indicators every minute. The model will immediately extract features from this data and predict changes in network status within the next 5 minutes. If the prediction results show that the network status will exceed the normal operating range, the model will output an early warning signal indicating that controller switching may be required. Such real-time monitoring and prediction mechanisms can take pre-synchronization measures before potential network problems occur, thereby improving network stability and reliability.
[0140] In this embodiment, see Figure 5, triggering the pre-synchronization mechanism, including the following steps:
[0141] Step S131, determining the data and status information that need to be synchronized.
[0142] These are usually the minimum data sets necessary to ensure continuous operation of the network.
[0143] Step S132, executing data synchronization, the calculation formula is as follows:
[0144] Data synchronization = f(primary node data, backup node),
[0145] Among them, f represents the synchronization function.
[0146] It can ensure that the data of the primary node is copied to the backup node.
[0147] Step S133, verifying the data of the backup node.
[0148] After synchronization is completed, the data integrity and consistency are ensured by verifying the data on the backup node.
[0149] The triggering condition of the pre-synchronization mechanism is: when the AI prediction model predicts that the network status is about to reach the switching threshold, it immediately sends a signal to trigger the pre-synchronization mechanism.
[0150] In this embodiment, see Figure 6 , triggering the rollback mechanism, including the following steps:
[0151] Step S141, stop the data synchronization process and roll back the backup database to a specified time point.
[0152] Restore the backup node's data to the state before pre-synchronization by using the previously created data snapshot or log.
[0153] Step S142: Update the internal status management information and mark the data on the backup node as invalid or inactive.
[0154] Convenient to ensure data consistency and system stability.
[0155] Step S143: instructing related network components and controllers to cancel any switching operation triggered by the wrong prediction.
[0156] Conveniently undo pre-sync and return to a stable state.
[0157] Step S144, recording detailed information of the rollback operation, including triggering reasons, execution steps and results.
[0158] This facilitates subsequent analysis and troubleshooting.
[0159] Step S145, updating the AI prediction model based on the cause of the error.
[0160] By updating the AI prediction model, similar prediction errors can be avoided in the future.
[0161] Monitoring switchover decisions: The system continuously monitors whether a controller switchover is actually triggered.
[0162] Determine the rollback condition: If it is determined that switching is not necessary (for example, because the network status returns to the normal range), the rollback mechanism is triggered.
[0163] For example, if the AI prediction model predicts that the network load will exceed the processing capacity of the primary controller in the next 5 minutes, the system will start the pre-synchronization mechanism. At this time, the primary controller will synchronize all key configuration files and real-time data to the backup controller. If the network load drops for some reason after the synchronization is completed, and the predicted switch does not occur, the system will start the rollback mechanism to restore the backup controller to the state before synchronization, ensuring the data consistency and stability of the system.
[0164] The data pre-synchronization device for network controller switching provided by the present invention is described below. The data pre-synchronization device for network controller switching described below and the data pre-synchronization method for network controller switching described above can be referred to each other.
[0165] like Figure 7 As shown, in one embodiment, a data pre-synchronization device for network controller switching includes an acquisition module 710 , an identification module 720 , a response module 730 and a trigger module 740 .
[0166] The acquisition module 710 is used to obtain historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status. The historical data includes information on network traffic patterns, data transmission delays, and error rates.
[0167] The identification module 720 is used to identify the network status based on the feature set and output the prediction result of the network status.
[0168] The response module 730 is used to output a warning signal and trigger a pre-synchronization mechanism in response to the prediction result reaching the switching threshold.
[0169] The trigger module 740 is used to trigger the rollback mechanism in response to the network status being within a normal range or the controller switching not actually occurring.
[0170] In this embodiment, the acquisition module 710 is specifically used for:
[0171] Obtain performance indicator data of key network nodes under monitoring;
[0172] Clean and format the historical data to obtain pre-processed historical data;
[0173] Analyze traffic patterns and identify peak traffic periods based on pre-processed historical data;
[0174] Analyze node failure history and output possible future failure points;
[0175] Perform mathematical transformation on the preprocessed historical data.
[0176] In this embodiment, mathematical transformation is performed on the preprocessed historical data, specifically for:
[0177] Identify periodic signals of pre-processed historical data based on Fourier transform technology;
[0178] Or, calculate the basic statistics of the preprocessed historical data, including the mean and variance.
[0179] In this embodiment, the identification module 720 is specifically used for:
[0180] Obtain a feature set representing the network state;
[0181] The feature set is input into the AI prediction model, and the prediction result of the network status is output. The AI prediction model is trained with samples of normal operating network status and samples of abnormal operating network status as training data.
[0182] In this embodiment, the pre-synchronization mechanism is triggered, specifically for:
[0183] Determine the data and status information that need to be synchronized;
[0184] Perform data synchronization, the calculation formula is as follows:
[0185] Data synchronization = f(primary node data, backup node),
[0186] Among them, f represents the synchronization function;
[0187] Verify the data of the backup node.
[0188] In this embodiment, the rollback mechanism is triggered, specifically for:
[0189] Stop the data synchronization process and roll back the backup database to the specified time point;
[0190] Update internal state management information and mark the data on the backup node as invalid or inactive;
[0191] Instruct the relevant network components and controllers to undo any switching actions triggered by the misprediction;
[0192] Record detailed information of the rollback operation, including the triggering reason, execution steps and results;
[0193] Update the AI prediction model based on the cause of the error.
[0194] The data pre-synchronization device for network controller switching can reduce the risk of delay and data inconsistency during network controller switching by intelligently predicting changes in network status and performing data synchronization in advance, thereby improving the stability and reliability of the network. At the same time, by determining whether the network controller switching actually occurs and providing a remedial rollback mechanism, the status of the backup controller can be restored to the state before synchronization, thereby ensuring the data consistency and stability of the system.
[0195] Figure 8 An example of a physical structure diagram of an electronic device is shown. The electronic device may be a smart terminal, and its internal structure diagram may be as follows: Figure 8 As shown. The electronic device includes a processor, a memory and a network interface connected via a system bus. The processor of the electronic device is used to provide computing and control capabilities. The memory of the electronic device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the electronic device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, a data pre-synchronization method for switching a network controller is implemented, and the method includes:
[0196] Obtain historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status. Historical data includes information on network traffic patterns, data transmission delays, and error rates.
[0197] Based on the feature set, identify the network status and output the prediction result of the network status;
[0198] In response to the prediction result reaching the switching threshold, an early warning signal is output and a pre-synchronization mechanism is triggered;
[0199] In response to the network status being within a normal range or the controller switching not actually occurring, a rollback mechanism is triggered.
[0200] Those skilled in the art will understand that Figure 8 The structure shown in the figure is only a block diagram of a part of the structure related to the scheme of the present invention, and does not constitute a limitation on the electronic device to which the scheme of the present invention is applied. The specific electronic device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0201] On the other hand, the present invention further provides a computer storage medium storing a computer program, wherein when the computer program is executed by a processor, a data pre-synchronization method for network controller switching is implemented, the method comprising:
[0202] Obtain historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status. Historical data includes information on network traffic patterns, data transmission delays, and error rates.
[0203] Based on the feature set, identify the network status and output the prediction result of the network status;
[0204] In response to the prediction result reaching the switching threshold, an early warning signal is output and a pre-synchronization mechanism is triggered;
[0205] In response to the network status being within a normal range or the controller switching not actually occurring, a rollback mechanism is triggered.
[0206] In another aspect, a computer program product or a computer program is provided, the computer program product or the computer program comprising computer instructions, the computer instructions being stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium, and when the processor executes the computer instructions, a data pre-synchronization method for switching a network controller is implemented, the method comprising:
[0207] Obtain historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status. Historical data includes information on network traffic patterns, data transmission delays, and error rates.
[0208] Based on the feature set, identify the network status and output the prediction result of the network status;
[0209] In response to the prediction result reaching the switching threshold, an early warning signal is output and a pre-synchronization mechanism is triggered;
[0210] In response to the network status being within a normal range or the controller switching not actually occurring, a rollback mechanism is triggered.
[0211] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing related hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided by the present invention may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory.
[0212] By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0213] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0214] The above-described embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the attached claims.
Claims
1. A data pre-synchronization method for network controller switching, characterized in that: The method comprises: Obtain historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status, wherein the historical data includes information on network traffic patterns, data transmission delays, and error rates; Based on the feature set, identify the network status and output the prediction result of the network status; In response to the prediction result reaching the switching threshold, an early warning signal is output and a pre-synchronization mechanism is triggered; In response to the network status being within a normal range or the controller switching not actually occurring, a rollback mechanism is triggered.
2. The data pre-synchronization method for network controller switching according to claim 1, characterized in that: The acquisition of historical data of network operation and extraction of features including traffic peak hours and node failure history include: Obtain performance indicator data of key network nodes under monitoring; Clean and format the historical data to obtain pre-processed historical data; Analyze traffic patterns and identify peak traffic periods based on pre-processed historical data; Analyze node failure history and output possible future failure points; Perform mathematical transformation on the preprocessed historical data.
3. The data pre-synchronization method for network controller switching according to claim 2, characterized in that: The mathematical conversion of the pre-processed historical data includes: Identify periodic signals of pre-processed historical data based on Fourier transform technology; Or, basic statistics of the preprocessed historical data are calculated, where the basic statistics include a mean and a variance.
4. The data pre-synchronization method for network controller switching according to claim 1, characterized in that: The identifying the network state based on the feature set and outputting the prediction result of the network state includes: Obtain a feature set representing the network state; The feature set is input into an AI prediction model, and a prediction result of the network status is output. The AI prediction model is trained using samples of network status in normal operation and samples of network status in abnormal operation as training data.
5. The data pre-synchronization method for network controller switching according to claim 4, characterized in that: The AI prediction model is a time series model or a deep learning model. The time series model is used to process data with strong linearity and periodicity, and the deep learning model is used to process complex data with long-term dependencies and nonlinear relationships.
6. The data pre-synchronization method for network controller switching according to any one of claims 1 to 5, characterized in that: The trigger pre-synchronization mechanism comprises: Determine the data and status information that need to be synchronized; Perform data synchronization, the calculation formula is as follows: , Among them, f represents the synchronization function; Verify the data of the backup node.
7. The data pre-synchronization method for network controller switching according to claim 6, characterized in that: The trigger rollback mechanism includes: Stop the data synchronization process and roll back the backup database to the specified time point; Update internal state management information and mark the data on the backup node as invalid or inactive; Instruct the relevant network components and controllers to undo any switching actions triggered by the misprediction; Record detailed information of the rollback operation, including triggering reasons, execution steps, and results; Update the AI prediction model based on the cause of the error.
8. A data pre-synchronization device for network controller switching, characterized in that: include: An acquisition module is used to acquire historical data of network operation and extract features including traffic peak periods and node failure history to form a feature set representing the network status. The historical data includes information on network traffic patterns, data transmission delays, and error rates. The recognition module is used to identify the network state based on the feature set and output the prediction result of the network state; A response module, used to output a warning signal and trigger a pre-synchronization mechanism in response to the prediction result reaching the switching threshold; The trigger module is used to trigger the rollback mechanism in response to the network status being within a normal range or the controller switching not actually occurring.
9. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Controller fault replacement system and method
CN113485090A
Network data detection method applying FCM clustering algorithm
CN116723136A
Industrial robot state monitoring method and system of distributed intelligent network
CN118092242A
Fault diagnosis method based on HPLC dual-mode communication technology
CN118264538A
Control method of PLC (Programmable Logic Controller) network with redundant CPU (Central Processing Unit)
CN118502346A
