CN117762221A - Server temperature control method and device, server and storage medium - Google Patents

Server temperature control method and device, server and storage medium Download PDF

Info

Publication number
CN117762221A
CN117762221A CN202311653064.7A CN202311653064A CN117762221A CN 117762221 A CN117762221 A CN 117762221A CN 202311653064 A CN202311653064 A CN 202311653064A CN 117762221 A CN117762221 A CN 117762221A
Authority
CN
China
Prior art keywords
server
temperature
prediction model
fan
predicted
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311653064.7A
Other languages
Chinese (zh)
Inventor
吴启标
耿梦达
尹明
王博
赵明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Yanxiang Intelligent Iot Software Co ltd
Original Assignee
Shenzhen Yanxiang Intelligent Iot Software Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Yanxiang Intelligent Iot Software Co ltd filed Critical Shenzhen Yanxiang Intelligent Iot Software Co ltd
Priority to CN202311653064.7A priority Critical patent/CN117762221A/en
Publication of CN117762221A publication Critical patent/CN117762221A/en
Pending legal-status Critical Current

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Control Of Temperature (AREA)

Abstract

The application relates to the technical field of servers and discloses a server temperature control method, which comprises the following steps: acquiring the temperature, the power and the rotating speed of a fan of a server at n+1 moments; inputting the server power and the fan rotation speed of the first n times of n+1 times into a prediction model to output the server predicted temperatures of the last n times of n+1 times; calculating the credibility value of the prediction model according to the server predicted temperature and the server temperature at the last n moments; judging whether the credibility value of the prediction model is smaller than or equal to a credibility threshold value; if yes, inputting the power of the server and the rotating speed of the fan at the current moment into a prediction model to output the predicted temperature of the server at the next moment at the current moment, and determining a temperature error according to the predicted temperature of the server at the next moment; if not, determining a temperature error according to the temperature of the server at the current moment; and determining a control parameter of the fan according to the temperature error. By the mode, the stability of the temperature of the server is improved.

Description

