Data source fault processing method and system based on AI server redundant system
By detecting and adjusting the status parameters of the CPU and NPU in real time in the AI server redundant system, the problem of data loss and slow recovery in the AI server architecture is solved, and business continuity and data processing efficiency are achieved.
Patent Information
- Application Number
- CN202410815794.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-24
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-06-24
AI Technical Summary
The existing AI server architecture causes the data source to be lost when the CPU is abnormal, the last calculation point cannot be fully restored, and the data model is processed slowly.
By detecting the status parameters of the CPU and NPU in the AI server redundant system in real time, dynamically adjust the priority, and switch to the matching CPU or NPU for data processing and calculation, ensuring that the data is backed up and recalculated when an exception occurs to avoid data loss. , and automatically switch data processing to other modules when the NPU module is abnormal.
It implements data source fault handling when the CPU or NPU is abnormal, ensuring business continuity, reducing data loss, and improving the recovery capability and processing speed of the data model.
Smart Images

Figure CN118394576B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of AI data source exception processing, and in particular, to a data source fault processing method and system based on an AI server redundant system. Background Art
[0002] The architecture of existing AI servers is based on the form of CPU+NPU. For existing AI servers, when the CPU system is abnormal, the whole machine cannot continue to work, and the NPU data source parsing will be terminated, resulting in abnormal loss of data sources. For example, 10,000 data languages are divided into 2,500 parts and given to four NPU modules for parsing. When parsing 4,999 data sources, the CPU is abnormal. The remaining unparsed data sources will fail to calculate due to the CPU abnormality and cannot be stored in the NVMe disk through the CPU, resulting in the loss of this part of the data source. At this time, it takes time for users to restore data and repair AI servers, and the interruption of business systems is a considerable loss to users.
[0003] For AI servers, when there are multiple NPU modules in the system, such as four NPU modules, when one of the NPU modules is abnormal, such as NPU module No. 1, the data source calculations of the remaining 2 / 3 NPU modules will wait for the calculation of NPU module No. 1 to be completed, and the data source calculation assigned to NPU module No. 1 fails due to the abnormality of NPU module No. 1. The existing technology is to isolate NPU module No. 1 through breakpoint continuation training, and at the same time handle the failure of this group of data sources. The subsequent NPU continues to calculate the next group of assigned data sources, which does not affect the analysis of the entire large data model, but there will be a data alarm to inform the user that the analysis of this group of data models is abnormal. This group of large data models will be recalculated later, but this method will still cause the loss of unsaved data, and it is impossible to completely restore the last calculation point. It only continues training based on the last saved data, and the data model processing is slow.
[0004] Therefore, how to improve the architecture of existing AI servers to solve the technical problems of the existing server architecture that easily causes the loss of unsaved data, cannot completely restore the last calculation point and only continues training based on the last saved data, and slow data model processing. Summary of the invention
[0005] The purpose of the present invention is to provide a data source fault handling method and system based on an AI server redundant system, so as to solve the technical problems existing in the existing server architecture, such as easy loss of unsaved data, inability to completely restore the last calculation point and only continue training based on the last saved data, and slow data model processing.
[0006] In order to solve the above technical problems, the technical solution adopted by the present invention is as follows:
[0007] In a first aspect, a data source failure processing method based on an AI server redundant system is provided, comprising the following steps:
[0008] S1: When starting the server, the status parameters of each CPU are detected, and the current CPU priority of each CPU is determined based on the status parameters, and the current CPU priority is compared with the default CPU priority to determine whether they are consistent. If so, step S2 is executed; if not, the CPU is run at the current priority, and step S2 is executed again, and the current CPU priority is set as the default priority;
[0009] S2: The CPU processes data and monitors the status of the currently running CPU in real time to determine whether it is abnormal. If so, the abnormality type and the data type being processed are analyzed, and the corresponding CPU is matched according to the abnormality type and the data type being processed, and the CPU is switched to the matching CPU, and the current priority is updated according to the matching result; if not, the CPU current priority is continued to be executed;
[0010] S3: The matching CPU caches the calculation data source stored in the NVMe disk of the abnormal CPU into the DIMM memory bar of the matching CPU, and sends AI algorithm instructions from the DIMM memory bar of the matching CPU to recalculate on the NPU module of the matching CPU;
[0011] S4: monitor the status parameters of each NPU in the NPU module of the matched CPU in real time, and determine the current priority of the NPU in the NPU module of the matched CPU according to its status parameters, compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent, if so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority;
[0012] S5: The NPU module processes data and monitors the status of each currently running NPU in real time to determine whether there is an abnormality. If so, analyze the abnormality type and the data type being processed, match the corresponding NPU according to the abnormality type and the data type being processed, and update the current priority of the NPU according to the matching result; the matching CPU re-sends the AI computing data source statically cached in the DIMM to the matching NPU, and the matching NPU calculates one more AI computing data source and executes step S6; if not, continue to execute the current priority of the NPU and then execute step S6;
[0013] S6: The data model analysis after calculation is sent to the matching CPU, which then caches the analyzed AI calculation data source in the DIMM memory bar and saves the data in the NVMe disk.
[0014] S7: Maintain the abnormal CPU and abnormal NPU to complete the fault handling of the AI server.
[0015] Preferably, step S1 includes the following specific process:
[0016] S11: Start the server and collect performance parameters of each CPU of the server in real time, wherein the performance parameters include main frequency, bus frequency, secondary cache, number of cores and number of threads;
[0017] S12: Score the performance of each CPU based on the collected performance parameters of each CPU and the corresponding preset weights of each parameter;
[0018] S13: setting the current priority of the CPU according to the performance score of each CPU, wherein the higher the score, the higher the corresponding priority;
[0019] S14: Compare the current CPU priority with the default CPU priority to determine whether they are consistent. If so, execute step S2; if not, run at the current CPU priority, execute step S2 again, and set the current CPU priority to the default priority;
[0020] The scoring process of step S12 is to first score each performance parameter. For example, when a certain performance parameter M is at the theoretical optimal state value, the full score is 10 points. 10 is multiplied by the percentage of the collected performance parameter compared to the theoretical optimal state value to obtain the score A of the corresponding performance parameter; the scores of other performance parameters are B, C, D, and E respectively, and the corresponding weights of A, B, C, D, and E are a, b, c, d, and e, and a+b+c+d+e=100%;
[0021] The final CPU score is X=Aa+Bb+Cc+Dd+Ee.
[0022] Preferably, step S2 includes the following specific process:
[0023] S21: Start the corresponding CPU to process data according to the priority in S1, and collect the status parameters of the currently running CPU in real time;
[0024] S22: Based on the comparison of the state parameters of the currently running CPU with the preset normal state parameters, it is determined whether there is an abnormality. If so, step S23 is executed; if not, the current priority of the CPU is continued to be executed;
[0025] S23: Analyze the exception type and the processed data type, match the corresponding CPU according to the exception type and the processed data type, switch to the matched CPU, and update the current priority according to the matching result.
[0026] Preferably, in step S2, the method of real-time monitoring of the currently running CPU in the CPU system of the AI server is that the CPU that is not performing data processing actively queries the CPU that is performing data processing, and at the same time, the CPU that is performing data processing also actively queries the CPU that is not performing data processing;
[0027] The method of real-time monitoring of the NPU module is as follows: the CPU that performs data processing actively monitors each NPU connected to it, and the CPU that does not perform data processing also actively monitors each NPU connected to it.
[0028] Preferably, in step S2, the corresponding CPU is matched to be a redundant CPU of the current server or a redundant CPU of another server according to the exception type and the processed data type.
[0029] Preferably, step S4 includes the following specific process:
[0030] S41: monitoring the status parameters of each NPU in the NPU module of the matched CPU in real time, wherein the status parameters of the NPU include computing power, frequency, and power consumption;
[0031] S42: Scoring the performance of each NPU based on the collected state parameters of each NPU and the corresponding preset parameter weights, and setting the current priority of the NPU in the NPU module of the matching CPU according to the scoring result, wherein the scoring process of each NPU is the same as the scoring process of the CPU;
[0032] S43: Compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent. If so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority.
[0033] Preferably, the execution steps of the data flow in the process of data source failure processing are as follows:
[0034] S1-1: The application task starts, the CPU runs the AI program, initializes the AI task NPU resources, and loads the model and network structure to the NPU;
[0035] S2-2: The data reading part starts to read the data to be used for the AI task, and reads the hard disk data into the CPU memory;
[0036] S3-3: The data preprocessing part preprocesses the data, and the CPU distributes the preprocessed data to all NPUs;
[0037] S4-4: The AI algorithm task starts, and the program distributes AI computing tasks to all NPUs through the CANN intermediate interface;
[0038] S5-5: The AI main process on the CPU side waits for all NPU AI task operations to be completed, copies all results back to the CPU side memory for data integration, and returns the integrated data to the CPU side;
[0039] S6-6: The network model of the AI main process on the CPU side updates the parameters of the AI model;
[0040] S7-7: The CPU program saves the current AI model weight file.
[0041] Preferably, the data integration in step S5-5 uses the All reduce distributed set communication data integration algorithm.
[0042] In the second aspect, a data source fault handling system based on an AI server redundant system is provided, including CPU0, CPU1, an NPU module, a DIMM memory bar, an NVMe disk, a PCIe standard card and a PCIe switch, wherein the CPU0 is communicatively connected to the CPU1, and the NPU module and the PCIe switch are each provided with two groups, wherein one group of NPU modules is connected to the CPU0 through one group of PCIe switches, and the other group of NPU modules is connected to the CPU1 through another group of PCIe switches;
[0043] The CPU0 and CPU1 are dual CPU redundant backup systems, which are used for system management of AI servers and AI data source acquisition and calculation data source, and are allocated to the NPU module data source in multi-point form;
[0044] The NPU module is used for AI data source calculation;
[0045] The DIMM memory bar is used for AI data source static cache and memory cache;
[0046] The NVMe disk is used to store the AI server operating system and the data storage of AI computing data sources and computing analysis;
[0047] The PCIe standard card is a standard PCIe network card or computing card;
[0048] The PCIe switch is used for PCIe expansion of CPU0, CPU1 and NPU module interaction. CPU0 and CPU1 are connected to the corresponding NPU module through the PCIe switch as a computing data source processing path.
[0049] The beneficial effects of the present invention include:
[0050] The data source fault handling method and system based on the AI server redundant system provided by the present invention detect the status parameters of each CPU in its CPU system when starting the server, and execute it with the best priority; monitor the status of the currently running CPU in real time, judge whether it is abnormal, and switch to the matching CPU, and update the current priority according to the matching result; the DIMM memory bar of the matching CPU sends algorithm instructions to recalculate on the NPU module of the matching CPU; monitor the status parameters of the NPU in real time and execute the best priority; monitor the status of each currently running NPU in real time, judge whether it is abnormal, and execute the best priority; the CPU sends the data source to the matching NPU for one more calculation, and the CPU saves the parsed data source to the NVMe disk.
[0051] First, AI servers involve a CPU+NPU architecture, and the CPU uses DIMM memory sticks to implement CPU backup redundancy. When one of the CPUs is abnormal, the data model business that interacts with the CPU and the NPU can continue to work, and will not affect the customer's current business use in the short term. At the same time, the CPU abnormality alerts the user, and the user can repair the server or shut down the business before the next business model calculation and inference to ensure that the data source will not be lost at will.
[0052] Second, by setting the priority of the CPU and executing the best priority in data processing, the server is guaranteed to be in the best state when processing data, and can match the appropriate CPU according to the data type. The same is true for setting the priority of the NPU module.
[0053] Third, when there are multiple NPU modules in the system, the CPU+NPU module is equipped through the software system. When one of the NPUs is abnormal, the data calculation of the abnormal NPU is terminated, and the corresponding CPU automatically switches to another NPU. At the same time, the data source allocated by the previous NPU is extracted from the NVMe disk, and sent to other NPUs for recalculation and allocation of abnormal data. After the calculation of the previous NPU module is completed, the subsequent NPU module continues to calculate the allocated data, and finally returns the result to the connected CPU for result integration and processing. At the same time, the CPU isolates the abnormal NPU module, and the subsequent big data is reallocated to other normal modules to continue business calculations. The abnormal problem point of the NPU module is determined and repaired when the system is restarted or the server is powered on and off next time. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 This is a structural diagram of the data source fault processing system based on the AI server redundant system of the present invention.
[0055] Figure 2 It is a schematic diagram of the I data source calculation and analysis execution flow of the present invention.
[0056] Figure 3 This is a structural schematic diagram of a CPU failure in a data source fault processing system based on an AI server redundant system of the present invention.
[0057] Figure 4 This is a structural schematic diagram of a case where a certain NPU of the data source fault processing system based on the AI server redundant system of the present invention fails. DETAILED DESCRIPTION
[0058] The following is combined with Figure 1~Figure 4 The present invention is further described in detail:
[0059] See attached Figure 1 As shown, the data source fault handling method based on the AI server redundant system includes the following steps:
[0060] S1: When starting the server, the status parameters of each CPU are detected, and the current CPU priority of each CPU is determined based on the status parameters, and the current CPU priority is compared with the default CPU priority to determine whether they are consistent. If so, step S2 is executed; if not, the CPU is run at the current priority, and step S2 is executed again, and the current CPU priority is set as the default priority;
[0061] S2: The CPU processes data and monitors the status of the currently running CPU in real time to determine whether it is abnormal. If so, the abnormality type and the data type being processed are analyzed, and the corresponding CPU is matched according to the abnormality type and the data type being processed, and the CPU is switched to the matching CPU, and the current priority is updated according to the matching result; if not, the CPU current priority is continued to be executed;
[0062] S3: The matching CPU caches the calculation data source stored in the NVMe disk of the abnormal CPU into the DIMM memory bar of the matching CPU, and sends AI algorithm instructions from the DIMM memory bar of the matching CPU to recalculate on the NPU module of the matching CPU;
[0063] S4: monitor the status parameters of each NPU in the NPU module of the matched CPU in real time, and determine the current priority of the NPU in the NPU module of the matched CPU according to its status parameters, compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent, if so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority;
[0064] S5: The NPU module processes data and monitors the status of each currently running NPU in real time to determine whether there is an abnormality. If so, analyze the abnormality type and the data type being processed, match the corresponding NPU according to the abnormality type and the data type being processed, and update the current priority of the NPU according to the matching result; the matching CPU re-sends the AI computing data source statically cached in the DIMM to the matching NPU, and the matching NPU calculates one more AI computing data source and executes step S6; if not, continue to execute the current priority of the NPU and then execute step S6;
[0065] S6: The data model analysis after calculation is sent to the matching CPU, which then caches the analyzed AI calculation data source in the DIMM memory bar and saves the data in the NVMe disk.
[0066] S7: Maintain the abnormal CPU and abnormal NPU to complete the fault handling of the AI server.
[0067] In the above scheme, step S1 includes the following specific processes:
[0068] S11: Start the server and collect performance parameters of each CPU of the server in real time, wherein the performance parameters include main frequency, bus frequency, secondary cache, number of cores and number of threads;
[0069] S12: Score the performance of each CPU based on the collected performance parameters of each CPU and the corresponding preset weights of each parameter;
[0070] S13: setting the current priority of the CPU according to the performance score of each CPU, wherein the higher the score, the higher the corresponding priority;
[0071] S14: Compare the current CPU priority with the default CPU priority to determine whether they are consistent. If so, execute step S2; if not, run at the current CPU priority, execute step S2 again, and set the current CPU priority to the default priority;
[0072] The scoring process of step S12 is to first score each performance parameter. For example, when a certain performance parameter M is at the theoretical optimal state value, the full score is 10 points. 10 is multiplied by the percentage of the collected performance parameter compared to the theoretical optimal state value to obtain the score A of the corresponding performance parameter; the scores of other performance parameters are B, C, D, and E respectively, and the corresponding weights of A, B, C, D, and E are a, b, c, d, and e, and a+b+c+d+e=100%;
[0073] The final CPU score is X=Aa+Bb+Cc+Dd+Ee.
[0074] Step S2 includes the following specific processes:
[0075] S21: Start the corresponding CPU to process data according to the priority in S1, and collect the status parameters of the currently running CPU in real time;
[0076] S22: Based on the comparison of the state parameters of the currently running CPU with the preset normal state parameters, it is determined whether there is an abnormality. If so, step S23 is executed; if not, the current priority of the CPU is continued to be executed;
[0077] S23: Analyze the exception type and the processed data type, match the corresponding CPU according to the exception type and the processed data type, switch to the matched CPU, and update the current priority according to the matching result.
[0078] In step S2, the current running CPU in the CPU system of the AI server is monitored in real time in the following manner: the CPU that is not performing data processing actively queries the CPU that is performing data processing, and the CPU that is performing data processing also actively queries the CPU that is not performing data processing. The NPU module is monitored in real time in the following manner: the CPU that is performing data processing actively monitors each NPU connected to it, and the CPU that is not performing data processing also actively monitors each NPU connected to it.
[0079] When a CPU is abnormal, that is, CPU0 marked with an "X" in the figure, the computing business of the abnormal CPU can interact with the matching CPU. When the matching CPU actively queries the abnormal CPU, the matching CPU caches the computing data source stored in the NVMe disk to the DIMM memory bar, and then sends AI algorithm instructions from the DIMM memory bar to recalculate on the NPU module. In this way, user business data will not be interrupted in the short term under the abnormality, and user losses are minimized while effectively ensuring the reliability and stability of the server.
[0080] Step S4 includes the following specific processes:
[0081] S41: monitoring the status parameters of each NPU in the NPU module of the matched CPU in real time, wherein the status parameters of the NPU include computing power, frequency, and power consumption;
[0082] S42: Scoring the performance of each NPU based on the collected state parameters of each NPU and the corresponding preset parameter weights, and setting the current priority of the NPU in the NPU module of the matching CPU according to the scoring result, wherein the scoring process of each NPU is the same as the scoring process of the CPU;
[0083] S43: Compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent. If so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority.
[0084] See also Figure 2 For AI servers, AI data flow anomalies, we must first clarify the processing form of the data flow. When the NPU module is in an abnormal state, this application will not continuously interrupt the calculation of the NPU module through the cooperation of the CPU and NPU, avoiding data flow loss and calculation failure leading to large data source calculation errors. The execution steps of the data flow in the process of data source fault processing are as follows:
[0085] S1-1: Program running: The application task starts, the CPU runs the AI program, initializes the AI task NPU resources, and loads the model and network structure to the NPU;
[0086] S2-2: Data reading: The data reading part starts to read the data to be used for the AI task, and reads the hard disk data into the CPU memory;
[0087] S3-3: Data preprocessing and distribution: The data preprocessing part preprocesses the data, and the CPU distributes the preprocessed data to all NPUs;
[0088] S4-4: AI algorithm task running: The AI algorithm task starts, and the program distributes AI computing tasks to all NPUs through the CANN intermediate interface;
[0089] S5-5: Data integration: The AI main process on the CPU side waits for all NPU AI task operations to complete, copies all results back to the CPU side memory for data integration, and returns the integrated data to the CPU side;
[0090] S6-6: Parameter update: The reverse part of the network model gradient derivation reverse calculation of the AI main process on the CPU side updates the parameters of the AI model;
[0091] S7-7: File storage: The CPU program saves the current AI model weight file.
[0092] In the execution steps of the above data flow, the NPU module plays a pivotal role in AI data flow processing in the AI server. When an NPU module fails, the entire AI computing process will be terminated. For existing AI servers, AI tasks can be assigned to multiple AI chips for AI computing. For example, 10,000 target data can be X copies based on the number of AI chips that can be run, X. Then the number of NPU operations per batch is BatchSize, and BatchSize is the number of samples for training at one time; so each NPU will eventually run 10,000 / X / BatchSize times, and the number of samples per training is also called epoch. If one of the NPUs fails during the 1000th epoch, the BatchSize data of the 1000th epoch of the failed NPU will be invalidated.
[0093] See also Figure 4 In another embodiment, for example, when an exception occurs in NPU1 of CPU0, that is, NPU1 marked with an "X" in the figure, CPU0 notifies CPU1 to re-send the AI computing data source statically cached in DIMM to NPU2; then CPU1 skips the abnormal NPU1 and asks NPU2 to calculate another copy of the AI computing data source again; then the data model parsing after the calculation is sent to CPU0, and CPU0 caches the parsed AI computing data source in the DIMM memory bar, and then saves the data in the NVMe disk.
[0094] See also Figure 1 A data source fault handling system based on an AI server redundant system includes CPU0, CPU1, an NPU module, a DIMM memory stick, an NVMe disk, a PCIe card and a PCIe switch. The CPU0 is communicatively connected to the CPU1. The NPU module and the PCIe switch are each provided with two groups, one of which is connected to the CPU0 through a group of PCIe switches, and the other is connected to the CPU1 through another group of PCIe switches. The PCIe switch is a key component for extending or aggregating PCIe interfaces.
[0095] The CPU0 and CPU1 are dual CPU redundant backup systems, which are used for system management of AI servers and AI data sources to obtain computing data sources, and are allocated to NPU module data sources in multi-point form. The NPU module is used for AI data source calculation. The DIMM memory bar is used for AI data source static cache and memory cache. The NVMe disk is used to store the AI server operating system and the data storage of AI computing data sources and computing parsed data. The PCIe standard card is a standard PCIe network card or computing card. The PCIe switch is used for PCIe extension for the interaction between CPU0, CPU1 and NPU modules. CPU0 and CPU1 bridge the corresponding NPU modules through the PCIe switch as the computing data source processing path.
[0096] In summary, the data source fault handling method and system based on the AI server redundant system provided by the present invention detects the status parameters of each CPU in its CPU system when starting the server, and executes it with the best priority; monitors the status of the currently running CPU in real time, determines whether it is abnormal, and switches to the matching CPU, and updates the current priority according to the matching result; the DIMM memory bar of the matching CPU sends algorithm instructions to recalculate on the NPU module of the matching CPU; monitors the status parameters of the NPU in real time and executes the best priority; monitors the status of each currently running NPU in real time, determines whether it is abnormal, and executes the best priority; the CPU sends the data source to the matching NPU for one more calculation, and the CPU saves the parsed data source to the NVMe disk.
[0097] First, AI servers involve a CPU+NPU architecture, and the CPU uses DIMM memory sticks to implement CPU backup redundancy. When one of the CPUs is abnormal, the data model business that interacts with the CPU and the NPU can continue to work, and will not affect the customer's current business use in the short term. At the same time, the CPU abnormality alerts the user, and the user can repair the server or shut down the business before the next business model calculation and inference to ensure that the data source will not be lost at will.
[0098] Second, by setting the priority of the CPU and executing the best priority in data processing, the server is guaranteed to be in the best state when processing data, and can match the appropriate CPU according to the data type. The same is true for setting the priority of the NPU module.
[0099] Third, when there are multiple NPU modules in the system, the CPU+NPU module is equipped through the software system. When one of the NPUs is abnormal, the data calculation of the abnormal NPU is terminated, and the corresponding CPU automatically switches to another NPU. At the same time, the data source allocated by the previous NPU is extracted from the NVMe disk, and sent to other NPUs for recalculation and allocation of abnormal data. After the calculation of the previous NPU module is completed, the subsequent NPU module continues to calculate the allocated data, and finally returns the result to the connected CPU for result integration and processing. At the same time, the CPU isolates the abnormal NPU module, and the subsequent big data is reallocated to other normal modules to continue business calculations. The abnormal problem point of the NPU module is determined and repaired when the system is restarted or the server is powered on and off next time.
Claims
1. A data source fault handling method based on an AI server redundant system, characterized in that: The following steps are involved: S1: When starting the server, the status parameters of each CPU are detected, and the current CPU priority of each CPU is determined based on the status parameters, and the current CPU priority is compared with the default CPU priority to determine whether they are consistent. If so, step S2 is executed; if not, the CPU is run at the current priority, and step S2 is executed again, and the current CPU priority is set as the default priority; S2: The CPU processes data and monitors the status of the currently running CPU in real time to determine whether it is abnormal. If so, the abnormality type and the data type being processed are analyzed, and the corresponding CPU is matched according to the abnormality type and the data type being processed, and the CPU is switched to the matching CPU, and the current priority is updated according to the matching result; if not, the CPU current priority is continued to be executed; S3: The matching CPU caches the calculation data source stored in the NVMe disk of the abnormal CPU into the DIMM memory bar of the matching CPU, and sends AI algorithm instructions from the DIMM memory bar of the matching CPU to recalculate on the NPU module of the matching CPU; S4: monitor the status parameters of each NPU in the NPU module of the matched CPU in real time, and determine the current priority of the NPU in the NPU module of the matched CPU according to its status parameters, compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent, if so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority; S5: The NPU module processes data and monitors the status of each currently running NPU in real time to determine whether there is an abnormality. If so, analyze the abnormality type and the data type being processed, match the corresponding NPU according to the abnormality type and the data type being processed, and update the current priority of the NPU according to the matching result; the matching CPU re-sends the AI computing data source statically cached in the DIMM to the matching NPU, and the matching NPU calculates one more AI computing data source and executes step S6; if not, continue to execute the current priority of the NPU and then execute step S6; S6: The data model analysis after calculation is sent to the matching CPU, which then caches the analyzed AI calculation data source in the DIMM memory bar and saves the data in the NVMe disk. S7: Maintain the abnormal CPU and abnormal NPU to complete the fault handling of the AI server.
2. The data source failure processing method based on the AI server redundant system according to claim 1 is characterized in that: Step S1 includes the following specific processes: S11: Start the server and collect performance parameters of each CPU of the server in real time, wherein the performance parameters include main frequency, bus frequency, secondary cache, number of cores and number of threads; S12: Score the performance of each CPU based on the collected performance parameters of each CPU and the corresponding preset weights of each parameter; S13: setting the current priority of the CPU according to the performance score of each CPU, wherein the higher the score, the higher the corresponding priority; S14: Compare the current CPU priority with the default CPU priority to determine whether they are consistent. If so, execute step S2; if not, run at the current CPU priority, execute step S2 again, and set the current CPU priority to the default priority; The scoring process of step S12 is to first score each performance parameter. When a certain performance parameter M is at the theoretical optimal state value, the full score is 10 points. 10 is multiplied by the percentage of the collected performance parameter compared to the theoretical optimal state value to obtain the score A of the corresponding performance parameter; the scores of other performance parameters are B, C, D, and E respectively, and the corresponding weights of A, B, C, D, and E are a, b, c, d, and e, and a+b+c+d+e=100%; The final CPU score is X=Aa+Bb+Cc+Dd+Ee.
3. The data source failure processing method based on the AI server redundant system according to claim 1 is characterized in that: Step S2 includes the following specific processes: S21: Start the corresponding CPU to process data according to the priority in S1, and collect the status parameters of the currently running CPU in real time; S22: Based on the comparison of the state parameters of the currently running CPU with the preset normal state parameters, it is determined whether there is an abnormality. If so, step S23 is executed; if not, the current priority of the CPU is continued to be executed; S23: Analyze the exception type and the processed data type, match the corresponding CPU according to the exception type and the processed data type, switch to the matching CPU, and update the current priority according to the matching result; The specific process of step S23 is as follows: S231: Create a mapping relationship table between the corresponding exception type and the processed data type and the corresponding CPU; S232: Determine the exception type and the data type to be processed, call the mapping table, and obtain a corresponding CPU according to the mapping table; S233: Switch the current CPU to the matching CPU, and update the current priority according to the matching result.
4. The data source failure processing method based on the AI server redundant system according to claim 3 is characterized in that: In step S2, the current running CPU in the CPU system of the AI server is monitored in real time in the following manner: the CPU not performing data processing actively queries the CPU performing data processing, and the CPU performing data processing also actively queries the CPU not performing data processing; The method of real-time monitoring of the NPU module is as follows: the CPU that performs data processing actively monitors each NPU connected to it, and the CPU that does not perform data processing also actively monitors each NPU connected to it.
5. The data source failure processing method based on the AI server redundant system according to claim 3 is characterized in that: In step S2, the corresponding CPU is matched to the redundant CPU of the current server or the redundant CPU of another server according to the exception type and the processed data type.
6. The data source failure processing method based on the AI server redundant system according to claim 1 is characterized in that: Step S4 includes the following specific processes: S41: monitoring the status parameters of each NPU in the NPU module of the matched CPU in real time, wherein the status parameters of the NPU include computing power, frequency, and power consumption; S42: Scoring the performance of each NPU based on the collected state parameters of each NPU and the corresponding preset parameter weights, and setting the current priority of the NPU in the NPU module of the matching CPU according to the scoring result, wherein the scoring process of each NPU is the same as the scoring process of the CPU; S43: Compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent. If so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority.
7. The data source failure processing method based on the AI server redundant system according to claim 1 is characterized in that: The execution steps of the data flow during data source failure handling are as follows: S1-1: The application task starts, the CPU runs the AI program, initializes the AI task NPU resources, and loads the model and network structure to the NPU; S2-2: The data reading part starts to read the data to be used for the AI task, and reads the hard disk data into the CPU memory; S3-3: The data preprocessing part preprocesses the data, and the CPU distributes the preprocessed data to all NPUs; S4-4: The AI algorithm task starts, and the program distributes AI computing tasks to all NPUs through the CANN intermediate interface; S5-5: The AI main process on the CPU side waits for all NPU AI task operations to be completed, copies all results back to the CPU side memory for data integration, and returns the integrated data to the CPU side; S6-6: The network model of the AI main process on the CPU side updates the parameters of the AI model; S7-7: The CPU program saves the current AI model weight file.
8. The data source failure processing method based on the AI server redundant system according to claim 7 is characterized in that: In step S5-5, data integration is performed using the All reduce distributed set communication data integration algorithm.
9. A data source fault handling system based on an AI server redundant system, characterized in that: It includes CPU0, CPU1, NPU module, DIMM memory bar, NVMe disk, PCIe standard card and PCIe switch, wherein CPU0 is connected to CPU1 for communication, and two groups of NPU modules and PCIe switches are provided, wherein one group of NPU modules is connected to CPU0 through one group of PCIe switches, and the other group of NPU modules is connected to CPU1 through another group of PCIe switches; The CPU0 and CPU1 are dual CPU redundant backup systems, which are used for system management of AI servers and AI data source acquisition and calculation data source, and are allocated to the NPU module data source in multi-point form; The NPU module is used for AI data source calculation; The DIMM memory bar is used for AI data source static cache and memory cache; The NVMe disk is used to store the AI server operating system and the data storage of AI computing data sources and computing analysis; The PCIe standard card is a standard PCIe network card or computing card; The PCIe switch is used for PCIe expansion of CPU0, CPU1 and NPU module interaction. CPU0 and CPU1 are bridged to the corresponding NPU module through the PCIe switch as a computing data source processing path; The method for implementing the data source fault processing system based on the AI server redundancy system is: S1: When starting the server, the status parameters of each CPU are detected, and the current CPU priority of each CPU is determined based on the status parameters, and the current CPU priority is compared with the default CPU priority to determine whether they are consistent. If so, step S2 is executed; if not, the CPU is run at the current priority, and step S2 is executed again, and the current CPU priority is set as the default priority; S2: The CPU processes data and monitors the status of the currently running CPU in real time to determine whether it is abnormal. If so, the abnormality type and the data type being processed are analyzed, and the corresponding CPU is matched according to the abnormality type and the data type being processed, and the CPU is switched to the matching CPU, and the current priority is updated according to the matching result; if not, the CPU current priority is continued to be executed; S3: The matching CPU caches the calculation data source stored in the NVMe disk of the abnormal CPU into the DIMM memory bar of the matching CPU, and sends AI algorithm instructions from the DIMM memory bar of the matching CPU to recalculate on the NPU module of the matching CPU; S4: monitor the status parameters of each NPU in the NPU module of the matched CPU in real time, and determine the current priority of the NPU in the NPU module of the matched CPU according to its status parameters, compare the current priority of the NPU with the default priority of the NPU to determine whether they are consistent, if so, execute step S5; if not, run with the current priority of the NPU, execute step S5 again, and set the current priority of the NPU to the default priority; S5: The NPU module processes data and monitors the status of each currently running NPU in real time to determine whether there is an abnormality. If so, analyze the abnormality type and the data type being processed, match the corresponding NPU according to the abnormality type and the data type being processed, and update the current priority of the NPU according to the matching result; the matching CPU re-sends the AI computing data source statically cached in the DIMM to the matching NPU, and the matching NPU calculates one more AI computing data source and executes step S6; if not, continue to execute the current priority of the NPU and then execute step S6; S6: The data model analysis after calculation is sent to the matching CPU, which then caches the analyzed AI calculation data source in the DIMM memory bar and saves the data in the NVMe disk. S7: Maintain the abnormal CPU and abnormal NPU to complete the fault handling of the AI server.
Citation Information
Patent Citations
NPU fault-tolerant scheduling system of computer cluster
CN117632444A
Systems and methods for redundant switch fabric and switch controller
US20090154342A1
