Extension device status detection method, server and electronic device
The method improves the accuracy of expansion device status detection by screening devices based on attribute information and preset values, reducing false alarms and maintenance costs in server systems.
Patent Information
- Application Number
- CN202411356978.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-27
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-09-27
AI Technical Summary
Existing methods for detecting the status of expansion devices in servers, such as PCIe devices, suffer from inaccurate results due to false alarms caused by normal reduced rate or bandwidth operations under the influence of different driver versions or loads, leading to increased maintenance costs and inefficiencies.
A method and apparatus for detecting the status of expansion devices by obtaining attribute information, screening devices to be shielded based on influencing factors, creating a shielding information table with preset expected values, and determining the detection result based on the size relationship between current and expected state values, thereby improving accuracy.
The method enhances the accuracy of expansion device status detection by distinguishing between normal and abnormal operations, reducing false alarms and maintenance efforts, and allowing for efficient management of server resources.
Smart Images

Figure CN118885359B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to an extended device status detection method, a server, and an electronic device. Background Art
[0002] As users' requirements for server performance become higher and higher, server manufacturers often deploy expansion devices such as PCIe devices in servers to meet the needs of servers in different application scenarios. Since the reduction of the rate and bandwidth of expansion devices will affect the overall performance of the server system, how to detect the status of expansion devices has become a key research topic.
[0003] In the related art, the current rate and current bandwidth of the expansion device are usually monitored. If the monitoring result is lower than the rated indicator given by the device manufacturer, the expansion device status is determined to be abnormal, and an alarm is generated to prompt maintenance personnel to perform detailed troubleshooting.
[0004] However, due to different driver versions or different loads of some expansion devices, the expansion devices will automatically perform normal reduced rate operation or reduced bandwidth operation, resulting in false alarms in related technologies and reducing the accuracy of the expansion device status detection results. Summary of the invention
[0005] The present application provides an extended device status detection method, a server and an electronic device to solve the defects of related technologies such as reducing the accuracy of extended device status detection results.
[0006] The first aspect of the present application provides a method for detecting an extended device status, comprising:
[0007] Get the attribute information of each extended device in the server;
[0008] According to the attribute information of each of the extension devices, the extension devices to be shielded are screened; wherein the extension devices to be shielded are normally operated at a reduced rate or reduced bandwidth under the influence of the influencing factors;
[0009] Creating a shielding information table of the server according to the preset state expected value of each of the to-be-shielded extended devices; wherein the preset state expected value is less than the state rated value of the to-be-shielded extended device;
[0010] When the current state value of any of the extension devices to be shielded in the shielding information table is obtained through monitoring, the state detection result of the extension device to be shielded is determined according to the size relationship between the current state value of the extension device to be shielded and the preset state expected value corresponding to the extension device to be shielded.
[0011] In an optional implementation manner, determining the state detection result of the to-be-shielded extended device according to the magnitude relationship between the current state value of the to-be-shielded extended device and the preset state expected value corresponding to the to-be-shielded extended device includes:
[0012] When it is determined that the current state value is lower than the preset state expected value, obtaining a state judgment data set of the to-be-shielded extended device;
[0013] Determine the state detection result of the extension device to be shielded according to the size relationship between the current state value of the extension device to be shielded and each state judgment index in the state judgment data set;
[0014] The current state value at least includes a current rate value and a current bandwidth value, and the preset state expected value at least includes a preset rate expected value and a preset bandwidth expected value.
[0015] In an optional embodiment, the method further includes:
[0016] In the case where it is determined that the current state value is equal to the preset state expected value, it is determined that the state detection result of the to-be-shielded extension device is normal.
[0017] In an optional implementation manner, the step of obtaining a state determination data set of the to-be-shielded extended device includes:
[0018] Obtaining location information of the extended device to be shielded;
[0019] Locating the parent device, child device and root device of the extended device to be shielded in the server according to the location information of the extended device to be shielded;
[0020] The state rating value of the parent device, the state rating value of the child device and the state setting value of the root device are acquired to obtain a state judgment data set of the extended device to be shielded.
[0021] In an optional implementation manner, determining the state detection result of the to-be-shielded extended device according to the magnitude relationship between the current state value of the to-be-shielded extended device and each state judgment indicator in the state judgment data set includes:
[0022] Determining whether the current state value is less than a state rating value of a parent device or a state rating value of a child device;
[0023] In the case where it is determined that the current state value is not less than the state rating value of the parent device or the state rating value of the child device, determining that the state detection result of the to-be-shielded extended device is normal;
[0024] The state judgment data set includes a state rating value of the parent device and a state rating value of the child device.
[0025] In an optional embodiment, the method further includes:
[0026] In the case where it is determined that the current state value is less than the state rating value of the parent device and the state rating value of the child device, determining whether the current state value is less than the state setting value of the root device;
[0027] In the case where it is determined that the current state value is not less than the state setting value of the root device, determining that the state detection result of the to-be-shielded extended device is normal;
[0028] The state judgment data set further includes a state setting value of the root device.
[0029] In an optional embodiment, the method further includes:
[0030] When it is determined that the current state value is less than the state setting value of the root device, it is determined that the state detection result of the to-be-shielded extended device is abnormal.
[0031] In an optional implementation manner, screening the extension devices to be shielded according to the attribute information of each of the extension devices includes:
[0032] For any of the expansion devices, judging, according to the attribute information of the expansion device, whether the state value of the expansion device changes according to the load or according to the driver version;
[0033] If the status value of the expansion device changes according to the load or according to the driver version, the expansion device is regarded as an expansion device to be shielded.
[0034] In an optional implementation manner, the creating the shielding information table of the server according to the preset state expected value of each of the to-be-shielded extended devices includes:
[0035] Creating a shielding information original table in the basic input and output system of the server;
[0036] The expected value of the preset state of each of the to-be-shielded extended devices and the unique identifier of each of the to-be-shielded extended devices are written into the original shielding information table to obtain the shielding information table of the server.
[0037] In an optional embodiment, the method further includes:
[0038] Monitoring the current status value of each expansion device in the server;
[0039] When the current state value of any extended device is obtained through monitoring, determining whether the unique identifier of the extended device is recorded in the shielding information table;
[0040] In the case where the unique identification of the extension device is recorded in the shielding information table, the current state value of any one of the extension devices to be shielded in the shielding information table is determined by monitoring, so as to execute the step of determining the state detection result of the extension device to be shielded according to the size relationship between the current state value of the extension device to be shielded and the expected value of the preset state corresponding to the extension device to be shielded.
[0041] In an optional embodiment, the method further includes:
[0042] In the case that the unique identification record of the extension device is not in the shielding information table, obtaining a state rating value of the extension device;
[0043] The state detection result of the expansion device is determined according to the magnitude relationship between the current state value of the expansion device and the state rated value of the expansion device.
[0044] A second aspect of the present application provides an extended device status detection device, comprising:
[0045] An acquisition module is used to obtain the attribute information of each extended device in the server;
[0046] A screening module, used for screening the extension devices to be shielded according to the attribute information of each of the extension devices; wherein the extension devices to be shielded perform normal reduced rate operation or reduced bandwidth operation under the influence of the influencing factors;
[0047] A creation module, used for creating a shielding information table of the server according to a preset state expected value of each of the to-be-shielded extended devices; wherein the preset state expected value is less than the state rated value of the to-be-shielded extended device;
[0048] The detection module is used to determine the status detection result of the expansion device to be shielded according to the size relationship between the current status value of any expansion device to be shielded and the preset status expected value corresponding to the expansion device to be shielded when the current status value of any expansion device to be shielded in the shielding information table is obtained through monitoring.
[0049] A third aspect of the present application provides a server, comprising: a basic input and output system and a plurality of expansion devices;
[0050] The basic input / output system performs status detection on the plurality of expansion devices based on the method described in the first aspect and various possible designs of the first aspect to obtain a status detection result of each expansion device.
[0051] A fourth aspect of the present application provides an electronic device, comprising: at least one processor and a memory;
[0052] The memory stores computer-executable instructions;
[0053] The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor performs the method described in the first aspect and various possible designs of the first aspect.
[0054] A fifth aspect of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When a processor executes the computer-executable instructions, the method described in the first aspect and various possible designs of the first aspect are implemented.
[0055] The sixth aspect of the present application provides a computer program product, including computer instructions, which are used to enable a computer to execute the method described in the first aspect and various possible designs of the first aspect.
[0056] The technical solution of this application has the following advantages:
[0057] The present application provides a method for detecting the status of an extended device, a server, and an electronic device, the method comprising: obtaining the attribute information of each extended device in the server; screening the extended devices to be shielded according to the attribute information of each extended device; wherein the extended devices to be shielded perform normal reduced rate operation or reduced bandwidth operation under the influence of influencing factors; creating a shielding information table of the server according to the preset state expected value of each extended device to be shielded; wherein the preset state expected value is less than the state rated value of the extended device to be shielded; when the current state value of any extended device to be shielded in the shielding information table is obtained through monitoring, the state detection result of the extended device to be shielded is determined according to the size relationship between the current state value of the extended device to be shielded and the preset state expected value corresponding to the extended device to be shielded. The method provided by the above scheme improves the accuracy of the state detection result of the extended device to be shielded by screening the extended devices to be shielded and performing state detection on the extended devices to be shielded based on the preset state expected value. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the following is a brief introduction to the drawings required for use in the embodiments or the related technical descriptions. Obviously, the drawings described below are some embodiments of the present application, and a person skilled in the art can also obtain other drawings based on these drawings.
[0059] Figure 1 A schematic diagram of the initialization process of a server PCIe device provided in an embodiment of the present application;
[0060] Figure 2 This is a schematic diagram of the structure of the extended device status detection system based on the embodiment of the present application;
[0061] Figure 3 A flow chart of a method for detecting the state of an extended device provided in an embodiment of the present application;
[0062] Figure 4 A schematic diagram of the topological structure of an exemplary expansion device provided in an embodiment of the present application;
[0063] Figure 5 A flowchart of an exemplary method for detecting the state of an extended device provided in an embodiment of the present application;
[0064] Figure 6 A flowchart of another exemplary method for detecting the state of an extended device provided in an embodiment of the present application;
[0065] Figure 7 A schematic diagram of the structure of an extended device status detection device provided in an embodiment of the present application;
[0066] Figure 8 A schematic diagram of the structure of a server provided in an embodiment of the present application;
[0067] Fig. 9 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.
[0068] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present disclosure in any way, but to illustrate the concepts of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION
[0069] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0070] In addition, the terms "first", "second", etc. are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. In the description of the following embodiments, the meaning of "multiple" is more than two, unless otherwise clearly and specifically defined.
[0071] Among related technologies, the development of GPU and other PCIe devices has shown a clear upward trend, mainly driven by technological innovation and market demand. In the process of rapid increase in the types and number of devices and continuous iteration, many false alarms have occurred when used on servers.
[0072] When a PCIe device reports a speed reduction or bandwidth reduction, it may affect system performance and stability. Speed reduction or bandwidth reduction may slow down data transmission, thus affecting the overall performance of the system. Especially for applications or tasks that require high-speed data transmission, speed reduction may significantly affect their execution efficiency. Speed reduction may increase the delay of data transmission and affect the response speed of the system. For applications or tasks that require low latency, speed reduction may cause performance degradation. Speed reduction or bandwidth reduction may cause data transmission errors or losses, increase the bit error rate, and thus affect the reliability of the system. This may cause data corruption, system crashes or other adverse consequences. For server maintenance personnel, when PCIe reports a speed reduction or bandwidth reduction behavior, it needs to be resolved as soon as possible. They do not know whether this error should appear or is a real fault. Maintenance personnel need to conduct detailed troubleshooting to determine the cause of the speed reduction. Possible causes include PCIe card failure, Riser card failure, motherboard failure or CPU failure, and the problem needs to be located by replacing components and checking logs. From this point of view, false errors will undoubtedly increase maintenance labor costs.
[0073] There are many reasons why PCIe device false alarms occur, including but not limited to the following:
[0074] 1) The chip manufacturer incorrectly wrote the rated operating speed and bandwidth of the device in the device firmware version;
[0075] 2) The running speed and bandwidth that can be trained to the device under different driver versions are different;
[0076] 3) After the link training is completed, the firmware of the device may reduce the operating speed for power consumption considerations, causing the server BIOS to misjudge the speed reduction and bandwidth reduction behavior.
[0077] like Figure 1As shown, it is a schematic diagram of the initialization process of the server PCIe device provided in the embodiment of the present application. First, the service is powered on, that is, the P0 stage. After the link training (P1 stage) of the PCIe device is completed, the device firmware will reduce the operating rate according to its own strategy, that is, in the P2 stage, P3 stage and the subsequent initialization stage, the PCIe device is in a normal reduced rate operation state, and only resumes the normal operating rate when there is a load. The server BIOS will enter the judgment of the speed reduction and bandwidth reduction behavior after the P4 stage (PCIeBUS scanning, resource allocation, and related function initialization). The P5 stage is the subsequent stage of BIOS POST, and the P6 stage is the end of BIOS POST and enters the system stage, which will cause the BIOS to determine that the PCIe device has abnormal speed behavior in the P4 stage, that is, it cannot confirm whether the device has normal low-power consumption speed reduction and other behaviors, so there will be a risk of false alarms. Among them, BIOS POST means BIOS power-on self-test.
[0078] In response to the above problems, an embodiment of the present application provides a method for detecting the status of an extended device, a server, and an electronic device, the method comprising: obtaining the attribute information of each extended device in the server; screening the extended devices to be shielded according to the attribute information of each extended device; wherein the extended devices to be shielded perform normal reduced rate operation or reduced bandwidth operation under the influence of influencing factors; creating a shielding information table of the server according to the preset state expected value of each extended device to be shielded; wherein the preset state expected value is less than the state rated value of the extended device to be shielded; when the current state value of any extended device to be shielded in the shielding information table is obtained through monitoring, the state detection result of the extended device to be shielded is determined according to the size relationship between the current state value of the extended device to be shielded and the preset state expected value corresponding to the extended device to be shielded. The method provided by the above scheme improves the accuracy of the state detection result of the extended device to be shielded by screening the extended devices to be shielded and performing state detection on the extended devices to be shielded based on the preset state expected value.
[0079] The following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. The embodiments of the present invention will be described below in conjunction with the accompanying drawings.
[0080] First, the structure of the extended device status detection system on which this application is based is described:
[0081] The expansion device status detection method, server and electronic device provided in the embodiments of the present application are suitable for performing status detection on a large number of expansion devices in the server to determine whether the expansion devices have abnormal rate reduction behavior or abnormal bandwidth reduction behavior. Figure 2As shown, it is a structural diagram of the expansion device status detection system based on the embodiment of the present application, which mainly includes a plurality of expansion devices, a data acquisition device and an expansion device status detection device. Among them, the data acquisition device is used to collect information such as attribute information and current status value of the expansion device, and send the collected information to the expansion device status detection device, and the expansion device status detection device performs status detection on the plurality of expansion devices according to the obtained information to obtain the status detection result of each expansion device.
[0082] The embodiment of the present application provides an expansion device status detection method for detecting the status of a large number of expansion devices in a server to determine whether the expansion devices have abnormal rate reduction behavior or abnormal bandwidth reduction behavior. The execution subject of the embodiment of the present application is an electronic device, such as a server, a desktop computer, a laptop computer, a tablet computer, and other electronic devices that can be used for expansion device status detection.
[0083] like Figure 3 FIG. 1 is a flow chart of a method for detecting the state of an extended device provided in an embodiment of the present application, the method comprising:
[0084] Step 301: Obtain attribute information of each extended device in the server.
[0085] The expansion devices in the server include PCIe devices such as GPU, network interface card, storage controller, RAID card and FPGA. The attribute information of the expansion devices at least includes their firmware version information. The firmware version information at least represents the device operation strategy.
[0086] Step 302: Filter the extension devices to be shielded according to the attribute information of each extension device.
[0087] The extended device to be shielded performs normal reduced rate operation or reduced bandwidth operation under the influence of the influencing factors.
[0088] Specifically, the extended devices to be shielded may be screened in the server according to the device operation policy represented by the firmware version information in the attribute information of the extended devices.
[0089] Specifically, in one embodiment, for any expansion device, it can be determined based on the attribute information of the expansion device whether the status value of the expansion device changes according to the load or the driver version; if the status value of the expansion device changes according to the load or the driver version, the expansion device is treated as an expansion device to be shielded.
[0090] The influencing factors include at least load changes and driver version changes, and the state values specifically include rate values and bandwidth values.
[0091] Specifically, it is determined whether the rate value and bandwidth value of the extension device will decrease normally due to factors such as load changes or driver version changes. If so, the extension device is determined to be a shielded extension device, otherwise the extension device is determined to be a common extension device.
[0092] Step 303: Create a shielding information table of the server according to the preset status expected value of each extended device to be shielded.
[0093] The preset state expected value is smaller than the state rated value of the extended device to be shielded.
[0094] Specifically, the upper limit value of the rate or the upper limit value of the bandwidth that the extension device to be shielded can achieve under conditions such as reduced rate operation or reduced bandwidth operation can be used as the preset state expected value of the extension device to be shielded.
[0095] Step 304, when the current state value of any extension device to be shielded in the shielding information table is obtained through monitoring, the state detection result of the extension device to be shielded is determined according to the size relationship between the current state value of the extension device to be shielded and the preset state expected value corresponding to the extension device to be shielded.
[0096] The current state value at least includes a current rate value and a current bandwidth value, and the preset state expected value at least includes a preset rate expected value and a preset bandwidth expected value.
[0097] Specifically, based on the size relationship between the current state value of the extension device to be shielded and the preset state expected value corresponding to the extension device to be shielded, when it is determined that the current rate value of the extension device to be shielded is lower than the preset rate expected value, the rate anomaly judgment process is entered; when it is determined that the current bandwidth value of the extension device to be shielded is lower than the preset bandwidth expected value, the bandwidth anomaly judgment process is entered; finally, based on the final judgment result obtained by the rate anomaly judgment process and / or the bandwidth anomaly judgment process, the state detection result of the extension device to be shielded is determined.
[0098] On the basis of the above embodiments, in order to further improve the accuracy of the status detection result of the extension device to be shielded, as an implementable manner, in one embodiment, according to the size relationship between the current status value of the extension device to be shielded and the preset status expected value corresponding to the extension device to be shielded, the status detection result of the extension device to be shielded is determined, including:
[0099] Step 3041, when it is determined that the current state value is lower than the preset state expected value, obtaining a state judgment data set of the extended device to be shielded;
[0100] Step 3042: Determine the status detection result of the extension device to be shielded according to the size relationship between the current status value of the extension device to be shielded and each status judgment index in the status judgment data set.
[0101] Accordingly, in one embodiment, when it is determined that the current state value is equal to the preset state expected value, it is determined that the state detection result of the to-be-shielded extension device is normal.
[0102] The status judgment index in the status judgment data set may be set according to the application requirements of the rate anomaly judgment process and the bandwidth anomaly judgment process.
[0103] Specifically, the state detection result of the expansion device to be shielded is determined by comparing the current state value of the expansion device to be shielded with the size of each state judgment indicator in the state judgment data set, instead of determining that the state detection result of the expansion device to be shielded is abnormal when the current state value is less than the preset state expected value, thereby improving the accuracy and objectivity of the state detection result of the expansion device to be shielded.
[0104] Specifically, in one embodiment, the location information of the extended device to be shielded can be obtained; based on the location information of the extended device to be shielded, the parent device, child device and root device of the extended device to be shielded are located in the server; the state rating value of the parent device, the state rating value of the child device and the state setting value of the root device are obtained to obtain a state judgment data set of the extended device to be shielded.
[0105] The location information of the extension device to be shielded represents the location of the device in the server device hierarchy. The location information of the extension device to be shielded may specifically include a slot number and a device address.
[0106] For example, Figure 4 As shown, it is a schematic diagram of the topological structure of an exemplary extension device provided in an embodiment of the present application, taking device 2 as an example of an extension device to be shielded for status detection. Figure 4 Device 0 is the root device of the extended device to be shielded, the in-degree of device 0 is 0, device 1 is the parent device of the extended device to be shielded, device 1 is also the parent device of device 3, device 4 and device 5 are child devices of the extended device to be shielded, that is, device 4 and device 5 are mounted on the extended device to be shielded, the extended device to be shielded is mounted on device 1, and device 1 is directly or indirectly mounted on device 0. In actual applications, device 0 can be the CPU of a server, etc.
[0107] Specifically, in one embodiment, it can be determined whether the current state value is less than the state rating of the parent device or the state rating of the child device; when it is determined that the current state value is not less than the state rating of the parent device or the state rating of the child device, it is determined that the state detection result of the expansion device to be shielded is normal.
[0108] The state judgment data set includes the state rating value of the parent device and the state rating value of the child device.
[0109] Specifically, Figure 5 As shown, it is a flow chart of an exemplary method for detecting the status of an extended device provided in an embodiment of the present application. To further ensure the objectivity of the detection result of the status of the extended device, it is possible to first determine whether the current status value of the extended device to be shielded is less than the status rated value, that is, to determine whether the current rate value of the extended device to be shielded is less than the rate rated value, and whether the current bandwidth value of the extended device to be shielded is less than the status bandwidth value. If so, it is further determined whether the current status value is less than the status rated value of the parent device or the status rated value of the child device. Otherwise, it is determined that an abnormality has occurred in the judgment process before this.
[0110] The state rating of the parent device and the state rating of the child device are the maximum rate value / maximum bandwidth value rated supported by the parent device and the maximum rate value / maximum bandwidth value rated supported by the child device. If the child device of the extended device to be shielded is not unique, that is, Figure 4 As shown, both device 4 and device 5 are sub-devices of the extended device to be shielded, then the state ratings of device 4 and device 5 are compared, and if the state rating of device 4 is less than the state rating of device 5, the state rating of device 4 is put into Figure 5 The process shown uses that as long as the current state value of the extension device to be shielded is less than the state rating value of device 4 or less than the state rating value of device 1, the state detection result of the extension device to be shielded is determined to be normal, otherwise, further judgment is performed.
[0111] Furthermore, in one embodiment, when it is determined that the current status value is less than the status rated value of the parent device and the status rated value of the child device, it can be judged whether the current status value is less than the status setting value of the root device; when it is determined that the current status value is not less than the status setting value of the root device, it is determined that the status detection result of the extended device to be shielded is normal.
[0112] The status judgment data set also includes the status setting value of the root device.
[0113] It should be noted that the status setting value of the root device is set by the user according to the actual status requirements. If the current status value of the extended device to be shielded is not less than the status setting value of the root device, it is determined that this is an artificially set rate reduction or bandwidth reduction behavior, and therefore the status detection result of the extended device to be shielded is determined to be normal.
[0114] Accordingly, in one embodiment, when it is determined that the current state value is less than the state setting value of the root device, it is determined that the state detection result of the to-be-shielded extended device is abnormal.
[0115] Specifically, if through a series of comparisons, it is determined that the current state value of the extension device to be shielded is less than the state setting value of the root device, it is determined that the extension device to be shielded has an abnormal speed reduction phenomenon or an abnormal bandwidth reduction phenomenon, and therefore the state detection result of the extension device to be shielded is determined to be abnormal.
[0116] On the basis of the above embodiments, relevant personnel shield the unique identifiers such as DeviceID, VendorID, SubSystemID, SubVendorID of the PCIe device reporting an error in the code as needed to determine this device. When entering the speed reduction and bandwidth reduction judgment process, if the current status value of this device (including Speed rate and Width bandwidth) read is equal to the given rated value, then the BMC will not be reported that this device has a speed reduction or bandwidth reduction problem. For different types of PCIe devices that need to shield errors, the information needs to be written into the code one by one. Whenever there is a new such situation, the code needs to be modified to recompile the available firmware, and a series of version release processes are required to provide the available firmware to the demander, which greatly affects the availability of the firmware version, and its update speed is limited by the maintenance cycle of the firmware version.
[0117] The embodiment of the present application is to further solve the above technical problem. As an implementable method, in one embodiment, according to the preset state expected value of each extended device to be shielded, a shielding information table of the server is created, including:
[0118] Step 3031, creating a shielding information original table in the basic input and output system of the server;
[0119] Step 3032: Write the expected value of the preset state of each extended device to be shielded and the unique identifier of each extended device to be shielded into the shielding information original table to obtain the shielding information table of the server.
[0120] Specifically, you can set an option "Shielding Information Table" in the BIOS menu, which provides 5 to 10 sub-options. Each sub-option contains the DID (S0), VID (S1), SSID (S2), SVID (S3), preset rate expected value (S4), and preset bandwidth expected value (S5) of the PCIe device. Information can be entered for each sub-option. After completion, the shielding information table is saved in the NVRAM area of the Flash chip where the BIOS firmware is located.
[0121] Among them, DID stands for DeviceID, VID stands for VendorID, SSID stands for SubSystemID, SVID stands for SubVendorID, and DeviceID, VendorID, SubSystemID, and SubVendorID are unique identifiers of the extended device to be shielded.
[0122] It should be noted that each option on the BIOS Setup page (menu) will have its own unique MapString. Through MapString, you can use in-band tools such as SCETOOL to uniquely determine the option, so as to enter the known PCIe device information (S1~S5) into the option "shield information table" or the "shield information original table" in an empty table state through terminal commands or scripts. Another way is to enter the BIOS Setup page and manually enter information for the option. The input information will be stored in the specified NVRAM area in the form of Variable.
[0123] Specifically, in one embodiment, the current state value of each expansion device in the server can be monitored; when the current state value of any expansion device is obtained through monitoring, it is determined whether the unique identifier of the expansion device is recorded in the shielding information table; when the unique identifier of the expansion device is recorded in the shielding information table, it is determined that the current state value of any expansion device to be shielded in the shielding information table is obtained through monitoring, so as to perform the step of determining the state detection result of the expansion device to be shielded according to the size relationship between the current state value of the expansion device to be shielded and the preset state expected value corresponding to the expansion device to be shielded.
[0124] For example, Figure 6As shown, it is a flow chart of another exemplary method for detecting the state of an extended device provided by an embodiment of the present application. When the speed reduction and bandwidth reduction judgment code is run, the data in the option "shielding information table" is obtained through the UEFI general API-getVariable. When all current PCIe devices are traversed and checked, the S0, S1, S2, and S3 information of the current device are first obtained, and matched with the values in the shielding information table. If the S0, S1, S2, and S3 of the current device are exactly the same as the information of a certain sub-item in the shielding information table, then it is considered that this is a shielded extended device that needs to be shielded with a false alarm, that is, the current state value of any shielded extended device in the shielding information table is determined to be obtained by monitoring. Further, S4 and S5 of the current extended device to be shielded are compared with the sub-item information in the shielding information table. When S4 is the same, the speed reduction behavior judgment process of the device is skipped, and when S5 is the same, the bandwidth reduction behavior judgment process of the device is skipped, that is, the state detection result of the current extended device to be shielded is determined to be normal. Otherwise, further judgment is performed to adopt a further speed reduction and bandwidth reduction judgment process, and so on, until the state detection of all extended devices in the server is completed.
[0125] Specifically, if Figure 5 The speed reduction and bandwidth reduction judgment process shown in the figure determines that the status detection result of the current expansion device to be shielded is abnormal. The current expansion device to be shielded is used as an abnormal expansion device. The device information (asset information) of the abnormal expansion device is reported to the BMC through the IPMI command. The BMC will match the asset information sent by the BIOS and directly display the location information of the device. At the same time, the BMC will report the abnormality in the log to realize the abnormal alarm of the expansion device.
[0126] Accordingly, in one embodiment, when the unique identification record of the expansion device is not in the shielding information table, the state rating of the expansion device is obtained; and the state detection result of the expansion device is determined based on the size relationship between the current state value of the expansion device and the state rating of the expansion device.
[0127] Specifically, when the unique identification record of the expansion device is not in the shielding information table, the expansion device is determined to be an ordinary expansion device, and therefore a status detection is performed on it using the status rated value. If the current status value of the ordinary expansion device is lower than the status rated value, then the status detection result of the ordinary expansion device is determined to be abnormal, otherwise, it is normal.
[0128] Furthermore, in one embodiment, since it takes a lot of time and effort for maintenance personnel to conduct detailed physical troubleshooting on expansion devices with abnormal status detection results, in order to further improve the maintenance efficiency of the server and reduce maintenance costs, when it is determined that the status detection result of any expansion device is normal, the CPU usage of the server can be viewed using a system monitoring tool. If the CPU usage is always high, it may affect the performance of the PCIe device. CPU resources can be released by shutting down unnecessary processes or services to improve the status values of the PCIe device, such as the rate and bandwidth.
[0129] Accordingly, you can also check the memory usage of the server to ensure that there is enough available memory. Insufficient memory may cause system performance to degrade, including the rate and bandwidth of PCIe devices. You can consider increasing memory or optimizing memory usage. In addition, PCIe devices communicate with the server through the bus, so the availability of bus bandwidth is also important. Understand the bus architecture and bandwidth limitations of the server, and ensure that no other devices or processes occupy excessive bus bandwidth. In addition to PCIe devices, other I / O devices on the server (such as hard disks, network interfaces, etc.) may also have an impact on system resources. Check the I / O load of these devices to ensure that they are not overly competing for resources to ensure that the rate and bandwidth of the PCIe device are not reduced.
[0130] The method for detecting the state of an extended device provided in the embodiment of the present application obtains the attribute information of each extended device in the server; according to the attribute information of each extended device, the extended device to be shielded is screened; wherein, the extended device to be shielded performs normal speed reduction operation or bandwidth reduction operation under the influence of the influencing factors; according to the preset state expected value of each extended device to be shielded, a shielding information table of the server is created; wherein, the preset state expected value is less than the state rated value of the extended device to be shielded; when the current state value of any extended device to be shielded in the shielding information table is obtained by monitoring, the state detection result of the extended device to be shielded is determined according to the size relationship between the current state value of the extended device to be shielded and the preset state expected value corresponding to the extended device to be shielded. The method provided by the above scheme improves the accuracy of the state detection result of the extended device to be shielded by screening the extended device to be shielded and performing state detection on the extended device to be shielded based on the preset state expected value. Moreover, under the premise of keeping the BIOS firmware version unchanged, different numbers and types of PCIe devices can be shielded and the speed reduction and bandwidth reduction error reporting can be performed. When a new PCIe device with a known speed reduction and bandwidth reduction false alarm behavior is introduced, the existing firmware version can be used, and the specific information of the device only needs to be filled in the "shielding information table". Server manufacturers can enter the devices that will have false alarms into the shielding information table in advance to avoid maintenance personnel spending a lot of energy to troubleshoot problems due to false alarms. At the same time, if the user encounters such problems with the PCIe device introduced by the user, he can also enter the device information to shield it by himself, without the need for the server manufacturer to develop new BIOS firmware to support it. This greatly reduces the maintenance manpower and time costs and reduces code maintenance.
[0131] An embodiment of the present application provides an expansion device status detection apparatus, which is used to execute the expansion device status detection method provided in the above embodiment.
[0132] like Figure 7 , which is a schematic diagram of the structure of an extended device status detection device provided in an embodiment of the present application. The extended device status detection device 70 comprises: an acquisition module 701 , a screening module 702 , a creation module 703 and a detection module 704 .
[0133] Among them, the acquisition module is used to obtain the attribute information of each extension device in the server; the screening module is used to screen the extension devices to be shielded according to the attribute information of each extension device; wherein the extension devices to be shielded perform normal reduced rate operation or reduced bandwidth operation under the influence of the influencing factors; the creation module is used to create a shielding information table of the server according to the preset state expected value of each extension device to be shielded; wherein the preset state expected value is less than the state rated value of the extension device to be shielded; the detection module is used to determine the state detection result of the extension device to be shielded according to the size relationship between the current state value of the extension device to be shielded and the preset state expected value corresponding to the extension device to be shielded when the current state value of any extension device to be shielded in the shielding information table is monitored.
[0134] Regarding the expansion device status detection device in this embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0135] The expansion device status detection device provided in the embodiment of the present application is used to execute the expansion device status detection method provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.
[0136] An embodiment of the present application provides a server for executing the extension device status detection method provided in the above embodiment.
[0137] like Figure 8 FIG. 8 is a schematic diagram of the structure of a server provided in an embodiment of the present application. The server 80 includes a basic input and output system (BIOS) 801 and a plurality of expansion devices 802 .
[0138] Wherein, the basic input and output system performs status detection on the plurality of expansion devices based on the expansion device status detection method provided in the above embodiment to obtain the status detection result of each expansion device.
[0139] The server provided in the embodiment of the present application is used to execute the extended device status detection method provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.
[0140] An embodiment of the present application provides an electronic device, which is used to execute the extended device status detection method provided in the above embodiment.
[0141] like Fig. 9 FIG. 1 is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. The electronic device 90 includes: at least one processor 91 and a memory 92.
[0142] The memory stores computer-executable instructions; the at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the method for detecting the state of an expansion device provided in the above embodiment.
[0143] The electronic device provided in the embodiment of the present application is used to execute the extended device status detection method provided in the above embodiment. Its implementation method and principle are the same and will not be repeated here.
[0144] An embodiment of the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the expansion device status detection method provided in any of the above embodiments is implemented.
[0145] The storage medium containing computer executable instructions provided in the embodiment of the present application can be used to store computer executable instructions of the expansion device status detection method provided in the aforementioned embodiment. Its implementation method and principle are the same and will not be repeated here.
[0146] An embodiment of the present application provides a computer program product, including computer instructions, wherein the computer instructions are used to enable a computer to execute the expansion device status detection method provided in the aforementioned embodiment.
[0147] The embodiment of the present application provides a computer program product that can be used to execute computer instructions of the expansion device status detection method provided in the aforementioned embodiment. The implementation method and principle are the same and will not be repeated here.
[0148] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0149] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0150] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional units.
[0151] The above-mentioned integrated unit implemented in the form of a software functional unit can be stored in a computer-readable storage medium. The above-mentioned software functional unit is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) or a processor to perform some steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program codes.
[0152] A part of the present application may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of computer program instructions in computer-readable media includes, but is not limited to, source files, executable files, installation package files, etc., and accordingly, the way in which computer program instructions are executed by a computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to the computer.
[0153] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example for illustration. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. The specific working process of the device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0154] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for detecting an extended device status, characterized in that: include: Get the attribute information of each extended device in the server; According to the attribute information of each of the extension devices, the extension devices to be shielded are screened; wherein the extension devices to be shielded perform normal reduced rate operation or reduced bandwidth operation under the influence of the influencing factors; the attribute information of the extension devices at least includes its firmware version information, and the firmware version information at least represents the device operation strategy; Creating a shielding information table of the server according to the preset state expected value of each of the to-be-shielded extended devices; wherein the preset state expected value is less than the state rated value of the to-be-shielded extended device; When the current state value of any of the to-be-shielded extended devices in the shielding information table is obtained through monitoring, the state detection result of the to-be-shielded extended device is determined according to the magnitude relationship between the current state value of the to-be-shielded extended device and the preset state expected value corresponding to the to-be-shielded extended device; The step of determining the state detection result of the extension device to be shielded according to the magnitude relationship between the current state value of the extension device to be shielded and the expected value of the preset state corresponding to the extension device to be shielded includes: When it is determined that the current state value is lower than the preset state expected value, obtaining a state judgment data set of the to-be-shielded extended device; Determine the state detection result of the extension device to be shielded according to the size relationship between the current state value of the extension device to be shielded and each state judgment index in the state judgment data set; The current state value includes at least a current rate value and a current bandwidth value, and the preset state expected value includes at least a preset rate expected value and a preset bandwidth expected value; The step of obtaining a state determination data set of the to-be-shielded extended device includes: Obtaining location information of the extended device to be shielded; Locating the parent device, child device and root device of the extended device to be shielded in the server according to the location information of the extended device to be shielded; Acquire the state rating value of the parent device, the state rating value of the child device and the state setting value of the root device to obtain a state judgment data set of the extended device to be shielded; The step of determining the state detection result of the extension device to be shielded according to the size relationship between the current state value of the extension device to be shielded and each state judgment index in the state judgment data set includes: Determining whether the current state value is less than a state rating value of a parent device or a state rating value of a child device; In the case where it is determined that the current state value is not less than the state rating value of the parent device or the state rating value of the child device, determining that the state detection result of the to-be-shielded extended device is normal; Wherein, the state judgment data set includes the state rating value of the parent device and the state rating value of the child device; In the case where it is determined that the current state value is less than the state rating value of the parent device and the state rating value of the child device, determining whether the current state value is less than the state setting value of the root device; In the case where it is determined that the current state value is not less than the state setting value of the root device, determining that the state detection result of the to-be-shielded extended device is normal; The state judgment data set also includes a state setting value of the root device, and the state setting value of the root device is set by the user according to actual state requirements; In the case where it is determined that the current state value is less than the state setting value of the root device, determining that the state detection result of the to-be-shielded extended device is abnormal; The step of creating the shielding information table of the server according to the preset state expected value of each of the to-be-shielded extended devices comprises: Creating a shielding information original table in the basic input and output system of the server; The preset state expected value of each of the expansion devices to be shielded and the unique identifier of each of the expansion devices to be shielded are written into the shielding information original table to obtain the shielding information table of the server; the shielding information table is stored in the NVRAM area of the Flash chip where the BIOS firmware is located.
2. The method according to claim 1, characterized in that The method further comprises: In the case where it is determined that the current state value is equal to the preset state expected value, it is determined that the state detection result of the to-be-shielded extension device is normal.
3. The method according to claim 1, characterized in that The step of screening the extension devices to be shielded according to the attribute information of each extension device includes: For any of the expansion devices, judging, according to the attribute information of the expansion device, whether the state value of the expansion device changes according to the load or according to the driver version; If the status value of the expansion device changes according to the load or according to the driver version, the expansion device is regarded as an expansion device to be shielded.
4. The method according to claim 1, characterized in that: The method further comprises: Monitoring the current status value of each expansion device in the server; When the current state value of any extended device is obtained through monitoring, determining whether the unique identifier of the extended device is recorded in the shielding information table; In the case where the unique identification of the extension device is recorded in the shielding information table, the current state value of any one of the extension devices to be shielded in the shielding information table is determined by monitoring, so as to execute the step of determining the state detection result of the extension device to be shielded according to the size relationship between the current state value of the extension device to be shielded and the expected value of the preset state corresponding to the extension device to be shielded.
5. The method according to claim 4, characterized in that The method further comprises: In the case that the unique identification record of the extension device is not in the shielding information table, obtaining a state rating value of the extension device; The state detection result of the expansion device is determined according to the magnitude relationship between the current state value of the expansion device and the state rated value of the expansion device.
6. A server, characterized in that: include: Basic input and output system and several expansion devices; The basic input and output system performs status detection on the plurality of expansion devices based on the expansion device status detection method according to any one of claims 1 to 5 to obtain a status detection result of each expansion device.
7. An electronic device, characterized in that: include: at least one processor and memory; The memory stores computer-executable instructions; The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor performs the method according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and when the processor executes the computer-executable instructions, the method according to any one of claims 1 to 5 is implemented.
9. A computer program product, characterized in that The method comprises computer instructions for causing a computer to execute the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
RAID inspection method and device, electronic equipment and readable storage medium
CN110659135A
Storage server fault SAS physical link shielding device and method
CN114281639A
PCIe equipment degradation detection method and device, terminal and storage medium
CN115801540A
Method and device for diagnosing long-term shutdown interruption
CN116932270A
PCIe fatal error rapid positioning method and system, electronic equipment and medium
CN118550747A