Server temperature control method and device, server and storage medium
Technical Field
The embodiment of the application relates to the technical field of servers, in particular to a server temperature control method, a device, a server and a storage medium.
Background
In the process of executing data storage and operation work, a CPU (Central Processing Unit, a central processing unit) and various electronic elements in a case consume electric energy and emit heat, and as the temperature in the case is continuously increased, the performance of the server is continuously reduced, and even unstable factors such as downtime of the server, over-temperature failure of the electronic elements and the like occur, so that the server is not beneficial to continuously and healthily work.
In the prior art, a step speed regulation method is commonly used for controlling the rotating speed of a server fan, so that the temperature inside a case is controlled. For example, the chinese patent literature divides the temperature of the server into certain intervals, and adjusts the duty ratio of the fan to different values under different intervals to control the rotational speed of the fan, so that the control strategy of the method is coarse and solidified, the condition of untimely temperature control is easy to occur, and the hysteresis of the temperature feedback of the server further amplifies the phenomenon of untimely temperature control, thereby increasing the degree of instability of the temperature of the server.
Disclosure of Invention
In view of the above problems, embodiments of the present application provide a method, an apparatus, a server, and a storage medium for controlling a server temperature, which improve stability of the server temperature.
According to an aspect of the embodiments of the present application, there is provided a server temperature control method, including: acquiring the temperature, the power and the rotating speed of a fan of a server at n+1 moments; inputting the power of the server and the rotation speed of the fan at the first n times of n+1 times into a prediction model, and outputting the predicted temperature of the server at the last n times of n+1 times by the prediction model; calculating the credibility value of the prediction model according to the server predicted temperature and the server temperature at the last n moments; judging whether the credibility value of the prediction model is smaller than or equal to a credibility threshold value; if yes, inputting the power of the server and the rotating speed of the fan at the current moment into a prediction model, outputting the predicted temperature of the server at the next moment at the current moment by the prediction model, and determining a temperature error according to the predicted temperature of the server at the next moment; wherein the current time is the last time of n+1 times; if not, determining a temperature error according to the temperature of the server at the current moment; and determining control parameters of the fan according to the temperature error so as to control the rotating speed of the fan to control the temperature of the server.
In an alternative manner, calculating the reliability value of the prediction model according to the predicted server temperature and the server temperature at the last n moments includes: calculating the absolute value of the difference between the server predicted temperature and the server temperature at each of the n times to obtain n absolute values; and calculating the sum of n absolute values, and calculating the ratio between the sum of the absolute values and n to obtain the credibility value of the prediction model.
In an alternative way, the server power and the fan rotation speed at the first n times of the n+1 times are input into a prediction model, and the predicted temperature of the server at the last n times of the n+1 times is output by the prediction model, including: inputting the server power and the fan rotating speed at the first n times into a prediction model to obtain initial predicted temperatures of the servers at the last n times; calculating the difference value between the server temperature at each of the n moments and the initial predicted temperature of the server by using the prediction model to obtain predicted temperature errors at the n moments; respectively compensating the predicted temperature errors of the first n-1 moments in the last n moments to the initial predicted temperatures of the servers in the last n-1 moments in the last n moments by using a prediction model, and outputting the predicted temperatures of the servers in the last n moments, wherein the predicted temperatures of the servers in the 1 st moment in the last n moments are equal to the initial predicted temperatures of the servers; inputting the server power and the fan rotating speed at the current moment into a prediction model, outputting the server predicted temperature at the moment next to the current moment by the prediction model, and further comprising: inputting the server power and the fan rotating speed at the current moment into a prediction model to obtain the initial predicted temperature of the server at the next moment; and compensating the predicted temperature error at the current moment to the initial predicted temperature of the server at the next moment by using the prediction model, and outputting the predicted temperature of the server at the next moment.
In an alternative way, before determining the temperature error according to the server temperature at the current time, the method further comprises: acquiring the server temperature, the server power and the fan rotating speed at N times before n+1 times; optimizing a prediction model according to the server temperature, the server power and the fan rotating speed at N moments; wherein the last of the N times is adjacent to the first of the n+1 times; the method further comprises the steps of: judging whether the server stops running or not; if not, the step is to obtain the server temperature, the server power and the fan rotating speed at n+1 times.
In an alternative way, the optimization prediction model according to the server temperature, the server power and the fan rotation speed at N times further includes: randomly generating N groups of optimization parameters, and setting the optimization times M; executing a circulation process until a preset condition is met, and judging whether the minimum objective function value in all the determined objective function values is smaller than an objective function threshold value or not when the preset condition is met; if yes, taking the prediction model updated by the optimization parameter corresponding to the minimum objective function value as the optimized prediction model, and turning to a step of determining a temperature error according to the temperature of the server at the current moment; if not, updating N groups of optimization parameters through the optimization parameters corresponding to the minimum preset number of objective function values in all the determined objective function values to obtain new N groups of optimization parameters, and turning to the step of executing a cyclic process until the preset condition is met, judging whether the minimum objective function value in all the determined objective function values is smaller than an objective function threshold value or not when the preset condition is met until the number of times of obtaining the new N groups of optimization parameters is greater than or equal to M, taking a prediction model updated by the optimization parameters corresponding to the minimum objective function value determined by the prediction model updated by the M th new N groups of optimization parameters as an optimized prediction model, and turning to the step of determining a temperature error according to the server temperature at the current moment; the cyclic process includes: updating the prediction model by using one of the N groups of unused optimization parameters; inputting the power of the server and the rotating speed of the fan at the front N-1 times in N times into an updated prediction model, and generating the predicted temperature of the server at the rear N-1 times in N times by the updated prediction model; determining objective function values corresponding to the set of optimization parameters according to the predicted temperatures of the servers at the later N-1 moments and the temperatures of the servers; wherein, the preset conditions are: the predictive model has been updated with all the optimization parameters.
In an alternative manner, after determining the temperature error according to the predicted temperature of the server at the next moment, the method further includes: determining a temperature error change rate according to the temperature error at the next moment; after determining the temperature error according to the server temperature at the current moment, the method further comprises: determining a temperature error change rate according to the temperature error at the current moment; determining a control parameter of the fan according to the temperature error to control the rotating speed of the fan to control the temperature of the server, and further comprising: inputting the temperature error and the temperature error change rate into a fuzzy variable domain controller, and outputting the adjustment quantity of the PID controller by the fuzzy variable domain controller; the adjustment amount is input into a PID controller, and the PID controller determines the control parameters of the fan, so that the PID controller controls the rotating speed of the fan according to the control parameters to control the temperature of the server.
In an alternative way, the temperature error and the temperature error change rate are input into the fuzzy variable domain controller, and the fuzzy variable domain controller outputs the adjustment amount of the PID controller, further comprising: determining an input expansion factor and an output expansion factor from a variable domain rule table according to the temperature error and the average power of the server at the last n moments; the temperature error, the temperature error change rate, the input expansion factor and the output expansion factor are input into a fuzzy variable domain controller; by the fuzzy variable domain controller: determining the membership of the temperature error from the membership function of the temperature error according to the temperature error and the input telescopic factor, and determining the membership of the temperature error change rate from the membership function of the temperature error change rate according to the temperature error change rate and the input telescopic factor; determining the membership degree of fuzzy control from a fuzzy control rule table according to the membership degree of the temperature error and the membership degree of the temperature error change rate; determining fuzzy control quantity from the fuzzy control membership function according to the fuzzy control membership; and outputting the adjustment quantity of the PID controller according to the fuzzy control quantity and the output expansion factor.
According to another aspect of the embodiments of the present application, there is provided a server temperature control apparatus, including: the acquisition module is used for acquiring the server temperature, the server power and the fan rotating speed at n+1 moments; the input module is used for inputting the power of the server and the rotating speed of the fan at the first n times of n+1 times into the prediction model, and outputting the predicted temperature of the server at the last n times of n+1 times by the prediction model; the calculation module is used for calculating the credibility value of the prediction model according to the server prediction temperatures and the server temperatures at the last n moments; the judging module is used for judging whether the credibility value of the prediction model is smaller than or equal to a credibility threshold value; the first determining module is used for inputting the power of the server and the rotating speed of the fan at the current moment into the prediction model when the reliability value of the prediction model is smaller than or equal to the reliability threshold value, outputting the predicted temperature of the server at the next moment at the current moment by the prediction model, and determining a temperature error according to the predicted temperature of the server at the next moment; wherein the current time is the last time of n+1 times; the second determining module is used for determining a temperature error according to the server temperature at the current moment when the credibility value of the prediction model is larger than the credibility threshold value; and the third determining module is used for determining control parameters of the fan according to the temperature error so as to control the rotating speed of the fan to control the temperature of the server.
According to another aspect of the embodiments of the present application, there is provided a server including: the device comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface are communicated with each other through the communication bus; the memory is used to store executable instructions that cause the processor to perform the operations of the server temperature control method provided by any of the embodiments described above.
According to still another aspect of the embodiments of the present application, there is provided a computer-readable storage medium having stored therein executable instructions that cause a server to perform the operations of the server temperature control method provided by any of the embodiments described above.
In the embodiment of the application, the power of the server and the rotating speed of the fan at the first n times in n+1 times are input into the prediction model, so that the prediction model can output the predicted temperatures of the server at the last n times in n+1 times, then, the reliability value of the prediction model is calculated through the predicted temperatures of the server at the last n times and the actual temperatures of the server, when the reliability value is smaller than or equal to the reliability threshold, the predicted temperature of the server at the next time in the current time is output by using the prediction model, and according to the predicted temperature of the server at the next time, the temperature error is calculated by using the temperature of the server at the current time when the reliability value is larger than the reliability threshold, and finally, the rotating speed of the fan can be controlled by determining the control parameters of the fan through the temperature error, so that the temperature of the server is controlled. By the method, the prediction model can be well verified by utilizing the historical operation data of the server, so that the temperature control strategy can be flexibly switched, the accuracy of temperature control is improved, and the stability of the temperature of the server is ensured.
The foregoing description is only an overview of the technical solutions of the embodiments of the present application, and may be implemented according to the content of the specification, so that the technical means of the embodiments of the present application can be more clearly understood, and the following detailed description of the present application will be presented in order to make the foregoing and other objects, features and advantages of the embodiments of the present application more understandable.
Drawings
The drawings are only for purposes of illustrating embodiments and are not to be construed as limiting the application. Also, like reference numerals are used to designate like parts throughout the figures. In the drawings:
fig. 1 is a schematic flow chart of a server temperature control method according to an embodiment of the present application;
FIG. 2 is a schematic flow chart of substeps of step 120 in FIG. 1;
FIG. 3 is a schematic flow chart of substeps of step 150 in FIG. 1;
FIG. 4 is a schematic flow chart of a method for controlling server temperature according to an embodiment of the present application;
FIG. 5 is a schematic flow chart of the substep of step 159 in FIG. 4;
fig. 6 is a schematic flow chart of a server temperature control method according to an embodiment of the present application;
FIG. 7 is a domain contraction schematic;
FIG. 8 is a schematic flow chart of the substeps of step 171 of FIG. 6;
fig. 9 is a schematic control flow diagram of the fuzzy variable domain controller provided in the present application;
FIG. 10 is a membership function chart of the fuzzy variable domain controller temperature error provided by the present application;
fig. 11 is a schematic structural diagram of a server temperature control device according to an embodiment of the present application;
fig. 12 is a schematic structural diagram of a server according to an embodiment of the present application.
Detailed Description
Exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present application are shown in the drawings, it should be understood that the present application may be embodied in various forms and should not be limited to the embodiments set forth herein.
The development of modern information technology is not separated from servers providing high-performance computing and storage functions. The server needs 24 hours to run in a special server room, and continuously performs data storage and operation, in the process, a CPU and various electronic elements in the server case consume electric energy and emit heat, and the performance of the server is continuously reduced along with the continuous rising of the temperature in the case, and even unstable factors such as downtime of the server, over-temperature failure of the electronic elements and the like occur, so that the continuous and healthy operation of the server is not facilitated. The temperature control system in the server case has hysteresis characteristics, which often causes that the temperature control system cannot observe the temperature rise of the server in time, and the control effect is not in time, and in the period of time, the performance of the server is adversely affected due to the temperature rise.
The temperature control method of the server is usually PID control (Proportional Integral Derivative control ), that is, a control deviation is formed according to a given value and an actual output value, and the deviation is formed into a control quantity by linear combination according to proportion, integral and derivative, so as to control a controlled object to realize temperature control. The conventional PID controller is widely used for industrial process control as a linear controller due to simple algorithm, good robustness and high reliability. However, since the internal temperature model of the server is complex and is a nonlinear time-varying system, it is difficult to adapt to the temperature control of the server under any working condition through a set of PID values, and therefore, it is necessary to ensure that the hysteresis of the temperature control can be compensated or predicted in time.
In the prior art, a full-power operation method, a grading speed regulation method and a closed-loop PID speed regulation method are commonly used for controlling the rotating speed of a server fan, so that the temperature inside a case is controlled. The full power operation method, that is, the fan outputs the maximum power to obtain the maximum rotation speed, has the best heat dissipation effect, but the long-time full power operation of the fan has huge electric energy loss, reduces the service life of the fan and ensures high maintenance cost of the server. The control mode of the method is general, the electric energy loss is large, the hysteresis of temperature feedback cannot be processed, the temperature control is not timely, and the system stability is poor. The closed-loop PID speed regulation method adopts a PID algorithm to carry out closed-loop control on the temperature, but the feedback of the temperature has hysteresis, and the PID algorithm can not solve the problem well.
In some schemes for controlling the temperature of the server by a hierarchical speed regulation control method, the temperature of the server is divided into a certain section, and under different sections, the duty ratio of the fan is adjusted to different values to control the rotation speed of the fan. Further, due to the generalization of the dividing sections, when the temperature of the server is near a certain threshold value, the rotation speed of the fan cannot be increased when the temperature of the server is slightly smaller than the threshold value, so that the temperature continues to be increased, and the rotation speed of the fan cannot be increased until the next threshold value, so that the temperature control is not timely; when the temperature of the server is slightly higher than the threshold value, the rotating speed of the fan is immediately increased, and the waste of power consumption is easily caused. Moreover, as the server temperature feedback has hysteresis, under the condition that the temperature is not controlled timely in the control strategy, the hysteresis can amplify the phenomenon of the untimely temperature control.
In some schemes for controlling the temperature of the server by using a PID control mode, hysteresis caused by temperature cannot be well compensated because the temperature of the main board is not predicted, the temperature and the heat dissipation coupling degree of various components in the server case are deep, the heat exchange environment is complex, and the rapidity and the stability of the server can not be well ensured when the environment changes or disturbance exists by a PID algorithm, so that the temperature overshoot is easily caused by using the PID control, and the stability of the temperature of the server is not facilitated.
In other schemes, when the server is pressurized suddenly, the power operator is used to calculate the compensation quantity of the fan rotating speed, and finally the compensation quantity is summed with the increment of the fan rotating speed generated by the increment type PID algorithm to obtain the total control quantity to realize the temperature control of the server. The control method senses the temperature change in advance through the power of the server chip and compensates the control quantity of the fan, thereby playing a certain compensation effect. However, it is not appropriate to directly compensate the rotation speed through the power of the server chip, and consideration of the current rotation speed on the heat dissipation performance of the system is ignored. Although the server is pressurized and depressurized, the rising and falling trend of the temperature of the main board can be reflected to a certain extent, when the period of time of the power change of the server chip is very short, the effect of the trend becomes very weak, the fan speed regulation is very sensitive, noise is generated, and the power consumption is increased. In addition, the power operator provided by the method is obtained through an empirical method, and historical operation data of the server cannot be well utilized to optimize the model, so that the temperature control effect is not ideal. Further, although the method adopts a PID controller, the PID controller is easy to cause larger overshoot of the temperature, and the temperature of the server cannot be well stabilized.
Based on the above, the application provides a server temperature control method, which is used for verifying the credibility of a server temperature prediction model based on the server historical temperature, the historical power and the fan historical rotating speed, then determining a temperature error according to the temperature predicted by the server temperature prediction model when the credibility of the prediction model meets the requirement, and determining the temperature error according to the actual temperature of the server when the credibility of the prediction model does not meet the requirement, so that the control parameters of the fan are determined by using the temperature error, and the rotating speed of the fan is controlled to realize the control of the server temperature. By the method, the prediction model can be well verified by utilizing the historical operation data of the server, so that the temperature control strategy can be flexibly switched, the accuracy of temperature control is improved, and the stability of the temperature of the server is ensured.
Fig. 1 shows a flow chart of a method for controlling the temperature of a server according to an embodiment of the present application, where the method may be executed by the server, or may be executed by a controller independent of the server, and control parameters of a fan of the server are output to the server through the controller. The method of the present embodiment is described below by taking a server as an example, and as shown in fig. 1, the method includes the steps of:
Step 110: and acquiring the server temperature, the server power and the fan rotating speed at n+1 moments.
The server temperature control method provided by the application operates on a BMC (Baseboard Management Controller ) chip of a server main board, the BMC chip can read the server temperature, the server power and the fan rotating speed at n+1 moments and store the read data, and n is a positive integer. The server may be provided with 6 system fans with the same specification, and no CPU (Central Processing Unit ) fan is provided, so that the CPU radiates heat by guiding wind generated by the system fans into the cooling fins of the CPU. And the temperature feedback sensors are arranged near the bridge pieces (namely the south bridge and the north bridge), the memory, the hard disk and the CPU of the server main board, and the temperature of the server can be determined according to the temperature fed back by each sensor. In addition, the server power is the power obtained after the power source power rejects all fan power, wherein the power source can be read through a PMBUS bus (Power Management Bus ), the fan power can be calculated through the hardware characteristics of the power source, and the fan rotating speed can be determined through the fan power. The server temperature, the server power, and the fan rotation speed at a time may be a server average temperature, a server average power, and a fan average rotation speed including a sampling period at the time, or may be a server reference temperature, a server reference power, and a fan reference rotation speed at the time obtained by calculation.
Step 120: the power of the server and the rotation speed of the fan at the first n times of n+1 times are input into a prediction model, and the prediction model outputs the predicted temperature of the server at the last n times of n+1 times.
The prediction model may be a temperature prediction model optimized according to an intelligent swarm algorithm, such as a genetic algorithm, a particle swarm algorithm, an ant colony algorithm, a whale algorithm, or a wolf algorithm, or an improved algorithm according to the above algorithm, which is only illustrated by way of example and not limitation.
Specifically, when other factors are unchanged, the fan rotation speed and the server temperature are in a linear relation, and the server power and the server temperature are also in a linear function relation, so that a prediction model can be obtained as follows:
tp (t+1) =av (t) +bp (t) +c, equation 1
Wherein a, b, c are parameters optimized according to the wolf algorithm, v (t) is the fan rotation speed at the current moment, p (t) is the server power at the current moment, and Tp (t+1) is the server predicted temperature at the moment next to the current moment.
Therefore, the read server power and fan rotation speed at the first n times of the n+1 times are sequentially input into the prediction model, and the prediction model sequentially outputs the server predicted temperatures at the last n times of the n+1 times, that is, the server temperatures at the last n times each have the corresponding server predicted temperatures.
Step 130: and calculating the credibility value of the prediction model according to the server predicted temperature and the server temperature at the last n moments.
The server predicted temperatures at the last n times and the server temperatures at the last n times are used as test data of a prediction model, and the reliability value of the prediction model can be calculated, so that the reliability of the prediction model can be judged according to the reliability value. Specifically, the server temperature at each time and the corresponding server predicted temperature are taken as a set of test data, and the server temperatures at the last n times and the server predicted temperatures at the last n times form n sets of test data, so that in order to improve the accuracy of the reliability value, the reliability value of the prediction model is calculated by taking the server temperatures at the last n times and the server predicted temperatures at the last n times as the test data.
Specifically, for the latter n times, calculating the absolute value of the difference between the server temperature at each time and the corresponding server predicted temperature, thereby obtaining n absolute values, then accumulating the n absolute values to obtain the sum of the n absolute values, and finally calculating the ratio between the sum of the n absolute values and the n, thereby obtaining the reliability value K of the prediction model, wherein the calculation formula of the reliability value K is as follows:
Wherein n is the number of test groups of the server temperature and the server predicted temperature,predicting a temperature for a server of the j-th set of test data, for>Server temperature for the j-th set of test data.
Step 140: judging whether the credibility value of the prediction model is smaller than or equal to a credibility threshold value, if so, executing step 150; if not, go to step 160.
It should be noted that, the confidence value K is compared with a preset confidence threshold K 0 The smaller the confidence value K, the higher the confidence of the predictive model. If the value of the credibility value K is smaller than or equal to the credibility threshold K 0 I.e. K.ltoreq.K 0 When the prediction accuracy of the prediction model meets the requirement, that is, the server temperature at the next time of the current time can be predicted by using the prediction model, step 150 is executed; if the value of the credibility value K is larger than the credibility threshold K 0 I.e. K > K 0 If the prediction accuracy of the prediction model does not meet the requirement, that is, if the server temperature at the time next to the current time cannot be predicted using the prediction model, step 160 is executed.
Step 150: inputting the server power and the fan rotating speed at the current moment into a prediction model, outputting the server predicted temperature at the next moment at the current moment by the prediction model, and determining a temperature error according to the server predicted temperature at the next moment; wherein the current time is the last time of the n+1 times.
When the value of the credibility value K is smaller than or equal to the credibility threshold K 0 When the server power and the fan rotation speed at the current moment, namely the last moment of n+1 moments, are input into a prediction model, and then the prediction model outputs the server predicted temperature at the moment next to the current moment. And then, calculating the difference between the predicted temperature of the server at the next moment and the preset target temperature to obtain a temperature error e at the next moment, wherein the target temperature is the ideal temperature when the server operates.
Step 160: and determining a temperature error according to the server temperature at the current moment.
When the value of the credibility value K is larger than the credibility threshold K 0 And calculating the difference between the server temperature at the current moment and the target temperature to obtain a temperature error e at the next moment.
Step 170: and determining control parameters of the fan according to the temperature error so as to control the rotating speed of the fan to control the temperature of the server.
When the temperature error is calculated, the temperature error is used as the input of the PID controller, the PID controller calculates according to the functional relation of proportion, integration and differentiation, the control parameter of the fan can be determined, when the PID controller calculates the control parameter, the control quantity of the fan can be obtained, and then the PID controller sends PWM (Pulse Width Modulation ) signals to the fan to change the rotating speed of the fan, so that the temperature of the server is reduced, and the temperature of the server is controlled.
In the embodiment of the application, the power of the server and the rotating speed of the fan at the first n times in n+1 times are input into the prediction model, so that the prediction model can output the predicted temperatures of the server at the last n times in n+1 times, then, the reliability value of the prediction model is calculated through the predicted temperatures of the server at the last n times and the temperatures of the server, when the reliability value is smaller than or equal to the reliability threshold value, the predicted temperature of the server at the next time in the current time is output by using the prediction model, and according to the predicted temperature of the server at the next time, the temperature error is calculated by using the temperature of the server at the current time when the reliability value is larger than the reliability threshold value, and finally, the rotating speed of the fan can be controlled by determining the control parameters of the fan through the temperature error, so that the temperature of the server is controlled. By the method, the prediction model can be well verified by utilizing the historical operation data of the server, so that the temperature control strategy can be flexibly switched, the accuracy of temperature control is improved, and the stability of the temperature of the server is ensured.
In some schemes, the temperature of the server chassis is predicted by adopting a neural network mode, then the predicted temperature is used as the input of a PID controller, and finally the control quantity of the fan is output to regulate the temperature of the server. For a complex system, the prediction accuracy of the neural network gradually decreases over time, and the method does not adopt an effective prediction error feedback strategy, i.e. does not provide treatment measures after a large error occurs in the prediction accuracy of the neural network, such as acquiring the latest data set again for training and testing, if a large prediction error occurs, the prediction value is still adopted as a control input, which results in inaccurate prediction temperature, so that the stability of the temperature of the server is greatly reduced, and unavoidable power consumption is wasted.
Thus, in order to improve the accuracy of the temperature error and thus the stability of the server temperature, according to some embodiments of the present application, optionally, fig. 2 is a schematic flow chart of the substeps of the above step 120 of the present application, and fig. 3 is a schematic flow chart of the substeps of the above step 150 of the present application. As shown in fig. 2, the step 120 includes the following steps:
step 121: and inputting the server power and the fan rotating speed at the first n times into a prediction model to obtain the initial predicted temperature of the server at the last n times.
Step 122: and calculating the difference value between the server temperature at each of the n times and the initial predicted temperature of the server by the prediction model to obtain the predicted temperature errors at the n times.
Step 123: and respectively compensating the predicted temperature errors of the first n-1 moments in the last n moments to the initial predicted temperatures of the servers in the last n-1 moments in the last n moments by using a prediction model, and outputting the predicted temperatures of the servers in the last n moments, wherein the predicted temperatures of the servers in the 1 st moment in the last n moments are equal to the initial predicted temperatures of the servers.
As shown in fig. 3, the above step 150 includes the steps of:
step 151: and inputting the server power and the fan rotating speed at the current moment into a prediction model to obtain the initial predicted temperature of the server at the next moment.
Step 152: and compensating the predicted temperature error at the current moment to the initial predicted temperature of the server at the next moment by using the prediction model, outputting the predicted temperature of the server at the next moment, and determining the temperature error according to the predicted temperature of the server at the next moment.
In the temperature prediction process, the predicted temperature of the server predicted by the prediction model cannot be guaranteed to be completely consistent with the actual temperature of the server, and the predicted temperature of the server predicted by the prediction model can be considered to be effective within the reliability threshold based on the judgment strategy of the reliability value, so that a certain error exists between the predicted temperature of the server and the actual temperature of the server. Over time, the accumulation of errors will become larger and larger, so that the speed at which the reliability value of the prediction model exceeds the reliability threshold value is increased, that is, the speed at which the prediction model needs to be re-optimized is increased, so that in order to improve the reliability of the prediction model, the error of the prediction temperature at the previous moment is compensated to the initial prediction temperature of the server at the current moment predicted by the prediction model, and the accumulation of errors can be reduced, thereby avoiding the premature failure of the prediction model.
Firstly, the server power and the fan rotation speed of the first n times of n+1 times are input into a prediction model, the prediction model outputs the initial predicted temperatures of the servers of the last n times of n+1 times, and further, the prediction model calculates the difference between the initial predicted temperatures of the servers of the last n times and the temperatures of the servers of the last n times, so that the predicted temperature error e of the last n times can be obtained p And in the latter n moments, the initial predicted temperature of the server at each moment corresponds to the predicted temperature error one by one. Predicted temperature error e p The calculation formula of (2) is as follows:
e p =T p (t-1)-T a (t-1), equation 3
Wherein e p Representing the predicted temperature error, T p (T-1) represents the initial predicted temperature of the server at the time immediately preceding the current time, T a (t-1) represents the server temperature at the time immediately preceding the current time.
Then, the prediction model calculates the calculated predicted temperature errors e at the last n moments p And sequentially compensating the initial predicted temperatures of the servers at the last n-1 times in the last n times to obtain the predicted temperatures of the servers at the last n-1 times, and taking the predicted temperatures of the servers at the 1 st time in the last n times as the initial predicted temperatures of the servers at the 1 st time to obtain the predicted temperatures of the servers at the last n times. Wherein, the temperature compensation formula is as follows:
T p (t)=T pc (t)+e p equation 4
Wherein T is pc (T) represents the initial predicted temperature of the server at the current time, T p And (t) represents the predicted temperature of the server at the current time.
And finally, inputting the server power and the fan rotating speed at the current moment into a prediction model, obtaining the initial predicted temperature of the server at the next moment at the current moment by the prediction model, and calculating the initial predicted temperature of the server at the current moment and the initial predicted temperature of the server at the last 1 moment in the last n moments output by the prediction model as the initial predicted temperature of the server at the current moment, and then compensating the predicted temperature error at the current moment to the initial predicted temperature of the server at the next moment by the prediction model, outputting the predicted temperature of the server at the next moment, and finally calculating the temperature error according to the predicted temperature of the server at the next moment.
The server predicted temperature is obtained by compensating the predicted temperature error of the previous moment to the initial predicted temperature of the server at the current moment, so that the error between the server predicted temperature and the server temperature at each moment can be effectively reduced, the error accumulated by a prediction model is reduced, the reliability of the prediction model is improved, the accuracy of the server predicted temperature at the next moment is further improved, the accuracy of the temperature error is improved, and the server temperature is more accurately controlled.
In order to improve reliability of the prediction model, according to some embodiments of the present application, optionally, referring to fig. 4, fig. 4 is a schematic flow chart of a server temperature control method provided in an embodiment of the present application, as shown in the figure, the foregoing step 160 includes the following steps:
step 158: and acquiring the server temperature, the server power and the fan rotating speed at N times before n+1 times.
Step 159: optimizing a prediction model according to the server temperature, the server power and the fan rotating speed at N moments; wherein the last of the N times is adjacent to the first of the N +1 times.
The step 170 includes the following steps:
step 180: judging whether the server stops running, if not, turning to step 110; if yes, ending.
When the reliability value of the prediction model is larger than the reliability threshold, the prediction model is unreliable, and optimization is needed according to historical data until the reliability value of the prediction model is smaller than or equal to the reliability threshold, so that the optimized prediction model is continuously used for predicting the temperature of the server in the subsequent time.
Firstly, in order to improve the optimization effect, the BMC chip reads the server temperature, the server power and the fan rotating speed at N times before n+1 times, and optimizes the prediction model according to the server temperature, the server power and the fan rotating speed at N times to obtain an optimized prediction model.
And then, when the temperature error is calculated according to the temperature of the server at the current moment, and after the control parameter of the fan is determined based on the temperature error to control the rotating speed of the fan, the BMC chip judges whether the server stops running or not based on the data read by the power bus, if so, the temperature control of the server is stopped, and if not, the temperature of the server, the power of the server and the rotating speed of the fan at n+1 moments are obtained and are used as test data to test the credibility value of the prediction model.
By the method, the prediction model can be continuously re-optimized when the prediction model does not meet the reliability requirement, and the reliability of the prediction model is improved, so that the server prediction temperature at the next moment can be accurately predicted by continuously using the optimized prediction model in the later time, and the stability of the server temperature is improved.
In order to optimize the prediction model, according to some embodiments of the present application, optionally, fig. 5 is a schematic flow chart of sub-steps of the above step 159 of the present application, as shown in the figure, the above step 159 includes the following steps:
step 159a: randomly generating N groups of optimization parameters, and setting the optimization times M.
Step 159b: the predictive model is updated with one of the N sets of optimization parameters that is unused.
Step 159c: and inputting the power of the server and the rotating speed of the fan at the first N-1 times in N times into an updated prediction model, and generating the predicted temperature of the server at the last N-1 times in N times by the updated prediction model.
Step 159d: and determining the objective function value corresponding to the set of optimization parameters according to the predicted server temperature and the server temperature at the last N-1 moments.
Step 159e: it is determined whether the predictive model has been updated with all of the optimization parameters. If yes, go to step 159f, if no, go to step 159b.
Step 159f: and judging whether the smallest objective function value in all the determined objective function values is smaller than an objective function threshold. If yes, go to step 159g, if not, go to step 159h.
Step 159g: and taking the prediction model updated by the optimization parameter corresponding to the minimum objective function value as the optimized prediction model, and turning to step 160.
Step 159h: updating the N groups of optimization parameters through the optimization parameters corresponding to the minimum preset number of objective function values in all the determined objective function values to obtain new N groups of optimization parameters, and turning to step 159b until the number of times of obtaining the new N groups of optimization parameters is greater than or equal to M, taking the prediction model updated by the optimization parameters corresponding to the minimum objective function values determined by the prediction model updated by the M-th new N groups of optimization parameters as an optimized prediction model, and turning to step 160.
First, from the predictive model equation T p As can be seen from (t+1) =av (t) +bp (t) +c, a, b, c are parameters to be optimized in the process of optimizing the prediction model, and the range of values is as follows:
a min ≤a≤a max ,b mmin ≤b≤b max ,c min ≤c≤c max
wherein a is min 、b min 、c min Representing the minimum values of the optimization parameters a, b, c, a, respectively max 、b max 、c max The maximum values of the optimization parameters a, b, c are indicated, respectively. Thus, N sets of optimization parameters are randomly generated, i.e. at the optimization parameters, respectivelya. And randomly generating N groups of optimization parameters a, b and c in the value range of b and c.
Then, the prediction model is updated by using the generated N groups of optimization parameters a, b and c, each group of optimization parameters a, b and c can be sequentially updated, and a group of optimization parameters a, b and c can be randomly extracted for updating on the premise of ensuring that each group of optimization parameters are not reused. After updating the prediction model by using one set of optimization parameters a, b and c to obtain an updated prediction model, the server power and the fan rotation speed at the previous N-1 time in N times are input into an updated prediction model formula, and the updated prediction model outputs the server prediction temperature at the next N-1 time in N times.
Then, the predicted temperatures of the servers at the last N-1 times and the temperatures of the servers at the last N-1 times are input into the objective function of the prediction model, so that the objective function value J corresponding to the set of optimization parameters can be determined, for example, after the prediction model is updated by using the first set of optimization parameters a, b and c, the objective function value J corresponding to the first set of optimization parameters a, b and c can be determined 1 . The objective function of the predictive model is as follows:
wherein,representing the server temperature at the i-th moment, a +.>A server predicted temperature indicating the i-th time, and T max ≤T P ≤T min ,T max ≤T a ≤T min Wherein T is max T is the upper limit value of the temperature of the server min Is the lower limit value of the server temperature.
After determining the objective function value J corresponding to one of the optimization parameters a, b, c, determining whether all the optimization parameters in the N groups of optimization parameters are usedThe number updates the predictive model. When the optimized parameters which are not used for updating the prediction model exist, continuously taking unused optimized parameters from N groups of optimized parameters to update the prediction model, inputting the server power and the fan rotating speed at the previous N-1 moments in N moments into an updated prediction model formula, outputting the server predicted temperature at the next N-1 moments in N moments by the updated prediction model into an objective function of the prediction model to calculate a new objective function value J, and continuously judging whether all the optimized parameters in the N groups of optimized parameters are used for updating the prediction model until all the optimized parameters in the N groups of optimized parameters are used for updating the prediction model … …; when the prediction model has been updated using all of the N sets of optimization parameters, the minimum objective function value J is determined from all of the objective function values J that have been calculated min And further judge the objective function value J min Whether or not it is smaller than a preset objective function threshold J 0
If the objective function value J min Less than the objective function threshold J 0 Then the objective function value J min And the prediction model updated by the corresponding optimization parameters is used as an optimized prediction model, and then the reliability of the optimized prediction model is verified by using the server temperature, the server power and the fan rotating speed at n+1 moments. If the objective function value J min Greater than or equal to the objective function threshold J 0 Firstly, determining the objective function value with the minimum preset number from all the calculated objective function values; then, based on a swarm intelligent algorithm, updating N groups of optimization parameters by using the determined optimization parameters a, b and c corresponding to the minimum preset objective function values respectively to obtain new N groups of optimization parameters a, b and c, for example, based on a wolf algorithm, 3 minimum objective function values can be determined from all objective function values, and then the N groups of optimization parameters are updated by using the optimization parameters a, b and c corresponding to the 3 minimum objective function values respectively; then, the new N groups of optimization parameters a, b and c are used in sequence to update the prediction model, and then the server power and the fan rotating speed at the previous N-1 time in N times are input into an updated prediction model formula, … …, until the prediction is finished The optimization times of the model is measured for M times, and the times of obtaining new N groups of optimization parameters are more than or equal to M; finally, updating the prediction model by using N groups of optimized parameters updated at the Mth time, and determining the minimum objective function value J min Then, the minimum objective function value J min And the prediction model updated by the corresponding optimization parameters is used as an optimized prediction model, and the reliability of the optimized prediction model is verified by using the server temperature, the server power and the fan rotating speed at n+1 moments.
By the method, the N groups of optimization parameters which are randomly generated and the server power and the fan rotating speed at the first N-1 moments in N moments can be used for generating the server predicted temperatures at the last N-1 moments according to the prediction model updated by the N groups of optimization parameters, so that the objective function value J can be determined from the objective function value J min The optimization parameters a, b, c of the predictive model can thus be determined to achieve optimization of the predictive model.
In order to improve the stability of the server temperature, according to some embodiments of the present application, optionally, fig. 6 is a schematic flow chart of a method for controlling the server temperature according to an embodiment of the present application, as shown in the figure, after the step 150, the method includes:
Step 150a: and determining the temperature error change rate according to the temperature error at the next moment.
Step 160 is followed by:
step 160a: and determining the temperature error change rate according to the temperature error at the current moment.
The step 170 includes the steps of:
step 171: the temperature error and the temperature error change rate are input into the fuzzy variable domain controller, and the fuzzy variable domain controller outputs the adjustment quantity of the PID controller.
Step 172: the adjustment amount is input into a PID controller, and the PID controller determines the control parameters of the fan, so that the PID controller controls the rotating speed of the fan according to the control parameters to control the temperature of the server.
Because of thermal coupling among various component temperatures in the server temperature, the control precision and control performance of the traditional PID controller are not ideal in the server temperature control, and the adjustment quantity of the PID controller determined by the fuzzy variable domain controller through a fuzzy logic algorithm can be automatically adjusted along with the change of the external environment, so that the intelligent temperature controller has self-adaptive characteristics, and the stability of temperature control can be ensured. Referring to fig. 7 specifically, fig. 7 shows a domain contraction schematic diagram, and when the feedback error is reduced under the premise of ensuring that the fuzzy rule is not modified, the domain range is narrowed so as to achieve the effect of increasing the control rule number, and the control precision is improved; in contrast, when the feedback error increases, the domain range increases, thereby achieving the effect of reducing the rule number, improving the convergence speed, and achieving better control accuracy compared with the traditional PID control.
Specifically, after determining the temperature error e by using the predicted temperature of the server at the next moment, calculating the difference between the predicted temperature of the server at the current moment and the target temperature to obtain the temperature error e at the current moment 1 . Then, calculate the temperature error e of the next moment and the temperature error e of the current moment 1 The difference (e-e 1 ) Then calculating the interval time T between the next time and the current time to obtain the temperature error change rate ec= (e-e) 1 ) T; when the temperature error e is determined by using the server predicted temperature at the current moment, calculating the difference between the server temperature at the moment immediately before the current moment and the target temperature to obtain the temperature error e at the moment immediately before the current moment 1 . Finally, calculating the temperature error e at the current moment and the temperature error e at the moment immediately before the current moment 1 The difference (e-e 1 ) Then calculating the interval duration T between the current time and the last time of the current time to obtain the temperature error change rate ec= (e-e) 1 )/T。
The embodiment of the application provides a 2-input 3-output fuzzy variable domain controller, wherein a temperature error e and a temperature error change rate ec are used as inputs of the fuzzy variable domain controller, and the proportional adjustment quantity delta k of a PID controller p Integral adjustment amount Δk i And differential adjustment amount Δk d As an output of the fuzzy variable domain controller. Temperature error e and temperature error change rateAfter ec is input into the fuzzy variable domain controller, the fuzzy variable domain controller performs fuzzification processing on the temperature error e and the temperature error change rate ec, then performs fuzzy reasoning according to a Mamdani algorithm, and after defuzzification processing is performed on a fuzzy reasoning result according to a gravity center method, the proportional adjustment quantity delta k of a more accurate PID controller can be output p Integral adjustment amount Δk i And differential adjustment amount Δk d Into a PID controller, and then the PID controller makes the ratio initial value k p0 Initial value of integral k i0 And a differential initial value k d0 Respectively and proportionally adjust the quantity delta k p Integral adjustment amount Δk i And differential adjustment amount Δk d By adding, the more accurate control parameter K of the fan can be obtained p 、K i And K d The calculation formula is as follows:
K p =k p0 +Δk p ,K i =k i0 +Δk i ,K d =k i0 +Δk d
after obtaining the control parameters of the fan, the PID controller is used for controlling the control parameters K of the fan p 、K i And K d By performing the operation, a more accurate control amount of the fan can be obtained, and then the PID controller can change the rotating speed of the fan and reduce the temperature of the server by sending the PWM signal to the fan. In this way, the control parameters of the fan output by the PID controller can be adaptively adjusted along with the temperature error and the temperature error change rate, so that the accurate control of the temperature of the server is realized.
In order to improve the accuracy of the adjustment amount of the PID controller, according to some embodiments of the present application, optionally, fig. 8 is a schematic flow chart of the substeps of the above step 171 of the present application, as shown in the figure, the above step 171 includes the following steps:
step 171a: and determining an input expansion factor and an output expansion factor from the variable domain rule table according to the temperature error and the average power of the server at the last n moments.
Step 171b: and inputting the temperature error, the temperature error change rate, the input expansion factor and the output expansion factor into the fuzzy variable domain controller.
Step 171c: and determining the membership of the temperature error from the membership function of the temperature error by the fuzzy variable domain controller according to the temperature error and the input telescopic factor, and determining the membership of the temperature error change rate from the membership function of the temperature error change rate according to the temperature error change rate and the input telescopic factor.
Step 171d: and determining the fuzzy control membership degree from the fuzzy control rule table by the fuzzy variable domain controller according to the membership degree of the temperature error and the membership degree of the temperature error change rate.
Step 171e: and determining the fuzzy control quantity from the fuzzy control membership function according to the fuzzy control membership by the fuzzy variable domain controller.
Step 171f: and outputting the adjustment quantity of the PID controller by the fuzzy variable domain controller according to the fuzzy control quantity and the output telescopic factor.
In the embodiment of the application, after the temperature error e and the temperature error change rate ec are calculated, the sum of the server powers at the n times after calculation is divided by n, and then the average power of the server at the n times after calculation can be obtained.
FIG. 9 is a schematic diagram showing a control flow of the fuzzy variable domain controller, wherein the temperature error e and the temperature error change rate ec are used as the inputs of the fuzzy variable domain controller, and the proportional adjustment quantity Deltak of the PID controller is shown in the diagram p Integral adjustment amount Δk i And differential adjustment amount Δk d As output of fuzzy variable domain controller, the average power P of the server at last n times ave And the temperature error e is used as a rule base of domain expansion factors. Based on the characteristics of PID control, the proportional adjustment amount Deltak p Differential adjustment amount Δk d Temperature error e and rate of change of temperature error ec and server average power P ave Positive correlation with temperature error e, integral adjustment Δk i Average power P with server ave The temperature error e is inversely related. Therefore, the control parameters of the fan output by the PID controller can be adaptively adjusted along with the change of the temperature and the power of the server, so that the robustness of the temperature control of the server is improved.
The input expansion factor is used for scaling up and down the input (temperature error e and temperature error change rate ec) of the fuzzy variable domain controller, and the output expansion factor is used for scaling up the initial output (proportional fuzzy control quantity delta k) of the fuzzy variable domain controller p0 Differential fuzzy control quantity delta k d0 And an integral fuzzy control quantity Delak i0 ) A scaling up and down is performed, which needs to be determined from the ranges of the temperature error e and the temperature error change rate ec.
First, the average power P of the server for the temperature error e and the last n times ave Partitioning is performed to determine a variant domain rule table. The partitions are as follows:
temperature error e, where e max Maximum value of temperature error:
temperature partition 1, use e 1 The representation is: [ -e max ,-0.7e max ]∪[0.7e max ,e max ],
Temperature partition 2, use e 2 The representation is: [ -0.7e max ,-0.4e max ]∪[0.4e max ,0.7e max ],
Temperature partition 3, use e 3 The representation is: [ -0.4e max ,0]∪[0,0.4e max ],
Server average power P ave Wherein P is max Maximum value of average power for server:
power partition 1, P 1 The representation is: [ -P max ,-0.7P max ]∪[0.7P max ,P max ],
Power partition 2, P 2 The representation is: [ -0.7P max ,-0.4P max ]∪[0.4P max ,0.7P max ],
Power partition 3, P 3 The representation is: [ -0.4P max ,0]∪[0,0.4P max ];
Input stretch factor alpha of temperature error e e Input stretch factor alpha of temperature error change rate ec ec Are both temperature error e and server average power P ave Which partition is dropped to, thereby Input expansion factor alpha for obtaining temperature error e e And a variable domain rule table of the temperature error change rate ec, refer to table 1 specifically. Wherein the input stretch factor alpha due to temperature error e e And the temperature error rate of change ec ec With temperature error e and server average power P ave Positive correlation, therefore, input the scaling factor alpha e And alpha ec The size of the liquid crystal display is smaller from left to right and from top to bottom.
Table 1: input of a scaling factor alpha eec Variable domain rule table of (a)
According to the parameter adjustment rule of the PID controller, a scale adjustment coefficient (output scaling factor can be obtained) And differential adjustment coefficient (output scaling factor +.>) See table 2 for details of the variable domain rule table. Wherein the larger the temperature error e or the average power P of the server ave The larger the scale factor is, the higher the scaling factor (output scaling factor +.>) And differential adjustment coefficient (output scaling factor +.>) To accelerate the response speed of the temperature control of the server, thus outputting the expansion factorAnd->Are all matched with the temperature error e and the average power P of the server ave Positive correlation, i.e. output of the scaling factor +.>And->The size of the liquid crystal display is smaller from left to right and from top to bottom.
Table 2: outputting a scale factorThe rule table of the transformation theory domain- >
According to the parameter adjustment rule of the PID controller, an integral adjustment coefficient (output expansion factor can be obtained) See table 3 for details of the variable domain rule table. Wherein the integral adjustment coefficient (output scaling factor +.>) The larger the response speed of the server temperature control is, the worse, and therefore, the stretch factor +.>And the size of the material increases from left to right and from top to bottom.
Table 3: outputting a scale factorVariable domain rule table of (a)
As can be seen from tables 1, 2 and 3, the temperature error e, the temperature error change rate ec and the server average power P are calculated ave After the fuzzy variable domain controller is input, the fuzzy variable domain controller can calculate the average power P of the server according to the temperature error e ave From input of a scaling factor alpha eec Input expansion factor alpha for determining temperature error e in variable domain rule table e And the temperature error rate of change ec ec The method comprises the steps of carrying out a first treatment on the surface of the The fuzzy variable domain controller can also be used for controlling the average power P of the server according to the temperature error e ave From the output of the scaling factorRespectively determining proportional fuzzy control quantity delta k in variable domain rule table p0 Output scaling factor +.>And a differential fuzzy control quantity Delak d0 Output scaling factor +.>Determining an integral fuzzy control quantity delta k from a variable domain rule table outputting a telescopic factor i0 Output scaling factor +.>
The present application describes a temperature error e, a temperature error change rate ec, and a server average power P ave As the zero point of the fuzzy zero point and the zero point of the fuzzy control rule table. Referring specifically to FIG. 10, FIG. 10 shows the fuzzy variable domain controller inputs (temperature error e.alpha.) provided herein e ) Membership function, the abscissa represents the use of an input scale factor alpha e A temperature error e (N) obtained by scaling the temperature error e, wherein the ordinate represents the membership degree of the temperature error e, and the blurring is changedInput of the domain controller (temperature error rate ec. Alpha.) ec ) And initial output (proportional fuzzy control quantity Delak) p0 Differential fuzzy control quantity delta k d0 Integral fuzzy control quantity delta k in ) The membership functions of (a) are the same as those shown in fig. 10 and are not shown here. As shown in fig. 10, the input temperature error e and the temperature error ec of the fuzzy variable domain controller and the initial output ratio fuzzy control quantity ak p0 Differential fuzzy control quantity delta k d0 And an integral fuzzy control quantity Delak i0 The fuzzy partitions of (a) are { NB, NM, NS, ZE, PS, PM, PB }, namely, negative large, negative medium, negative small, zero, positive small, medium and positive large are all seven grades. The middle is a triangle membership function, and the average power of the server is smaller in temperature fluctuation and is near a stable value when the error is negative or positive, so that the membership functions of NB and PB can be respectively Z-shaped and S-shaped membership functions.
As can be seen from FIG. 10, the initial arguments of the temperature error e are [ -1,1]. Since the maximum working temperature in the server is typically 80 ℃, and the minimum temperature in the extreme case is-40 ℃, but such extreme case will not occur in general, the minimum working temperature in the server can be set to 0 ℃, the ideal working temperature is 40 ℃, and the actually inputted temperature error e is within the range of [ -40, 40]Thus, an input of the scaling factor alpha is required e /40 to determine the temperature error range [ -40, 40]Conversion to the initial argument of temperature error e [ -1,1]And (3) upper part. Temperature error change rate ec, proportional fuzzy control quantity Δk p0 Differential fuzzy control quantity delta k d0 And an integral fuzzy control quantity Delak i0 The same is true of the arrangement of (c) and will not be described in detail here.
Tables 4, 5 and 6 show the proportional fuzzy control amount Δk, respectively p0 Differential fuzzy control quantity delta k d0 And an integral fuzzy control quantity Delak i0 The fuzzy control rule table is formulated according to the temperature error e and the temperature error change rate ec, and the rule of influence of the temperature error e and the temperature error change rate ec on the control parameters of the fan output by the PID controller is formulated fully.
TABLE 4 Deltak p0 Fuzzy control rule table
TABLE 5 Deltak i0 Fuzzy control rule table
TABLE 6 Deltak d0 Fuzzy control rule table
Thus, by inputting the scaling factor alpha e After scaling the temperature error e to a certain extent, the membership degree e (k) of the temperature error e can be determined from the membership function of the temperature error e according to the scaled temperature error e (N), and similarly, the expansion factor alpha is input ec After scaling the temperature error change rate ec to a certain extent, determining the membership deltae (k) of the temperature error change rate ec from the membership function of the temperature error change rate ec according to the scaled temperature error change rate ec (N).
Then, the membership degree Δe (k) according to the membership degree e (k) of the temperature error e and the membership degree Δe (k) of the temperature error change rate ec can be controlled from the proportional fuzzy control amount Δk p0 Determining a proportional fuzzy control quantity deltak in a fuzzy control rule table of (2) p0 From the integral fuzzy control quantity deltak i0 Determining an integral fuzzy control quantity deltak in a fuzzy control rule table of (2) i0 From the differential fuzzy control quantity deltak d0 Determining a differential fuzzy control quantity Delak in a fuzzy control rule table of (2) d0 Fuzzy control membership of (2) so that the quantity delta k can be fuzzy controlled according to the proportion p0 The fuzzy control membership degree of (a) is controlled from the proportion fuzzy control quantity delta k p0 Determining a proportional fuzzy control quantity deltak in a membership function of (a) p0 According to the integral fuzzy control quantity delta k i0 From the integral fuzzy control quantity deltak i0 Determining an integral fuzzy control quantity deltak in a fuzzy control membership function of (a) i0 According to the differential fuzzy control quantity delta k d0 From a differential fuzzy control quantity deltak d0 Determining a differential fuzzy control quantity deltak in a fuzzy control membership function of (a) d0 . Further, the proportional fuzzy control quantity Deltak p0 Multiplying by an output scaling factorThe proportional adjustment amount deltak of the PID controller can be calculated p The differential fuzzy control quantity delta k d0 Multiplying by the output scaling factor +.>The differential adjustment amount deltak of the PID controller can be calculated d The fuzzy control quantity Deltak will be integrated i0 Multiplying by the output scaling factor +.>The integral adjustment amount deltak of the PID controller can be calculated i . Thus, the fuzzy variable domain controller can calculate the calculated proportional adjustment quantity delta k p Differential adjustment amount Δk d And an integral adjustment amount Deltak i Output to the PID controller.
In the embodiment of the application, the input expansion factor and the output expansion factor are determined through the temperature error and the average power of the server, and then the fuzzy variable domain controller determines the adjustment quantity output to the PID controller according to the temperature error, the temperature error change rate input expansion factor and the output expansion factor, so that the PID controller can adaptively adjust the control parameters of the output fan along with the change of the temperature error and the average power of the server, and the robustness of the temperature control of the server is improved.
Fig. 11 shows a schematic structural diagram of a server temperature control device according to an embodiment of the present application. As shown in fig. 11, the server temperature control apparatus 200 includes: the acquisition module 210, the input module 220, the calculation module 230, the judgment module 240, the first determination module 250, the second determination module 260, and the third determination module 270. An obtaining module 210, configured to obtain a server temperature, a server power, and a fan rotation speed at n+1 times; the input module 220 is configured to input the server power and the fan rotation speed at the first n times of the n+1 times into the prediction model, and output the server predicted temperatures at the last n times of the n+1 times from the prediction model; the calculating module 230 is configured to calculate a reliability value of the prediction model according to the server predicted temperatures and the server temperatures at the last n times; a judging module 240, configured to judge whether the reliability value of the prediction model is less than or equal to the reliability threshold; the first determining module 250 is configured to input the server power and the fan rotation speed at the current time into the prediction model when the reliability value of the prediction model is less than or equal to the reliability threshold, output the predicted temperature of the server at the next time at the current time by the prediction model, and determine a temperature error according to the predicted temperature of the server at the next time; wherein the current time is the last time of n+1 times; a second determining module 260, configured to determine a temperature error according to the server temperature at the current time when the reliability value of the prediction model is greater than the reliability threshold; the third determining module 270 is configured to determine a control parameter of the fan according to the temperature error, so as to control the rotational speed of the fan to control the temperature of the server.
The specific implementation process and the beneficial effects of the server temperature control device in the embodiment of the present invention may refer to the embodiment of the server temperature control method shown in fig. 1, and are not described herein again.
Fig. 12 is a schematic structural diagram of a server according to an embodiment of the present application, which is not limited to a specific implementation of the server.
As shown in fig. 12, the server may include: a processor (processor) 302, a communication interface (Communications Interface) 304, a memory (memory) 306, and a communication bus 308.
Wherein: processor 302, communication interface 304, and memory 306 perform communication with each other via communication bus 308. A communication interface 304 for communicating with network elements of other devices, such as clients or other servers. Processor 302 is configured to execute program 310, and may specifically perform the relevant steps described above for the server temperature control method embodiment.
In particular, program 310 may include program code comprising computer-executable instructions.
The processor 302 may be a central processing unit CPU, or a specific integrated circuit ASIC (Application Specific Integrated Circuit), or one or more integrated circuits configured to implement embodiments of the present application. The one or more processors included by the server may be the same type of processor, such as one or more CPUs; but may also be different types of processors such as one or more CPUs and one or more ASICs.
Memory 306 for storing program 310. Memory 306 may comprise high-speed RAM memory or may also include non-volatile memory (non-volatile memory), such as at least one disk memory.
The embodiment of the application provides a computer readable storage medium, wherein the storage medium stores executable instructions, and the executable instructions enable a server to execute the server temperature control method in any of the method embodiments.

