An optimal low energy consumption maintenance method, device, equipment and medium
By calculating the ratio of the adjustment time interval of the fan speed to the adjustment time interval, the fan speed is obtained in real time and the fan speed is adjusted according to the overall energy consumption, the problem of difficult fan regulation in the existing technology is solved, and the optimal low energy consumption maintenance of the fan under different conditions is achieved.
Patent Information
- Application Number
- CN202211199946.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-29
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2042-09-29
AI Technical Summary
In the prior art, it is difficult to achieve optimal energy consumption in different models and load ranges in fan control, and requires a lot of testing and experiments, which wastes manpower and material resources.
By obtaining pre-set energy consumption parameters, calculate the ratio of the adjustment time interval to the fan speed regulation time interval, obtain the fan speed in real time, calculate the average energy consumption based on the overall energy consumption, and adjust the fan speed to maintain the optimal low energy consumption.
The optimal low energy consumption maintenance of fans under different conditions is achieved, human and material resources are saved, and the accuracy and efficiency of energy consumption regulation are improved.
Smart Images

Figure CN115494930B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to an optimal low-energy consumption maintaining method, device, equipment and medium. Background Art
[0002] Currently, BMC (Baseboard Management Controller) is a unique management controller for servers. BMC can automatically monitor the operating status of the server and make adjustments according to the current status in a timely manner. One of its main functions is to adjust the speed of the cooling fan to cool the server. With the widespread use of servers, their low-energy design is becoming more and more important. The current fan control strategy can only achieve optimal energy consumption in specific models and specific load ranges, and a large amount of testing and experimental work is required in the early stage of implementation, which seriously wastes human and material resources.
[0003] At present, the fan control strategy defined based on the heat dissipation status of a specific model, the industry-wide PID (Proportional-Integral-Derivative) speed control can achieve the minimum fan speed on the basis of satisfying the heat dissipation of the entire server, but this minimum speed does not correspond to the optimal energy consumption of the server. After the fan speed is increased, the system's CPU (central processing unit), memory and other key components may have a smaller energy consumption value due to the drop in temperature, so the energy consumption of the entire machine may also be lower, so it is necessary to further improve the fan control mechanism.
[0004] In summary, how to maintain the optimal low energy consumption of the fan is a problem that needs to be solved urgently. Summary of the invention
[0005] In view of this, the purpose of the present invention is to provide an optimal low energy consumption maintenance method, device, equipment and medium, which can maintain the optimal low energy consumption of the fan. The specific scheme is as follows:
[0006] In a first aspect, the present application discloses an optimal low energy consumption maintenance method, comprising:
[0007] Obtaining preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval;
[0008] Determine whether the energy consumption parameter is valid, and if valid, calculate the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times;
[0009] When the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions, the fan speed is obtained in real time based on the control time interval, and if the fan speed is the same for the target number of consecutive times, the current total energy consumption of the whole machine at the adjustment time interval is calculated, and the current average energy consumption at the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times;
[0010] If the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the process proceeds to the step of obtaining the fan speed in real time based on the control time interval;
[0011] If the current average energy consumption is not the first average energy consumption, then calculating the energy consumption difference between the current average energy consumption and the previous average energy consumption;
[0012] Based on the energy consumption difference and according to the target adjustment range, the fan speed is increased or decreased, and the process jumps to the step of obtaining the fan speed in real time based on the control time interval to ensure that the fan maintains optimal low energy consumption in real time.
[0013] Optionally, after acquiring the fan speed in real time based on the control time interval, the method further includes:
[0014] If the air inlet temperature is unstable, resulting in the fan speed currently being obtained being different from the fan speed previously obtained, or other temperatures not satisfying the fan speed control degree that satisfies the preset conditions, the optimal low energy consumption maintenance process is exited.
[0015] Optionally, obtaining a preset energy consumption parameter includes:
[0016] The fan control program obtains the preset energy consumption parameters from the power-off non-volatile storage chip.
[0017] Optionally, before obtaining the preset energy consumption parameters, the method further includes:
[0018] Acquire an IPMI command with the energy consumption parameter set through the BMC, parse the IPMI command, and determine whether the energy consumption parameter is valid through the BMC;
[0019] If valid, storing the energy consumption parameter in the power-off non-volatile storage chip;
[0020] If invalid, an error code is returned.
[0021] Optionally, after determining whether the energy consumption parameter is valid, the step further includes:
[0022] If invalid, the step of calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times is prohibited.
[0023] Optionally, if the fan speeds are the same for the target number of consecutive times, calculating the current total energy consumption of the entire machine at the adjustment time interval includes:
[0024] If the fan speed is the same for the target number of consecutive times, the current whole machine energy consumption at each of the control time intervals is calculated, and the current whole machine energy consumption at the target number of times is calculated to obtain the current whole machine total energy consumption at the adjustment time interval.
[0025] Optionally, the increasing or decreasing the fan speed based on the energy consumption difference and according to the target adjustment range includes:
[0026] If the energy consumption difference is not less than zero, the fan speed is increased according to the target adjustment range;
[0027] If the energy consumption difference is less than zero, the fan speed is reduced according to the target adjustment range.
[0028] In a second aspect, the present application provides an optimal low energy consumption maintenance device, comprising:
[0029] A parameter acquisition module, used to acquire preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval;
[0030] A judgment module, used for judging whether the energy consumption parameter is valid, and if valid, calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times;
[0031] An energy consumption calculation module is used to obtain the fan speed in real time based on the control time interval when the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions; if the fan speed is the same for the target number of consecutive times, calculate the current total energy consumption of the whole machine at the adjustment time interval; and calculate the current average energy consumption at the control time interval based on the current total energy consumption of the whole machine and the target number of times;
[0032] A first speed adjustment module, configured to increase the fan speed based on a target adjustment range if the current average energy consumption is the average energy consumption obtained for the first time, and jump to the step of acquiring the fan speed in real time based on the control time interval;
[0033] A difference calculation module, configured to calculate the energy consumption difference between the current average energy consumption and the previous average energy consumption if the current average energy consumption is not the first average energy consumption obtained;
[0034] The second speed adjustment module is used to increase or decrease the fan speed based on the energy consumption difference and according to the target adjustment range, and jump to the step of obtaining the fan speed in real time based on the control time interval to ensure that the fan maintains optimal low energy consumption in real time.
[0035] In a third aspect, the present application discloses an electronic device, comprising a processor and a memory; wherein, when the processor executes a computer program stored in the memory, the optimal low-energy consumption maintaining method disclosed above is implemented.
[0036] In a fourth aspect, the present application discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, the optimal low-energy consumption maintaining method disclosed above is implemented.
[0037] It can be seen that the present application obtains a preset energy consumption parameter; the energy consumption parameter includes a flag and an adjustment time interval; determines whether the energy consumption parameter is valid, and if valid, calculates the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times; when the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions, the fan speed is obtained in real time based on the control time interval, and if the fan speed is the same for consecutive target times, the current total energy consumption of the whole machine under the adjustment time interval is calculated, and the current average energy consumption under the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times; if the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the step of obtaining the fan speed in real time based on the control time interval is jumped; if the current average energy consumption is the average energy consumption obtained for a non-first time, the energy consumption difference between the current average energy consumption and the previous average energy consumption is calculated; based on the energy consumption difference and according to the target adjustment range, the fan speed is increased or decreased, and the step of obtaining the fan speed in real time based on the control time interval is jumped to ensure that the fan maintains the optimal low energy consumption in real time. From the above, it can be seen that the present application calculates in real time the average energy consumption corresponding to each adjustment time interval under the control time interval based on the fan speed, and adjusts the fan speed according to the average energy consumption, which can automatically maintain the optimal low energy consumption and achieve energy conservation and emission reduction; in addition, the process of calculating the average energy consumption improves accuracy and reduces the impact of a certain low or high energy consumption on the fan speed adjustment. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0039] Figure 1 A flow chart of an optimal low energy consumption maintenance method provided for this application;
[0040] Figure 2A schematic diagram of an optimal low energy consumption maintenance method provided in this application;
[0041] Figure 3 A specific optimal low energy consumption maintenance method flow chart provided for this application;
[0042] Figure 4 A structural diagram of an optimal low-energy consumption holding device provided for this application;
[0043] Figure 5 A structural diagram of an electronic device provided for this application. DETAILED DESCRIPTION
[0044] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0045] The current fan control strategy can only achieve optimal energy consumption in specific models and specific load ranges, and a large amount of testing and experimental work is required in the early stage of implementation, which seriously wastes human and material resources; in addition, the fan control strategy defined based on the heat dissipation status of a specific model, the industry's common PID speed regulation can achieve the minimum fan speed on the basis of satisfying the heat dissipation of the entire server, but since this minimum speed does not correspond to the optimal energy consumption of the server. After the fan speed is increased, the system's key components such as the CPU and memory may have a smaller energy consumption value due to the drop in temperature, and the energy consumption of the entire machine may also be lower, so it is necessary to further improve the fan control mechanism.
[0046] In order to overcome the above problems, the present application provides an optimal low energy consumption maintenance solution, which can maintain the optimal low energy consumption of the fan.
[0047] See also Figure 1 As shown, the embodiment of the present application discloses an optimal low energy consumption maintenance method, which includes:
[0048] Step S11: obtaining preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval.
[0049] In the embodiment of the present application, the method of obtaining the preset energy consumption parameters includes: obtaining the preset energy consumption parameters from the power-off non-volatile storage chip through the fan control program. It should be noted that before obtaining the preset energy consumption parameters, it also includes: obtaining the IPMI (Intelligent Platform Management Interface) command with the energy consumption parameters set through the BMC, parsing the IPMI command and judging whether the energy consumption parameters are valid through the BMC; if valid, storing the energy consumption parameters in the power-off non-volatile storage chip; if invalid, returning an error code. It should be noted that the present application first performs "sending the IPMI command for setting automatic energy consumption optimization", and sending the command can set whether the server performs automatic energy consumption optimization and the time interval for automatic energy consumption optimization. After receiving the command, the BMC parses and judges whether the set energy consumption automatic optimization flag and the energy consumption automatic optimization time interval are valid. If valid, the above parameters are stored in the power-off non-volatile storage chip. If invalid, an error code is returned to prompt the server operation and maintenance personnel that the setting is wrong.
[0050] It should be pointed out that IPMI is an industrial standard for managing peripheral devices used in Intel-based enterprise systems. Users can use IPMI to monitor the physical health characteristics of the server, such as temperature, voltage, fan operating status, power status, etc., and can also develop their own commands to set or read server control parameters. The BMC program can perform corresponding operations based on IPMI commands.
[0051] It should be noted that the adjustment time interval can be changed at any time based on the IPMI command.
[0052] In the embodiment of the present application, after "sending the IPMI command for setting automatic optimization of energy consumption", the automatic optimization setting parameters of energy consumption are read, that is, when the server is powered on, the fan control program reads the set automatic optimization parameters of energy consumption (energy consumption parameters) gOptimizeFlag (optimization flag) and gOptimizeInterval (optimization time interval or adjustment time interval) from the power-off non-volatile storage chip.
[0053] Step S12: determining whether the energy consumption parameter is valid; if valid, calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times.
[0054] In the embodiment of the present application, it is determined whether the energy consumption parameter is valid. If it is valid, the ratio of the adjustment time interval to the control time interval based on the fan speed is calculated to obtain the target number of times; if it is invalid, the step of calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times is prohibited. That is, after obtaining the identification bit and the adjustment time interval (optimization time interval), first determine whether the above energy consumption parameter is valid: if it is invalid, it is considered that the parameter is not set, and the optimal low energy consumption maintenance process is prohibited, but the fan control is performed according to the automatic optimization of energy consumption that is not enabled (using the existing method to perform fan control); if it is valid, the next step of calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times (that is, "energy consumption automatic optimization parameter initialization"), and the subsequent "fan speed control data collection" is performed according to the parameter. It can be understood that through the above process, the present application can be set to not perform automatic optimization of energy consumption or perform automatic optimization of energy consumption (optimal low energy consumption maintenance).
[0055] It should be noted that the target number of times (i.e., "initialization of automatic optimization parameters for energy consumption") is obtained by calculating the ratio of the adjustment time interval to the control time interval based on the fan speed. Specifically, the number of cycles (target number) of recording and accumulating the energy consumption of the whole machine is calculated according to the following formula:
[0056] gRecordCycles=gOptimizeInterval / (FAN_CTRL_INTERVAL);
[0057] Among them, gRecordCycles is the number of cycles (target number of times), gOptimizeInterval is the adjustment time interval value set, and FAN_CTRL_INTERVAL is the control time interval of the BMC to control the fan.
[0058] Step S13: When the temperature of the fan inlet is stable and other temperatures satisfy the preset conditions for the fan speed control, the fan speed is obtained in real time based on the control time interval. If the fan speed is the same for the target number of consecutive times, the current total energy consumption of the whole machine at the adjustment time interval is calculated, and the current average energy consumption at the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times.
[0059] In an embodiment of the present application, after the fan speed is obtained in real time based on the control time interval, it also includes: if the air inlet temperature is unstable, causing the currently obtained fan speed to be different from the previously obtained fan speed or other temperatures do not meet the preset conditions for the fan speed control, then the optimal low energy consumption maintenance process is exited.
[0060] It should be pointed out that the specific process of "fan speed control data collection" in this application is as follows: under the premise that the current speed of the fan meets the heat dissipation requirements of the system, only the air inlet temperature InletTemp linearly controls the fan in the system, and when the value of the air inlet temperature InletTemp is stable, the corresponding fan speed control output is also a stable value, and the PWM for PID curve control of other temperatures are all values not greater than 0. After the fan speed regulated by the air inlet temperature InletTemp is stable for a certain number of cycles, calculate whether the current fan speed control PWM value is stable, and check whether the fan speed control PWM value has stabilized for the corresponding number of cycles; if the number of stable times of the fan speed control PWM value has not reached the corresponding number of cycles and is still in a stable stage, that is, deltaFanPwm=0, then continue to accumulate the number of stable times to the number of cycles; if the number of stable cycles of the fan speed control PWM value has reached the corresponding number of cycles, then perform "whole machine energy consumption accumulation and average energy consumption calculation", and start the accumulation of the whole machine energy consumption value and the calculation of the average energy consumption value; if deltaFanPwm≠0 or the PWM regulated by the PID curve is greater than 0 in this step, then stop the optimal low energy consumption maintenance process, therefore, the present application can immediately exit the energy consumption automatic optimization function when there is an air inlet temperature change or the temperature of the key components (other temperatures) participates in the regulation, thus ensuring the normal heat dissipation of the server, and thus ensuring the normal operation of the server. It should be pointed out that PWM and deltaFanPwm represent the difference in fan speed between the two modulation time intervals.
[0061] It should be pointed out that the process of checking whether the fan speed control PWM value has stabilized for the corresponding number of cycles is as follows: within the corresponding number of cycles, in each fan control cycle, the current fan speed control value gFanPwmCur is assigned to the previous fan speed control value gFanPwmPre, and the new fan control value is assigned to gFanPwmCur, and the fan speed control value gFanCtrlPwm at this time is recorded:
[0062] gFanPwmPre=gFanPwmCur;
[0063] gFanPwmCur = gLinePwm;
[0064] gFanCtrlPwm=gLinePwm;
[0065] deltaFanPwm=gFanPwmPre-gFanPwmCur.
[0066] It should be noted that the preset condition is that all PWM values for PID curve control at other temperatures are not greater than 0.
[0067] In an embodiment of the present application, if the fan speed is the same for the target number of consecutive times, the current total energy consumption of the whole machine at the adjustment time interval is calculated, including: if the fan speed is the same for the target number of consecutive times, the current energy consumption of the whole machine at each of the adjustment time intervals is calculated, and the current energy consumption of the whole machine at the target number of times is calculated to obtain the current total energy consumption of the whole machine at the adjustment time interval.
[0068] It should be noted that the process of "total energy consumption accumulation and average energy consumption calculation" is as follows: Read the system total energy consumption gTotalPowerVal in each fan control cycle i The energy consumption value is accumulated into gTotalPowerSumVal, and a total of gRecordCycles (target number) times is accumulated. Then the average value gAvrPowerVal is calculated to obtain the current average energy consumption:
[0069]
[0070] gAvrPowerVal=gTotalPowerSumVal / gRecordCycles;
[0071] Among them, gRecordCycles is the number of cycles (target number), gTotalPowerVal i is the current system energy consumption value read in the subsequent i-th fan control cycle, gTotalPowerSumVal is the current total energy consumption value of the whole system accumulated after gRecordCycles records, and gAvrPowerVal is the calculated current average energy consumption value.
[0072] Step S14: if the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the process jumps to the step of obtaining the fan speed in real time based on the control time interval.
[0073] In the embodiment of the present application, if gAvrPowerCur is obtained for the first time, the fan speed control value gFanCtrlPwm is increased by 1%. It should be noted that the target adjustment range is 1%.
[0074] Step S15: If the current average energy consumption is not the first average energy consumption obtained, then the energy consumption difference between the current average energy consumption and the previous average energy consumption is calculated.
[0075] In the embodiment of the present application, if it is not the first time to calculate the average energy consumption value of the whole machine, the difference of the average energy consumption value of the whole machine is calculated.
[0076] It should be noted that the process of step S14 and step S15 can be represented by the following content:
[0077] gAvrPowerPre=gAvrPowerCur;
[0078] gAvrPowerCur=gAvrPowerVal;
[0079] "if(("gAvrPowerCur≠0")&&(gAvrPowerPre=0))";
[0080] "then"{gFanCtrlPwm=gFanCtrlPwm+1};
[0081] else then{deltaAvrPower=gAvrPowerPre-gAvrPowerCur};
[0082] Among them, gAvrPowerPre is the current average energy consumption value of the last energy consumption optimization cycle, gAvrPowerCur is the current average energy consumption value of the current energy consumption optimization cycle, and deltaAvrPower is the difference in average energy consumption of the whole machine between the last and current energy consumption optimization cycles.
[0083] Step S16: Based on the energy consumption difference and in accordance with the target adjustment range, the fan speed is increased or decreased, and the process proceeds to the step of acquiring the fan speed in real time based on the control time interval to ensure that the fan maintains optimal low energy consumption in real time.
[0084] In an embodiment of the present application, after obtaining the energy consumption difference through "accumulating the energy consumption of the whole machine and calculating the average energy consumption", "optimizing the fan speed numerical calculation" is performed, that is, based on the energy consumption difference and according to the target adjustment range, the fan speed is increased or decreased, and the process jumps to the step of obtaining the fan speed in real time based on the control time interval, so as to ensure that the fan maintains the optimal low energy consumption in real time.
[0085] It should be noted that this application is based on Figure 2 The fan speed is adjusted to achieve optimal low energy consumption by following the steps of "Sending IPMI command to set automatic energy optimization", "Reading automatic energy optimization setting parameters", "Initializing automatic energy optimization parameters", "Collecting fan speed control data", "Calculating total power consumption and average power consumption" and "Calculating fan speed optimization values".
[0086] In the embodiment of the present application, 1. After a certain period of time after the fan speed control is stable, under the premise that only the linear control of the air inlet temperature is performed but no PID curve control is performed, the fan speed control value gFanCtrlPwm at this time is first recorded, and the energy consumption value of the whole machine at this time for gOptimizeCycle times is also recorded and accumulated, the current average energy consumption gAvrPowerCur is calculated, and the fan control speed gFanCtrlPwm is increased by 1%; 2. After increasing the fan speed and waiting for the fan speed to stabilize for a certain number of times, the current average energy consumption gAvrPowerCur is assigned to the previous average energy consumption gAvrPowerPre, and the energy consumption value of the whole machine at this time for gRecordCycles times is recorded and accumulated to calculate the new current average energy consumption gAvrPowerCur value; 3. The difference in average energy consumption values deltaAvrPower=gAvrPowerPre is calculated, and then the difference in average energy consumption deltaAvrPower is used to decide whether to increase or decrease the fan speed by 1% next time. Through the continuous cycle of the above three steps, the system will eventually reach the optimal energy consumption point where the energy consumption of key system components such as the CPU and memory is the lowest and the fan speed is also the lowest.
[0087] It should be pointed out that this application can automatically find the fan speed corresponding to the optimal energy consumption of the server for all models and all application scenarios. This application stores parameters such as whether to enable automatic energy consumption optimization flag and automatic optimization time interval set by IPMI command in a non-volatile storage chip. After the server is restarted or the BMC is upgraded, the fan can still be adjusted according to the previously set parameters. After a period of operation, the service power consumption can still be optimal without resetting.
[0088] It can be seen that the present application obtains a preset energy consumption parameter; the energy consumption parameter includes a flag and an adjustment time interval; determines whether the energy consumption parameter is valid, and if valid, calculates the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times; when the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions, the fan speed is obtained in real time based on the control time interval, and if the fan speed is the same for consecutive target times, the current total energy consumption of the whole machine under the adjustment time interval is calculated, and the current average energy consumption under the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times; if the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the step of obtaining the fan speed in real time based on the control time interval is jumped; if the current average energy consumption is the average energy consumption obtained for a non-first time, the energy consumption difference between the current average energy consumption and the previous average energy consumption is calculated; based on the energy consumption difference and according to the target adjustment range, the fan speed is increased or decreased, and the step of obtaining the fan speed in real time based on the control time interval is jumped to ensure that the fan maintains the optimal low energy consumption in real time. From the above, it can be seen that the present application calculates in real time the average energy consumption corresponding to each adjustment time interval under the control time interval based on the fan speed, and adjusts the fan speed according to the average energy consumption, which can automatically maintain the optimal low energy consumption and achieve energy conservation and emission reduction; in addition, the process of calculating the average energy consumption improves accuracy and reduces the impact of a certain low or high energy consumption on the fan speed adjustment.
[0089] See also Figure 3 As shown, the embodiment of the present application discloses a specific optimal low energy consumption maintenance method, which includes:
[0090] Step S21: obtaining preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval.
[0091] For a more specific processing procedure of step S21, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be described in detail here.
[0092] Step S22: determining whether the energy consumption parameter is valid; if valid, calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times.
[0093] For a more specific processing procedure of step S22, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be described in detail here.
[0094] Step S23: When the temperature of the fan inlet is stable and other temperatures satisfy the preset conditions for the fan speed control, the fan speed is obtained in real time based on the control time interval. If the fan speed is the same for the target number of consecutive times, the current total energy consumption of the whole machine at the adjustment time interval is calculated, and the current average energy consumption at the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times.
[0095] For a more specific processing procedure of step S23, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be described in detail here.
[0096] Step S24: if the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the process jumps to the step of obtaining the fan speed in real time based on the control time interval.
[0097] For a more specific processing procedure of step S24, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be described in detail here.
[0098] Step S25: If the current average energy consumption is not the first average energy consumption obtained, then the energy consumption difference between the current average energy consumption and the previous average energy consumption is calculated.
[0099] For a more specific processing procedure of step S25, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be described in detail here.
[0100] Step S26: If the energy consumption difference is not less than zero, the fan speed is increased according to the target adjustment range; if the energy consumption difference is less than zero, the fan speed is decreased according to the target adjustment range, and then the process jumps to the step of obtaining the fan speed in real time based on the control time interval to ensure that the fan maintains optimal low energy consumption in real time.
[0101] In the embodiment of the present application, if the calculated current average energy consumption deltaAvrPower is greater than or equal to 0, it means that the power consumption has decreased or has not increased after the fan speed control PWM value is increased. At this time, the fan speed control PWM value is increased by 1% again; if deltaAvrPower is less than 0, it means that the power consumption has increased after the fan speed control PWM value is increased. In the next regulation, the fan speed control PWM value is reduced by 1%, and then jump to the step of obtaining the fan speed in real time based on the regulation time interval to ensure that the fan maintains the optimal low energy consumption in real time.
[0102] It should be pointed out that the specific process can be expressed as follows:
[0103] "if("deltaAvrPower≥0")";
[0104] "then"{gFanCtrlPwm=gFanCtrlPwm+1};
[0105] else then{gFanCtrlPwm=gFanCtrlPwm-1}.
[0106] It can be understood that in the embodiment of the present application, the fan control value (current average energy consumption) is calculated according to a certain formula when enabling automatic optimization of server energy consumption, and then the value is applied to fan speed control. Under the premise of ensuring that the server's heat dissipation requirements are met, automatic optimization of the server's overall energy consumption is achieved, thereby achieving optimal overall energy consumption of the server during operation.
[0107] It can be seen that the present application obtains preset energy consumption parameters; the energy consumption parameters include a flag and an adjustment time interval; determines whether the energy consumption parameters are valid, and if valid, calculates the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times; when the fan air inlet temperature is stable and other temperatures satisfy the preset conditions for the fan speed control degree, when the fan air inlet temperature is stable and other temperatures satisfy the preset conditions for the fan speed control degree, the fan speed is obtained in real time based on the control time interval, and if the fan speed is the same for consecutive target times, the current total energy consumption of the whole machine under the adjustment time interval is calculated, and based on the current total energy consumption of the whole machine and the target number of times, the The current average energy consumption under the control time interval; if the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the step of obtaining the fan speed in real time based on the control time interval is jumped; if the current average energy consumption is not the average energy consumption obtained for the first time, the energy consumption difference between the current average energy consumption and the previous average energy consumption is calculated; if the energy consumption difference is not less than zero, the fan speed is increased according to the target adjustment range, if the energy consumption difference is less than zero, the fan speed is lowered according to the target adjustment range, and then the step of obtaining the fan speed in real time based on the control time interval is jumped to ensure that the fan maintains the optimal low energy consumption in real time. It can be seen from this that the present application calculates the average energy consumption corresponding to each adjustment time interval under the control time interval based on the fan speed in real time, and adjusts the fan speed according to the average energy consumption, which can automatically complete the maintenance of the optimal low energy consumption and achieve energy conservation and emission reduction; in addition, the process of calculating the average energy consumption improves the accuracy and reduces the impact of a certain low or high energy consumption on the fan speed adjustment.
[0108] See also Figure 4 As shown, the embodiment of the present application discloses an optimal low energy consumption maintaining device, comprising:
[0109] The parameter acquisition module 11 is used to acquire the preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval;
[0110] A judging module 12 is used to judge whether the energy consumption parameter is valid, and if it is valid, calculate the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times;
[0111] The energy consumption calculation module 13 is used to obtain the fan speed in real time based on the control time interval when the fan inlet temperature is stable and the fan speed control degree of other temperatures meets the preset conditions; if the fan speed is the same for the target number of consecutive times, the current total energy consumption of the whole machine at the adjustment time interval is calculated; and the current average energy consumption at the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times;
[0112] A first speed adjustment module 14 is configured to increase the fan speed based on a target adjustment range if the current average energy consumption is the average energy consumption obtained for the first time, and jump to the step of acquiring the fan speed in real time based on the control time interval;
[0113] A difference calculation module 15 is used to calculate the energy consumption difference between the current average energy consumption and the previous average energy consumption if the current average energy consumption is not the first average energy consumption obtained;
[0114] The second speed adjustment module 16 is used to increase or decrease the fan speed based on the energy consumption difference and according to the target adjustment range, and jump to the step of obtaining the fan speed in real time based on the control time interval to ensure that the fan maintains optimal low energy consumption in real time.
[0115] Among them, for more specific working processes of the above-mentioned modules, please refer to the corresponding contents disclosed in the aforementioned embodiments, which will not be repeated here.
[0116] It can be seen that the present application obtains a preset energy consumption parameter; the energy consumption parameter includes a flag and an adjustment time interval; determines whether the energy consumption parameter is valid, and if valid, calculates the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times; when the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions, the fan speed is obtained in real time based on the control time interval, and if the fan speed is the same for consecutive target times, the current total energy consumption of the whole machine under the adjustment time interval is calculated, and the current average energy consumption under the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times; if the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the step of obtaining the fan speed in real time based on the control time interval is jumped; if the current average energy consumption is the average energy consumption obtained for a non-first time, the energy consumption difference between the current average energy consumption and the previous average energy consumption is calculated; based on the energy consumption difference and according to the target adjustment range, the fan speed is increased or decreased, and the step of obtaining the fan speed in real time based on the control time interval is jumped to ensure that the fan maintains the optimal low energy consumption in real time. From the above, it can be seen that the present application calculates in real time the average energy consumption corresponding to each adjustment time interval under the control time interval based on the fan speed, and adjusts the fan speed according to the average energy consumption, which can automatically maintain the optimal low energy consumption and achieve energy conservation and emission reduction; in addition, the process of calculating the average energy consumption improves accuracy and reduces the impact of a certain low or high energy consumption on the fan speed adjustment.
[0117] Furthermore, an embodiment of the present application also provides an electronic device, Figure 5 This is a structural diagram of an electronic device 20 according to an exemplary embodiment. The content in the diagram cannot be regarded as any limitation on the scope of use of the present application.
[0118] Figure 5 The present invention provides a schematic diagram of the structure of an electronic device 20 provided in an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, an input / output interface 24, a communication interface 25, and a communication bus 26. The memory 22 is used to store a computer program, which is loaded and executed by the processor 21 to implement the relevant steps of the optimal low-energy consumption maintenance method disclosed in any of the aforementioned embodiments.
[0119] In this embodiment, the power supply 23 is used to provide working voltage for each hardware device on the electronic device 20; the communication interface 25 can create a data transmission channel between the electronic device 20 and the external device, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present application, and is not specifically limited here; the input and output interface 24 is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs and is not specifically limited here.
[0120] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, a random access memory, a disk or an optical disk, etc. The memory 22 can include a random access memory as a running memory and a non-volatile memory for external memory storage purposes. The storage resources thereon include an operating system 221, a computer program 222, etc., and the storage method can be temporary storage or permanent storage.
[0121] The operating system 221 is used to manage and control the hardware devices on the electronic device 20 on the source host and the computer program 222. The operating system 221 can be Windows, Unix, Linux, etc. In addition to including a computer program that can be used to complete the optimal low-energy consumption maintenance method performed by the electronic device 20 disclosed in any of the aforementioned embodiments, the computer program 222 can further include a computer program that can be used to complete other specific tasks.
[0122] In this embodiment, the input and output interface 24 may specifically include but is not limited to a USB interface, a hard disk reading interface, a serial interface, a voice input interface, a fingerprint input interface, and the like.
[0123] Furthermore, an embodiment of the present application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, the aforementioned optimal low-energy consumption maintaining method disclosed above is implemented.
[0124] For the specific steps of the method, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be described in detail here.
[0125] The computer-readable storage medium mentioned here includes random access memory (RAM), memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, register, hard disk, magnetic disk or optical disk or any other form of storage medium known in the technical field. Wherein, when the computer program is executed by the processor, the aforementioned optimal low-energy consumption maintenance method is implemented. For the specific steps of the method, reference can be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be repeated here.
[0126] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the optimal low energy consumption maintenance method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description.
[0127] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0128] The steps of the algorithm described in conjunction with the embodiments disclosed herein can be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module can be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0129] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0130] The above is a detailed introduction to an optimal low-energy consumption maintenance method, device, equipment and medium provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for general technical personnel in this field, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
Claims
1. An optimal low energy consumption maintenance method, It is characterized in that include: Obtaining preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval; Determine whether the energy consumption parameter is valid, and if valid, calculate the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times; When the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions, the fan speed is obtained in real time based on the control time interval, and if the fan speed is the same for the target number of consecutive times, the current total energy consumption of the whole machine at the adjustment time interval is calculated, and the current average energy consumption at the control time interval is calculated based on the current total energy consumption of the whole machine and the target number of times; If the current average energy consumption is the average energy consumption obtained for the first time, the fan speed is increased based on the target adjustment range, and the process proceeds to the step of obtaining the fan speed in real time based on the control time interval; If the current average energy consumption is not the first average energy consumption, then calculating the energy consumption difference between the current average energy consumption and the previous average energy consumption; Based on the energy consumption difference and according to the target adjustment range, the fan speed is increased or decreased, and the process proceeds to the step of acquiring the fan speed in real time based on the control time interval, so as to ensure that the fan maintains optimal low energy consumption in real time; Among them, after obtaining the fan speed in real time based on the control time interval, it also includes: if the air inlet temperature is unstable, resulting in the current fan speed being different from the previously obtained fan speed or other temperatures do not meet the preset conditions for the fan speed control, then exit the optimal low energy consumption maintenance process.
2. The optimal low energy consumption maintenance method according to claim 1, It is characterized in that The obtaining of the preset energy consumption parameters includes: The fan control program obtains the preset energy consumption parameters from the power-off non-volatile storage chip.
3. The optimal low energy consumption maintaining method according to claim 2, It is characterized in that Before obtaining the preset energy consumption parameters, the method further includes: Acquire an IPMI command with the energy consumption parameter set through the BMC, parse the IPMI command, and determine whether the energy consumption parameter is valid through the BMC; If valid, storing the energy consumption parameter in the power-off non-volatile storage chip; If invalid, an error code is returned.
4. The optimal low energy consumption maintaining method according to claim 1, It is characterized in that After determining whether the energy consumption parameter is valid, the method further includes: If invalid, the step of calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times is prohibited.
5. The optimal low energy consumption maintaining method according to claim 1, It is characterized in that If the fan speeds are the same for the target number of consecutive times, calculating the current total energy consumption of the whole machine at the adjustment time interval includes: If the fan speed is the same for the target number of consecutive times, the current whole machine energy consumption at each of the control time intervals is calculated, and the current whole machine energy consumption at the target number of times is calculated to obtain the current whole machine total energy consumption at the adjustment time interval.
6. The optimal low energy consumption maintaining method according to any one of claims 1 to 5, It is characterized in that The increasing or decreasing the fan speed based on the energy consumption difference and according to the target adjustment range includes: If the energy consumption difference is not less than zero, the fan speed is increased according to the target adjustment range; If the energy consumption difference is less than zero, the fan speed is reduced according to the target adjustment range.
7. An optimal low energy consumption maintenance device, It is characterized in that include: A parameter acquisition module, used to acquire preset energy consumption parameters; the energy consumption parameters include a flag bit and an adjustment time interval; A judgment module, used for judging whether the energy consumption parameter is valid, and if valid, calculating the ratio of the adjustment time interval to the control time interval based on the fan speed to obtain the target number of times; An energy consumption calculation module is used to obtain the fan speed in real time based on the control time interval when the temperature of the fan inlet is stable and the degree of fan speed control by other temperatures meets the preset conditions; if the fan speed is the same for the target number of consecutive times, calculate the current total energy consumption of the whole machine at the adjustment time interval; and calculate the current average energy consumption at the control time interval based on the current total energy consumption of the whole machine and the target number of times; A first speed adjustment module, configured to increase the fan speed based on a target adjustment range if the current average energy consumption is the average energy consumption obtained for the first time, and jump to the step of acquiring the fan speed in real time based on the control time interval; A difference calculation module, configured to calculate the energy consumption difference between the current average energy consumption and the previous average energy consumption if the current average energy consumption is not the first average energy consumption obtained; A second speed adjustment module is used to increase or decrease the fan speed based on the energy consumption difference and according to the target adjustment range, and jump to the step of obtaining the fan speed in real time based on the control time interval to ensure that the fan maintains optimal low energy consumption in real time; Among them, after obtaining the fan speed in real time based on the control time interval, it also includes: if the air inlet temperature is unstable, resulting in the current fan speed being different from the previously obtained fan speed or other temperatures do not meet the preset conditions for the fan speed control, then exit the optimal low energy consumption maintenance process.
8. An electronic device, It is characterized in that It comprises a processor and a memory; wherein, when the processor executes the computer program stored in the memory, the optimal low energy consumption maintaining method as described in any one of claims 1 to 6 is implemented.
9. A computer-readable storage medium, It is characterized in that Used to store computer programs; wherein, when the computer program is executed by a processor, the optimal low energy consumption maintaining method as described in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Efficient and energy-saving method for adjusting and controlling fans of SmartRack cabinet
CN105240303A
Heat dissipation method and heat dissipation device for electronic equipment
CN109843026A