Claims (10)

1. A method for controlling temperature of a server, the method comprising:
acquiring the temperature, the power and the rotating speed of a fan of a server at n+1 moments;
inputting the server power and the fan rotation speed of the first n times of the n+1 times into a prediction model, and outputting the server predicted temperature of the last n times of the n+1 times by the prediction model;
calculating the credibility value of the prediction model according to the server predicted temperature and the server temperature at the last n moments;
judging whether the credibility value of the prediction model is smaller than or equal to a credibility threshold value;
if yes, inputting the power of the server and the rotating speed of the fan at the current moment into the prediction model, outputting the predicted temperature of the server at the next moment of the current moment by the prediction model, and determining a temperature error according to the predicted temperature of the server at the next moment; wherein the current time is the last time of the n+1 times;
If not, determining a temperature error according to the server temperature at the current moment;
and determining control parameters of the fan according to the temperature error so as to control the rotating speed of the fan to control the temperature of the server.
2. The method of claim 1, wherein calculating the confidence value of the predictive model from the server predicted temperatures and server temperatures at the last n times comprises:
calculating the absolute value of the difference between the server predicted temperature and the server temperature at each of the last n moments to obtain n absolute values;
and calculating the sum of the n absolute values, and calculating the ratio between the sum of the absolute values and n to obtain the credibility value of the prediction model.
3. The method of claim 1, wherein said inputting the server power and fan speed at the first n of said n+1 times into a predictive model, outputting the server predicted temperatures at the last n of said n+1 times from said predictive model, comprises:
inputting the server power and the fan rotating speed at the first n times into the prediction model to obtain initial predicted temperatures of the servers at the last n times;
Calculating a difference value between the server temperature at each of the last n moments and the initial predicted temperature of the server by the prediction model to obtain predicted temperature errors of the last n moments;
respectively compensating the predicted temperature errors of the first n-1 moments in the last n moments to the initial predicted temperatures of the servers in the last n-1 moments in the last n moments by the prediction model, and outputting the predicted temperatures of the servers in the last n moments, wherein the predicted temperatures of the servers in the 1 st moment in the last n moments are equal to the initial predicted temperatures of the servers;
the step of inputting the server power and the fan rotation speed at the current moment into the prediction model, and outputting the server predicted temperature at the moment next to the current moment by the prediction model, further comprises:
inputting the server power and the fan rotating speed at the current moment into the prediction model to obtain the initial predicted temperature of the server at the next moment;
and compensating the predicted temperature error at the current moment to the initial predicted temperature of the server at the next moment by the prediction model, and outputting the predicted temperature of the server at the next moment.
4. The method of claim 1, wherein prior to determining a temperature error from the server temperature at the current time, the method further comprises: acquiring the server temperature, the server power and the fan rotating speed at N times before the n+1 times; optimizing the prediction model according to the server temperatures, the server powers and the fan speeds at the N moments; wherein a last time instant of the N time instants is adjacent to a first time instant of the n+1 time instants;
The method further comprises the steps of:
judging whether the server stops running or not;
if not, the step of obtaining the server temperature, the server power and the fan rotating speed at n+1 times is carried out.
5. The method of claim 4, wherein optimizing the predictive model based on the server temperature, server power, and fan speed for the N times further comprises:
randomly generating N groups of optimization parameters, and setting the optimization times M;
executing a circulation process until a preset condition is met, and judging whether the minimum objective function value in all the determined objective function values is smaller than an objective function threshold value or not when the preset condition is met;
if yes, taking the prediction model updated by the optimization parameter corresponding to the minimum objective function value as the optimized prediction model, and turning to the step of determining a temperature error according to the server temperature at the current moment;
if not, updating the N groups of optimization parameters through the optimization parameters corresponding to the minimum preset number of objective function values in all the determined objective function values to obtain new N groups of optimization parameters, turning to the execution circulation process until the preset condition is met, judging whether the minimum objective function value in all the determined objective function values is smaller than an objective function threshold value or not when the preset condition is met, until the number of times of obtaining the new N groups of optimization parameters is greater than or equal to M, taking a prediction model updated by the optimization parameters corresponding to the minimum objective function value determined by the prediction model updated by the M-th new N groups of optimization parameters as an optimized prediction model, and turning to the step of determining a temperature error according to the server temperature at the current moment;
The cyclic process includes:
updating the predictive model using an unused one of the N sets of optimization parameters;
inputting the power of the server and the rotating speed of the fan at the first N-1 times in the N times into an updated prediction model, and generating the predicted temperature of the server at the last N-1 times in the N times by the updated prediction model;
determining an objective function value corresponding to the set of optimization parameters according to the predicted server temperature and the server temperature at the last N-1 moments;
wherein, the preset conditions are as follows:
the predictive model has been updated with all optimization parameters.
6. The method of claim 1, wherein after determining a temperature error based on the server predicted temperature at the next time, the method further comprises: determining a temperature error change rate according to the temperature error of the next moment;
after the temperature error is determined according to the server temperature at the current moment, the method further comprises the following steps: determining a temperature error change rate according to the temperature error at the current moment;
the determining the control parameter of the fan according to the temperature error to control the rotation speed of the fan to control the temperature of the server further comprises: inputting the temperature error and the temperature error change rate into a fuzzy variable domain controller, and outputting the adjustment quantity of a PID controller by the fuzzy variable domain controller; inputting the adjustment amount into the PID controller, and determining control parameters of the fan by the PID controller so that the PID controller controls the rotating speed of the fan according to the control parameters to control the temperature of the server.
7. The method of claim 6, wherein the inputting the temperature error and the temperature error rate of change into the fuzzy variable domain controller, outputting, by the fuzzy variable domain controller, an adjustment of a PID controller, further comprises:
determining an input expansion factor and an output expansion factor from a variable domain rule table according to the temperature error and the average power of the server at the last n moments;
inputting the temperature error, the temperature error change rate, the input scaling factor and the output scaling factor into the fuzzy variable domain controller;
and (c) by the fuzzy variable domain controller:
determining the membership of the temperature error from the membership function of the temperature error according to the temperature error and the input scaling factor, and determining the membership of the temperature error change rate from the membership function of the temperature error change rate according to the temperature error change rate and the input scaling factor;
determining fuzzy control membership degree from a fuzzy control rule table according to the membership degree of the temperature error and the membership degree of the temperature error change rate;
determining a fuzzy control quantity from the fuzzy control membership function according to the fuzzy control membership;
And outputting the adjustment quantity of the PID controller according to the fuzzy control quantity and the output expansion factor.
8. A server temperature control apparatus, the apparatus comprising:
the acquisition module is used for acquiring the server temperature, the server power and the fan rotating speed at n+1 moments;
the input module is used for inputting the server power and the fan rotating speed of the first n times of the n+1 times into a prediction model, and outputting the server predicted temperature of the last n times of the n+1 times by the prediction model;
the calculation module is used for calculating the credibility value of the prediction model according to the server predicted temperatures and the server temperatures at the last n moments;
the judging module is used for judging whether the credibility value of the prediction model is smaller than or equal to a credibility threshold value;
the first determining module is used for inputting the power of the server and the rotating speed of the fan at the current moment into the prediction model when the reliability value of the prediction model is smaller than or equal to the reliability threshold value, outputting the predicted temperature of the server at the next moment of the current moment by the prediction model, and determining a temperature error according to the predicted temperature of the server at the next moment; wherein the current time is the last time of the n+1 times;
The second determining module is used for determining a temperature error according to the server temperature at the current moment when the credibility value of the prediction model is larger than the credibility threshold;
and the third determining module is used for determining control parameters of the fan according to the temperature error so as to control the rotating speed of the fan to control the temperature of the server.
9. A server, comprising: the device comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete communication with each other through the communication bus;
the memory is configured to store executable instructions that cause the processor to perform the operations of the server temperature control method of any one of claims 1-7.
10. A computer readable storage medium, wherein executable instructions are stored in the storage medium, which when run on a server, cause the server to perform the operations of the server temperature control method according to any one of claims 1-7.
CN202311653064.7A 2023-12-01 2023-12-01 Server temperature control method and device, server and storage medium Pending CN117762221A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311653064.7A CN117762221A (en) 2023-12-01 2023-12-01 Server temperature control method and device, server and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311653064.7A CN117762221A (en) 2023-12-01 2023-12-01 Server temperature control method and device, server and storage medium

Publications (1)

Publication Number Publication Date
CN117762221A true CN117762221A (en) 2024-03-26

Family

ID=90315371

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311653064.7A Pending CN117762221A (en) 2023-12-01 2023-12-01 Server temperature control method and device, server and storage medium

Country Status (1)

Country Link
CN (1) CN117762221A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118466720A (en) * 2024-07-09 2024-08-09 苏州元脑智能科技有限公司 Method and device for regulating server, electronic equipment and readable storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118466720A (en) * 2024-07-09 2024-08-09 苏州元脑智能科技有限公司 Method and device for regulating server, electronic equipment and readable storage medium

Similar Documents

Publication Publication Date Title
CN111129550B (en) PID control method for fuel cell system
CN117762221A (en) Server temperature control method and device, server and storage medium
JPH04259004A (en) Method for feedback control and tuning apparatus
CN108241392A (en) Temprature control method and system
CN111196145B (en) Method and device for controlling rotating speed of cooling fan and vehicle
CN110094838B (en) Variable parameter model-free self-adaptive control method based on air conditioning system
CN114995108A (en) Control method based on fuzzy PID and sliding mode control composite control
CN116700393A (en) Reaction kettle temperature control method based on fuzzy control
CN109491248A (en) Magnetic levitation ball position prediction control method based on RBF-ARX model and laguerre function
CN110928341B (en) Temperature control method, device, equipment and storage medium
CN117519353A (en) Cabinet temperature control method and device and air conditioner
CN112180733B (en) Fuzzy logic-based building energy consumption system prediction control parameter setting method
CN116827177B (en) Brushless direct current motor rotating speed control method, system, equipment and storage medium
CN107461977B (en) A kind of intelligent temperature control method of semiconductor refrigeration temperature control case
CN113506899A (en) Control device and control method for thermostat of liquid cooling system of fuel cell
CN116292466B (en) Digital liquid flow matching system and control method
CN104238359B (en) A kind of large-scale electromechanical mixing inertia system control method
CN108155836A (en) Based on global online heuristic dynamic programming permanent magnet synchronous motor vector control method
CN115788773A (en) Floating type wind turbine generator set multi-target variable pitch control, system and equipment
CN112460039B (en) Device for monitoring operating condition of vane pump and adjusting method
CN112049811B (en) Method for controlling the rotational speed of a device
CN109688652B (en) Method for accurately controlling temperature of microwave high-temperature reactor based on double-layer structure model predictive control
Mofei et al. Design of intelligent temperature controller for thermocouple automatic calibrating furnace
CN118426524B (en) Heat control method based on intelligent control valve
CN117879408B (en) Self-adaptive intelligent control method of linear motor and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination