Temperature control method, device, equipment and medium
By monitoring the temperature of server components in real time and dynamically adjusting the flow limits according to the temperature change rate and linear regression slope, the problem of high cost of server temperature control and difficulty in reducing power consumption in the prior art is solved, and efficient and low-cost temperature control is achieved.
Patent Information
- Application Number
- CN202411461660.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-18
- Publication Date
- 2025-02-07
AI Technical Summary
The prior art has problems of high cost and difficulty in fundamentally reducing power consumption in reducing server temperatures, especially in small server clusters that are difficult to achieve effective temperature control.
By monitoring the temperature of each component of the server in real time, calculating the component temperature average, and dynamically adjusting the traffic limit percentage based on the temperature change rate and linear regression slope to control the server temperature.
It realizes reducing the temperature control cost while reducing the server temperature, avoids complex scheduling algorithms, simplifies the temperature control process, and ensures the stability of server performance.
Smart Images

Figure CN119396577A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of heat dissipation technology, and in particular to a temperature control method, device, equipment and medium. Background Art
[0002] Currently, the power consumption of modern computing devices (such as servers) is closely related to the load they process; especially in high-performance computing scenarios, the heat generated by the equipment needs to be dissipated in time through the cooling system to keep the equipment working normally; if the temperature is too high, it may cause the equipment to be unstable or even damaged. Therefore, power consumption management and temperature control are key links in the operation of computing devices.
[0003] The relevant technology is to reduce the server temperature by optimizing the cooling system, such as using liquid cooling technology or efficient air circulation design; but this usually requires additional hardware investment and is costly.
[0004] At the same time, the hardware investment cost is high and is suitable for large-scale data centers, but small server clusters are unaffordable; and optimizing the cooling system cannot fundamentally reduce the power consumption of the server, but only alleviates the temperature problem. Summary of the invention
[0005] In order to overcome the above technical defects, the purpose of this application is to provide a temperature control method, device, equipment and medium, the method comprising: obtaining the temperature of each component of the server, the components including a central processing unit, a memory, an image processor, and a disk; calculating the component temperature average value according to the weighted temperature of each component of the server, and setting the component temperature average value as the server temperature value; comparing the server temperature value with a first preset value; in response to the server temperature value being greater than the first preset value, starting the server temperature calculation control process; calculating the server temperature change rate according to time and server temperature change; calculating the linear regression slope through temperature monitoring at multiple time points; in response to the linear regression slope being greater than a second preset value, calculating the flow restriction percentage according to the server temperature change rate, and controlling the server temperature by the flow restriction percentage until the server temperature value is less than the first preset value. This application reduces the difficulty of implementing server temperature control by determining a flow restriction point that meets the requirements and avoids complex scheduling algorithms, while reducing the cost of temperature control.
[0006] The specific technical solutions provided by the embodiments of this application are as follows:
[0007] In a first aspect, the present application provides a temperature control method, which is applied to a server and includes:
[0008] Obtaining the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0009] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0010] Comparing the server temperature value with a first preset value;
[0011] In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process;
[0012] Calculate the server temperature change rate based on time and server temperature change;
[0013] The linear regression slope was calculated by monitoring the temperature at multiple time points;
[0014] In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
[0015] In one embodiment, calculating the server temperature change rate according to time and server temperature change includes:
[0016] Get the time change threshold Δt and the current server temperature value T t+1 , initial server temperature value T t ;
[0017] By formula: ΔT = T t+1 -T t / Δt, calculate the server temperature change rate ΔT.
[0018] In one embodiment, the calculating the linear regression slope by monitoring the temperature at multiple time points comprises:
[0019] Get the value ti of the i-th monitoring time point and the average value of all monitoring time points The total number of monitoring time points n;
[0020] Get the server temperature value Ti corresponding to the i-th time point and the average value of the server temperature at all time points
[0021] By formula Calculate the linear regression slope k.
[0022] In one embodiment, the calculating the flow limit percentage according to the server temperature change rate and controlling the server temperature by the flow limit percentage includes:
[0023] Obtain the initial flow limit percentage L1 of the server network card and the temperature change rate ΔT of the server;
[0024] The current flow limit percentage L2 of the server network card is calculated by the formula L2=L1+ΔT;
[0025] Controlling the server temperature by using the current flow limit percentage of the server network card;
[0026] The controlling the server temperature by the current flow limit percentage of the server network card includes:
[0027] When the current flow limit percentage of the server network card is a third preset value, the time change threshold t2-t1, the server temperature value T2 at time t2, and the server temperature value T1 at time t1 are obtained;
[0028] The temperature change rate k1 of the first server is calculated by the formula: k1=T2-T1 / t2-t1;
[0029] In response to the temperature change rate of the first server being greater than a second preset value, the flow limit percentage of the server network card is continued to be increased, and the current flow limit percentage of the server network card is set to a fourth preset value;
[0030] When the current flow limit percentage of the server network card is a fourth preset value, obtaining a time change threshold t4-t3, a server temperature value T3 at time t3, and a server temperature value T4 at time t4;
[0031] The temperature change rate k2 of the second server is calculated by the formula: k2=T3-T4 / t4-t3;
[0032] In response to the temperature change rate of the second server being greater than the second preset value, the current flow limit percentage of the server network card is maintained at a fourth preset value to control the server temperature.
[0033] In one embodiment, the method further comprises:
[0034] In response to the linear regression slope being less than a second preset value, controlling the flow restriction percentage according to the current server temperature value;
[0035] The controlling of the flow limit percentage according to the current server temperature value includes:
[0036] When the server temperature value is greater than a fifth preset value, the current flow limit percentage of the server is maintained unchanged;
[0037] When the temperature value of the server is less than a fifth preset value, the flow limit percentage of the server is closed.
[0038] In one embodiment, the flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value, including:
[0039] Record the historical data of the server temperature and the corresponding network card flow;
[0040] Creating a mapping relationship between the server temperature and the corresponding network card flow rate according to the historical data of the server temperature and the corresponding network card flow rate;
[0041] The server temperature control is optimized and adjusted according to the mapping relationship between the server temperature and the corresponding network card flow.
[0042] In one embodiment, the method further comprises:
[0043] Monitor the load of each server through a load balancer;
[0044] Reassign tasks to servers through intelligent scheduling algorithms and the current server workload, wherein the scheduling algorithms include polling algorithms, least connection algorithms, and IP hash algorithms;
[0045] Automatically adjust the number of servers according to the server load task ratio;
[0046] The automatic correction of the number of servers according to the server load task ratio includes:
[0047] When the server load task increases and the server temperature is greater than a first preset value, an additional server is started, part of the load is transferred to the additional server through a load balancer, and the server temperature is controlled;
[0048] When the server load task decreases and the server temperature is less than a first preset value, the redundant servers are shut down;
[0049] When the server is in off-peak hours, the hardware device uses energy-saving mode to automatically reduce the processor speed and / or shut down non-critical components.
[0050] In a second aspect, the present application further provides a temperature control device, which is applied to a server and includes:
[0051] An acquisition module, used to acquire the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0052] A calculation module is used to calculate the component temperature average value according to the weighted temperature of each component of the server, and set the component temperature average value as the server temperature value; calculate the server temperature change rate according to time and server temperature change; and calculate the linear regression slope through temperature monitoring at multiple time points;
[0053] A comparison module, used for comparing the server temperature value with a first preset value;
[0054] An activation module, configured to activate a server temperature calculation control process in response to the server temperature value being greater than a first preset value;
[0055] The control module is used to calculate the flow limit percentage according to the server temperature change rate in response to the linear regression slope being greater than the second preset value, and control the server temperature by the flow limit percentage until the server temperature value is less than the first preset value.
[0056] In a third aspect, a temperature control device is also provided, comprising:
[0057] one or more processors;
[0058] A storage device for storing one or more programs;
[0059] When the one or more programs are executed by the one or more processors, the one or more processors implement the temperature control method as described in any one of the first aspects.
[0060] In a fourth aspect, the present application further provides a computer device, the device comprising:
[0061] A memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the temperature control method as described in any one of the first aspects.
[0062] In a fifth aspect, the present application further provides a computer program product, comprising a computer program, which, when executed by a processor, implements the steps of any temperature control method described in the first aspect.
[0063] In a sixth aspect, the present application further provides a computer storage medium, the medium comprising:
[0064] A computer program is stored thereon, and when the computer program is executed by a processor, the steps of any temperature control method described in the first aspect are implemented.
[0065] Compared with the prior art, the method described in the technical solution provided in the embodiment of the present application includes: obtaining the temperature of each component of the server, the components including a central processing unit, a memory, an image processor, and a disk; calculating the component temperature average value according to the weighted temperature of each component of the server, and setting the component temperature average value as the server temperature value; comparing the server temperature value with a first preset value; in response to the server temperature value being greater than the first preset value, starting the server temperature calculation control process; calculating the server temperature change rate according to time and server temperature change; calculating the linear regression slope through temperature monitoring at multiple time points; in response to the linear regression slope being greater than a second preset value, calculating the flow limit percentage according to the server temperature change rate, and controlling the server temperature through the flow limit percentage until the server temperature value is less than the first preset value. The present application reduces the difficulty of implementing server temperature control by determining a flow limit point that meets the requirements and avoids complex scheduling algorithms, while reducing the cost of temperature control.
[0066] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0067] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management. BRIEF DESCRIPTION OF THE DRAWINGS
[0068] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0069] Figure 1 A first flow chart of the temperature control method provided in Example 1 of the present application;
[0070] Figure 2 A second flow chart of the temperature control method provided in Example 1 of the present application;
[0071] Figure 3 A third flow chart of the temperature control method provided in Example 2 of the present application;
[0072] Figure 4 A fourth flow chart of the temperature control method provided in Example 2 of the present application;
[0073] Figure 5 A structural diagram of a temperature control device provided in Example 3 of the present application;
[0074] Figure 6 The exemplary system provided for Embodiment 7 of the present application can be used to implement the various embodiments described in the present application. DETAILED DESCRIPTION
[0075] In order to make the purpose, technical solutions and advantages of this application clearer, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0076] It should be noted that, unless the context clearly requires otherwise, words such as “include”, “including” and similar words throughout the specification and claims should be interpreted as including rather than exclusive or exhaustive; that is, the meaning is “including but not limited to”.
[0077] Furthermore, in the description of the present application, unless otherwise specified, “plurality” means two or more.
[0078] Dynamic Voltage and Frequency Scaling (DVFS) is a power management technology that dynamically adjusts the voltage and operating frequency of the processor according to the computing load to reduce power consumption and extend battery life; DVFS is mainly used in processors (such as CPUs and GPUs) and other electronic devices capable of variable frequency.
[0079] However, due to the hardware capabilities of the processor, reducing the frequency may cause serious degradation of device performance under high load.
[0080] Embodiment 1
[0081] The present application embodiment provides a temperature control method, such as Figure 1 As shown, the method is applied to a server, and the method comprises:
[0082] Obtaining the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0083] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0084] Comparing the server temperature value with a first preset value;
[0085] In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process;
[0086] Calculate the server temperature change rate based on time and server temperature change;
[0087] The linear regression slope was calculated by monitoring the temperature at multiple time points;
[0088] In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
[0089] Specifically, Figure 2 As shown, the system of this technical solution includes a temperature monitoring module, a monitoring calculation module, a flow control module, and a data analysis module;
[0090] The temperature monitoring module is responsible for real-time monitoring of the server temperature;
[0091] When the temperature exceeds the first preset value (such as 45 degrees), further calculation and control are triggered. The goal of temperature control is to keep the temperature below the control threshold of 75°C (fifth preset value), and the control temperature growth rate is linearly related to time, and the slope is less than the second preset value (such as the slope is 1);
[0092] The monitoring calculation module starts working after the temperature exceeds 45°C, records the temperature changes over a period of time, and determines whether the temperature rise trend exceeds the slope of the linear relationship or presents an exponential relationship;
[0093] The flow limitation module takes measures to limit the flow according to the results of the monitoring and calculation module, thereby controlling power consumption; by randomly blocking the flow and blocking for a limited time, the appropriate flow limitation ratio is gradually found.
[0094] It is understandable that a local optimal solution means that the solution is optimal relative to other feasible solutions within a certain range or region. However, this does not mean that this solution is optimal in the entire problem space; the local optimal solution may be different from the global optimal solution, which is the optimal solution in the entire problem space; in the server temperature control scenario, immediate adjustment is required, and the local optimal solution can meet the control conditions.
[0095] In some scenarios, server traffic and server load are positively correlated, and blocking some traffic will not affect the business. For example, in the CDN distribution business, video streaming service providers use CDN servers to cache and distribute their popular video content. When users request these videos, they usually get them from the CDN server closest to them to reduce latency and improve the viewing experience. During certain time periods (such as prime time in the evening), the number of user requests to watch videos increases significantly, causing a sharp increase in traffic. At the same time, CDN architecture is usually designed with redundancy and high availability in mind, and multiple servers can back up each other. If a server is restricted by traffic or temporarily fails, other servers can seamlessly take over its traffic.
[0096] Among them, the first preset value is 45° C., and the second preset value is 1.
[0097] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0098] This application reduces the difficulty of implementing server temperature control by determining the flow limit point that meets the demand and avoids complex scheduling algorithms, while reducing the cost of temperature control.
[0099] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0100] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management.
[0101] Embodiment 2
[0102] The present application embodiment provides a temperature control method, such as Figure 3 As shown, the method is applied to a server, and the method comprises:
[0103] Step S01, obtaining the temperature of each component of the server, wherein the components include a central processing unit (CPU), a memory, a graphics processing unit (GPU), and a disk;
[0104] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0105] Comparing the server temperature value with a first preset value;
[0106] In response to the server temperature value being greater than a first preset value (calculation threshold), the server temperature calculation control process is started.
[0107] Specifically, the temperature monitoring module monitors the device temperature;
[0108] A temperature sensor is used to monitor the temperature of the device in real time. When the temperature exceeds the set calculation threshold (for example, 45 degrees), the monitoring calculation is triggered.
[0109] The temperature sensor collects the temperatures t0, t1, t2, t3, and t4 of the CPU, memory, GPU, disk, and power supply, and then calculates a weighted average value, which is used as the temperature of the server and compared with the first preset value.
[0110] Step S02, calculating the server temperature change rate according to time and server temperature change.
[0111] Step S02 also includes:
[0112] Step S021, obtaining the time change threshold Δt and the current server temperature value T t+1 , initial server temperature value T t ;
[0113] By formula: ΔT = T t+1 -T t / Δt, calculate the server temperature change rate ΔT.
[0114] Specifically, time window: set a time window Δt, for example 5 minutes, and record the temperature change;
[0115] Temperature change function: Record the temperature change ΔT within the time window Δt and calculate the temperature change rate.
[0116] Step S03, calculating the linear regression slope by monitoring the temperature at multiple time points.
[0117] Step S03 also includes:
[0118] Step S031, obtain the value ti of the i-th monitoring time point and the average value of all monitoring time points The total number of monitoring time points n;
[0119] Get the server temperature value Ti corresponding to the i-th time point and the average value of the server temperature at all time points
[0120] By formula Calculate the linear regression slope k.
[0121] Specifically, the functional relationship between the temperature rise ΔT and Δt within the time Δt is monitored and calculated to determine whether the slope 1 of the linear relationship or the exponential relationship is exceeded.
[0122] If the temperature exceeds the slope of 1 in the linear relationship, then the relationship is exponential or linear.
[0123] The exponential relationship function is T t+1 =T t e αt ;
[0124] Among them, the current server temperature value T t+1 , initial server temperature value T t , exponential growth factor α;
[0125] Here, the above k: is the slope to be calculated, which represents the rate at which temperature changes with time;
[0126] Σ: is the summation symbol;
[0127] n: is the total number of monitored temperature data points, for example 30 times;
[0128] ti: is the value at the i-th time point;
[0129] is the average of all time points;
[0130] Ti: is the temperature value corresponding to the i-th time point;
[0131] is the average of all temperature values;
[0132] represents the deviation of the i-th time point from the average time;
[0133] represents the deviation of the ith temperature value from the average temperature;
[0134] is the square of the time deviation;
[0135] The numerator of the k formula It is the sum of the products of time deviation and temperature deviation, reflecting the covariance relationship between time and temperature;
[0136] The denominator of the k formula is the sum of the squares of the time deviations, used to normalize the slope;
[0137] Assume there are the following 5 data points:
[0138] t1=1,T1=20
[0139] t2=2,T2=22
[0140] t3=3,T3=25
[0141] t4=4,T4=27
[0142] t5=5,T5=30
[0143] Step 1: Calculate the average
[0144]
[0145] Step 2: Calculate the deviation
[0146]
[0147] Step 3: Calculate the numerator
[0148]
[0149] Step 4: Calculate the denominator
[0150]
[0151] Step 5: Calculate the slope k
[0152] k=25 / 10=2.5.
[0153] Step S04, in response to the linear regression slope being greater than a second preset value, calculating a flow limit percentage according to the server temperature change rate, and controlling the server temperature by the flow limit percentage.
[0154] Step S04 also includes:
[0155] Step S041, obtaining the initial flow limit percentage L1 of the server network card and the temperature change rate ΔT of the server;
[0156] The current flow limit percentage L2 of the server network card is calculated by the formula L2=L1+ΔT;
[0157] Controlling the server temperature by using the current flow limit percentage of the server network card;
[0158] The controlling the server temperature by the current flow limit percentage of the server network card includes:
[0159] When the current flow limit percentage of the server network card is a third preset value, the time change threshold t2-t1, the server temperature value T2 at time t2, and the server temperature value T1 at time t1 are obtained;
[0160] The temperature change rate k1 of the first server is calculated by the formula: k1=T2-T1 / t2-t1;
[0161] In response to the temperature change rate k1 of the first server being greater than the second preset value, the flow limit percentage of the server network card is continued to be increased, and the current flow limit percentage of the server network card is set to a fourth preset value;
[0162] When the current flow limit percentage of the server network card is a fourth preset value, obtaining a time change threshold t4-t3, a server temperature value T3 at time t3, and a server temperature value T4 at time t4;
[0163] The temperature change rate k2 of the second server is calculated by the formula: k2=T3-T4 / t4-t3;
[0164] In response to the second server temperature change rate k2 being greater than the second preset value, the current flow limit percentage of the server network card is maintained at the fourth preset value to control the server temperature.
[0165] Specifically, the flow limiting module is triggered, and when the temperature monitoring module determines that the temperature is increasing exponentially according to the above k formula, that is, k is greater than 1 or is an exponential relationship, the power consumption limiting module is triggered;
[0166] The goal of the power consumption limiting module is to control the temperature rise of the server so that the temperature does not exceed a first preset value (e.g., 45 degrees);
[0167] The constraint is to adjust the flow restriction percentage (L) to ensure that the flow rate drops as little as possible while controlling the temperature;
[0168] The flow restriction percentage L is iteratively adjusted using an algorithm to control the temperature rise;
[0169] The initial flow blocking ratio L can be set within the range of 10% to 20%;
[0170] In each iteration, the flow restriction percentage is adjusted according to the temperature change rate;
[0171] The temperature change rate is calculated by the temperature monitoring module and its value is ΔT;
[0172] If the monitored temperature change still does not reach a linear or downward trend, increase the blocking ratio L to L2;
[0173] That is, L2=L1+ΔT.
[0174] It is understandable that, for example, a high-performance server is used in a data center to process a large number of external requests. The temperature of the server often exceeds 45 degrees during peak hours, affecting its performance and life. In order to protect the equipment, an effective temperature control method is required;
[0175] This server parameters:
[0176] Network bandwidth: 1Gbps;
[0177] Normal operating temperature range: 20-45℃;
[0178] Initial state
[0179] Current temperature: 46°C (exceeds the 45°C threshold);
[0180] Ambient temperature: 25℃;
[0181] Current server load: 80% CPU utilization, 900Mbps network bandwidth utilization;
[0182] Temperature monitoring upper limit: 45℃ (ordinary air cooling system);
[0183] 1: The temperature monitoring module detects that the device temperature is higher than the threshold, triggering the monitoring calculation;
[0184] The temperature monitoring module detects that the temperature is 46°C, which is higher than 45°C, triggering the monitoring calculation;
[0185] 2: Monitor and calculate the functional relationship between the temperature rise ΔT and Δt within the time Δt, and determine whether it exceeds the slope 1 of the linear relationship or the exponential relationship;
[0186] Record the temperature change within time Δt (e.g. 1 minute): 46°C -> 47°C -> 48.5°C;
[0187] Through linear regression fitting calculation, it is found that the temperature change trend exceeds the reasonable slope of linear growth 1 (such as set to 1°C / minute). It can be seen from the data that the temperature growth exceeds expectations and is exponential;
[0188] 3: The temperature is detected to be increasing exponentially, triggering the power consumption limit module;
[0189] 4: Finding the initial solution
[0190] Initial flow restriction scheme: reduce the flow by 10% (third preset value);
[0191] The new data rate is 810 Mbps;
[0192] 5: The power consumption limit module starts with the device network card traffic and randomly blocks the traffic. The temperature monitoring module continuously monitors the function F of temperature and time.
[0193] Block some traffic and reduce it to 810Mbps;
[0194] 6: The temperature monitoring module continuously monitors temperature changes;
[0195] The temperature change after blocking as a function of time is recorded as follows:
[0196] t1=0min:T1=48.5℃
[0197] t2=1 minute:T2=49.7℃
[0198] At this time, the rising trend of temperature slows down, but k1 is still higher than the reasonable slope of linear growth 1;
[0199] 7: If the function solution does not meet the requirements, continue the solution process, increase the blocking percentage, and repeat steps 4-5 until a solution that meets the conditions is obtained;
[0200] Increase the random blocking rate to 20% (the fourth preset value):
[0201] Calculate 810 Mbps × (1-0.2) = 648 Mbps;
[0202] Then continue to monitor temperature changes:
[0203] t3=0min:T3=47.5℃
[0204] t4=1 minute: T4=46℃
[0205] At this time, the temperature drops back to 46 degrees, and the calculated k2 meets the linear growth requirement;
[0206] In summary, through temperature monitoring, flow control, and a cyclic solution process, the flow blocking ratio is gradually adjusted until the requirement of linear growth of temperature change is met, successfully controlling the temperature and power consumption of the server.
[0207] Step S05, in response to the linear regression slope being less than a second preset value, controlling the flow restriction percentage according to the current server temperature value;
[0208] The controlling of the flow limit percentage according to the current server temperature value includes:
[0209] When the server temperature value is greater than a fifth preset value (control threshold), the current flow limit percentage of the server is maintained unchanged;
[0210] When the temperature value of the server is less than a fifth preset value, the flow limit percentage of the server is closed.
[0211] Wherein, the fifth preset value is 75°C.
[0212] Step S06: In response to the server temperature value being less than a first preset value, the temperature control of the server is completed.
[0213] Specifically, until the server temperature is monitored to return to the range of 45° C., the temperature control of the server is completed.
[0214] Step S07, recording the historical data of the server temperature and the corresponding network card flow;
[0215] Creating a mapping relationship between the server temperature and the corresponding network card flow rate according to the historical data of the server temperature and the corresponding network card flow rate;
[0216] The server temperature control is optimized and adjusted according to the mapping relationship between the server temperature and the corresponding network card flow.
[0217] Specifically, data recording and analysis examples
[0218] Initial load temperature record
[0219] Load: 900Mbps (80% CPU), Temperature: 46°C;
[0220] Initial blockage 10%;
[0221] Load after blocking: 810Mbps, temperature change: 48.5℃->49.7℃;
[0222] Increase blocking by 20%;
[0223] Load after blocking: 648Mbps, temperature change: 47.5℃->46℃.
[0224] Through actual data verification, the temperature is adjusted to a reasonable range and the safety of the equipment is improved.
[0225] Here, the data analysis module is responsible for recording the historical data of temperature and flow, analyzing the relationship between temperature and flow, and assisting other modules to make more accurate temperature judgments and adjustments; assuming that the temperature T is a function of the flow F, it can be expressed as: T=xF, when the flow limit percentage F is 0, the slope of the linear relationship is used as the preset slope.
[0226] Step S08, monitoring the load of each server through a load balancer;
[0227] Reassign tasks to servers through intelligent scheduling algorithms and the current server workload, wherein the scheduling algorithms include polling algorithms, least connection algorithms, and IP hash algorithms;
[0228] Automatically adjust the number of servers according to the server load task ratio;
[0229] The automatic correction of the number of servers according to the server load task ratio includes:
[0230] When the server load task increases and the server temperature is greater than a first preset value, an additional server is started, part of the load is transferred to the additional server through a load balancer, and the server temperature is controlled;
[0231] When the server load task decreases and the server temperature is less than a first preset value, the redundant servers are shut down;
[0232] When the server is in off-peak hours, the hardware device uses energy-saving mode to automatically reduce the processor speed and / or shut down non-critical components.
[0233] Specifically, controlling server temperature by evenly distributing tasks across multiple servers is an effective load management strategy; this approach can avoid overloading a single server, thereby reducing the temperature rise caused by high load:
[0234] Use a hardware or software load balancer to distribute incoming requests to the system. The load balancer monitors the load on each server and sends new requests to the least busy server.
[0235] Implement intelligent scheduling algorithms (such as polling, least connections, IP hashing, etc.) that can dynamically reallocate tasks based on the current workload;
[0236] Automatically increase or decrease the number of servers based on actual load. When an increase in load is detected and the temperature approaches a threshold, additional servers can be automatically started to distribute the load; when the load decreases, redundant servers can be shut down to save resources.
[0237] Install temperature sensors in the server and set thresholds. When the temperature reaches or exceeds the preset value (45 degrees), an alarm is triggered and actions are taken, such as transferring part of the load to other servers through a load balancer.
[0238] Ensure that the air conditioning system and ventilation facilities in the data center are operating properly to remove excess heat in a timely manner; at the same time, the air flow can be adjusted to improve cooling efficiency;
[0239] Use hardware devices that support energy-saving modes, which automatically reduce processor speeds or shut down unnecessary components during off-peak hours to reduce heat generation;
[0240] The hot aisle and cold aisle are separated in the equipment room design to ensure that the cold air flows directly to the equipment that needs cooling, while the hot air is effectively exhausted;
[0241] Optimize the performance of running applications and reduce unnecessary computing workload, thereby reducing power consumption and heat generation.
[0242] Combining the above methods, server temperature can be effectively controlled through intelligent management and reasonable configuration to prevent service interruption or hardware damage caused by overheating.
[0243] like Figure 4 As shown, the key point of the present application is to provide a locally optimal temperature control method, dynamically adjust the flow rate based on temperature changes, find the local optimal limiting point, and achieve temperature control simply and efficiently; compared with the general temperature control method, this method sets two preset values, a first preset value and a fifth preset value, to achieve the purpose of controlling temperature, protecting business and extending the service life of equipment.
[0244] This technical solution is a flow dynamic adjustment mechanism based on real-time temperature monitoring, which is composed of a temperature monitoring module, a monitoring calculation module, a flow control module, and a data analysis module. It realizes an overall solution of dual preset value temperature control through the application of local optimal solution ideas in flow regulation and through flow limitation applications.
[0245] In addition, the increase in server network card traffic means that the server workload increases, which will cause the internal temperature of the server to rise; the server temperature control is optimized and adjusted according to the mapping relationship between the server temperature and the corresponding network card traffic, including:
[0246] Use system monitoring tools (such as Nagios, Zabbix) to monitor server CPU load, memory usage, disk I / O, network traffic and other indicators in real time;
[0247] Install temperature sensors to monitor the temperature of key server hardware;
[0248] Determine the correlation between network card traffic changes and server temperature through data analysis;
[0249] Use machine learning to identify temperature variation patterns of servers under different loads and predict server overheating issues;
[0250] Adjust the cooling system of the server room based on the data analysis results;
[0251] For servers that support intelligent temperature control, the fan speed is automatically adjusted according to the actual temperature;
[0252] Use load balancing technology to distribute traffic to different servers to avoid overloading a single server and causing excessive temperature.
[0253] Optimize the performance of applications or services, reduce unnecessary computing overhead, and reduce power consumption and heat generation;
[0254] Replace server hardware components with higher performance ratios, improve the physical structure design of the server, and increase air circulation efficiency;
[0255] The interval time threshold checks the server hardware status and replaces faulty components in time to prevent overheating caused by hardware failure.
[0256] Through the above measures, the temperature of the server can be effectively managed and controlled to ensure its stable operation; at the same time, the temperature control management strategy can be continuously optimized through continuous data collection and analysis.
[0257] The temperature control method provided in the embodiment of the present application may be further improved and optimized without departing from the technical solution of the present application, and these improvements and optimizations should also be regarded as within the scope of protection of the present application.
[0258] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0259] This application reduces the difficulty of implementing server temperature control and reduces the cost of temperature control by determining the flow limit point that meets the demand and avoiding complex scheduling algorithms.
[0260] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0261] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management.
[0262] Embodiment 3
[0263] The present application provides a temperature control device, such as Figure 5 As shown, the device includes an acquisition module, a calculation module, a comparison module, an opening module, a control module, and an optimization module.
[0264] In this embodiment, the acquisition module is used to acquire the temperature of each component of the server, and the components include a central processing unit, a memory, an image processor, and a disk;
[0265] A calculation module is used to calculate the component temperature average value according to the weighted temperature of each component of the server, and set the component temperature average value as the server temperature value; calculate the server temperature change rate according to time and server temperature change; calculate the linear regression slope through temperature monitoring at multiple time points;
[0266] A comparison module, used for comparing the server temperature value with a first preset value;
[0267] An activation module, configured to activate a server temperature calculation control process in response to the server temperature value being greater than a first preset value;
[0268] The control module is used to calculate the flow limit percentage according to the server temperature change rate in response to the linear regression slope being greater than the second preset value, and control the server temperature by the flow limit percentage until the server temperature value is less than the first preset value.
[0269] In one embodiment, the calculation module is used to obtain the time change threshold Δt, the current server temperature value T t+1 , initial server temperature value T t ;
[0270] By formula: ΔT = T t+1 -T t / Δt, calculate the server temperature change rate ΔT.
[0271] In one embodiment, the calculation module is used to obtain the value ti of the i-th monitoring time point and the average value of all monitoring time points. The total number of monitoring time points n;
[0272] Get the server temperature value Ti corresponding to the i-th time point and the average value of the server temperature at all time points
[0273] By formula Calculate the linear regression slope k.
[0274] In one of the embodiments, the control module is used to obtain the initial flow limit percentage L1 of the server network card and the temperature change rate ΔT of the server;
[0275] The current flow limit percentage L2 of the server network card is calculated by the formula L2=L1+ΔT;
[0276] Controlling the server temperature by using the current flow limit percentage of the server network card;
[0277] The controlling the server temperature by the current flow limit percentage of the server network card includes:
[0278] When the current flow limit percentage of the server network card is a third preset value, the time change threshold t2-t1, the server temperature value T2 at time t2, and the server temperature value T1 at time t1 are obtained;
[0279] The temperature change rate k1 of the first server is calculated by the formula: k1=T2-T1 / t2-t1;
[0280] In response to the temperature change rate k1 of the first server being greater than the second preset value, the flow limit percentage of the server network card is continued to be increased, and the current flow limit percentage of the server network card is set to a fourth preset value;
[0281] When the current flow limit percentage of the server network card is a fourth preset value, obtaining a time change threshold t4-t3, a server temperature value T3 at time t3, and a server temperature value T4 at time t4;
[0282] The temperature change rate k2 of the second server is calculated by the formula: k2=T3-T4 / t4-t3;
[0283] In response to the second server temperature change rate k2 being greater than the second preset value, the current flow limit percentage of the server network card is maintained at the fourth preset value to control the server temperature.
[0284] In one of the embodiments, the control module is used to control the flow restriction percentage according to the current server temperature value in response to the linear regression slope being less than a second preset value;
[0285] The controlling of the flow limit percentage according to the current server temperature value includes:
[0286] When the temperature value of the server is greater than a fifth preset value, the current flow limit percentage of the server is maintained unchanged;
[0287] When the temperature value of the server is less than a fifth preset value, the flow limit percentage of the server is closed.
[0288] In one of the embodiments, the optimization module is used to record the historical data of the server temperature and the corresponding network card traffic;
[0289] Creating a mapping relationship between the server temperature and the corresponding network card flow rate according to the historical data of the server temperature and the corresponding network card flow rate;
[0290] The server temperature control is optimized and adjusted according to the mapping relationship between the server temperature and the corresponding network card flow.
[0291] In one of the embodiments, the control module is used to monitor the load of each server through a load balancer;
[0292] Reassign tasks to servers through intelligent scheduling algorithms and the current server workload, wherein the scheduling algorithms include polling algorithms, least connection algorithms, and IP hash algorithms;
[0293] Automatically adjust the number of servers according to the server load task ratio;
[0294] The automatic correction of the number of servers according to the server load task ratio includes:
[0295] When the server load task increases and the server temperature is greater than a first preset value, an additional server is started, part of the load is transferred to the additional server through a load balancer, and the server temperature is controlled;
[0296] When the server load task decreases and the server temperature is less than a first preset value, the redundant servers are shut down;
[0297] When the server is in off-peak hours, the hardware device uses energy-saving mode to automatically reduce the processor speed and / or shut down non-critical components.
[0298] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0299] This application reduces the difficulty of implementing server temperature control by determining the flow limit point that meets the demand and avoids complex scheduling algorithms, while reducing the cost of temperature control.
[0300] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0301] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management.
[0302] Embodiment 4
[0303] The present invention also provides a temperature control device, comprising:
[0304] one or more processors;
[0305] A storage device for storing one or more programs;
[0306] When the one or more programs are executed by the one or more processors, the one or more processors perform the temperature control method described below:
[0307] Obtaining the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0308] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0309] Comparing the server temperature value with a first preset value;
[0310] In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process;
[0311] Calculate the server temperature change rate based on time and server temperature change;
[0312] The linear regression slope was calculated by monitoring the temperature at multiple time points;
[0313] In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
[0314] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0315] This application reduces the difficulty of implementing server temperature control and reduces the cost of temperature control by determining the flow limit point that meets the demand and avoiding complex scheduling algorithms.
[0316] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0317] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management.
[0318] Embodiment 5
[0319] The present application provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the following temperature control method can be executed:
[0320] Obtaining the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0321] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0322] Comparing the server temperature value with a first preset value;
[0323] In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process;
[0324] Calculate the server temperature change rate based on time and server temperature change;
[0325] The linear regression slope was calculated by monitoring the temperature at multiple time points;
[0326] In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
[0327] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0328] This application reduces the difficulty of implementing server temperature control and reduces the cost of temperature control by determining the flow limit point that meets the demand and avoiding complex scheduling algorithms.
[0329] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0330] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management.
[0331] Embodiment 6
[0332] The present application also provides a computer program product, including a computer program, which can implement the following temperature control method when executed by a processor:
[0333] Obtaining the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0334] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0335] Comparing the server temperature value with a first preset value;
[0336] In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process;
[0337] Calculate the server temperature change rate based on time and server temperature change;
[0338] The linear regression slope was calculated by monitoring the temperature at multiple time points;
[0339] In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
[0340] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0341] This application reduces the difficulty of implementing server temperature control and reduces the cost of temperature control by determining the flow limit point that meets the demand and avoiding complex scheduling algorithms.
[0342] The technical solution provided in the embodiment of the present application monitors the server temperature in real time, dynamically adjusts the flow to control power consumption, and prevents the equipment from overheating; while ensuring temperature control, it minimizes the impact on server performance and avoids serious performance degradation.
[0343] The technical solution provided by the embodiment of the present application is simple and efficient, does not require a complex scheduling algorithm, and finds the optimal flow limitation solution simply and efficiently through the idea of local optimal solution; at the same time, the technical solution is low-cost, does not require additional hardware investment, and reduces the cost of temperature control management.
[0344] Embodiment 7
[0345] The present application provides a computer storage medium, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the following steps are implemented:
[0346] Obtaining the temperature of each component of the server, wherein the components include a central processing unit, a memory, an image processor, and a disk;
[0347] Calculate the average temperature of each component of the server according to the weighted temperature of each component, and set the average temperature of the component as the server temperature value;
[0348] Comparing the server temperature value with a first preset value;
[0349] In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process;
[0350] Calculate the server temperature change rate based on time and server temperature change;
[0351] The linear regression slope was calculated by monitoring the temperature at multiple time points;
[0352] In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
[0353] In one embodiment, calculating the server temperature change rate according to time and server temperature change includes:
[0354] Get the time change threshold Δt and the current server temperature value T t+1 , initial server temperature value T t ;
[0355] By formula: ΔT = T t+1 -T t / Δt, calculate the server temperature change rate ΔT.
[0356] In one embodiment, the calculating the linear regression slope by monitoring the temperature at multiple time points comprises:
[0357] Get the value ti of the i-th monitoring time point and the average value of all monitoring time points The total number of monitoring time points n;
[0358] Get the server temperature value Ti corresponding to the i-th time point and the average value of the server temperature at all time points
[0359] By formula Calculate the linear regression slope k.
[0360] In one embodiment, the calculating the flow limit percentage according to the server temperature change rate and controlling the server temperature by the flow limit percentage includes:
[0361] Obtain the initial flow limit percentage L1 of the server network card and the temperature change rate ΔT of the server;
[0362] The current flow limit percentage L2 of the server network card is calculated by the formula L2=L1+ΔT;
[0363] Controlling the server temperature by using the current flow limit percentage of the server network card;
[0364] The controlling the server temperature by the current flow limit percentage of the server network card includes:
[0365] When the current flow limit percentage of the server network card is a third preset value, the time change threshold t2-t1, the server temperature value T2 at time t2, and the server temperature value T1 at time t1 are obtained;
[0366] The temperature change rate k1 of the first server is calculated by the formula: k1=T2-T1 / t2-t1;
[0367] In response to the temperature change rate k1 of the first server being greater than the second preset value, the flow limit percentage of the server network card is continued to be increased, and the current flow limit percentage of the server network card is set to a fourth preset value;
[0368] When the current flow limit percentage of the server network card is a fourth preset value, obtaining a time change threshold t4-t3, a server temperature value T3 at time t3, and a server temperature value T4 at time t4;
[0369] The temperature change rate k2 of the second server is calculated by the formula: k2=T3-T4 / t4-t3;
[0370] In response to the second server temperature change rate k2 being greater than the second preset value, the current flow limit percentage of the server network card is maintained at the fourth preset value to control the server temperature.
[0371] In one embodiment, the method further comprises:
[0372] In response to the linear regression slope being less than a second preset value, controlling the flow restriction percentage according to the current server temperature value;
[0373] The controlling of the flow limit percentage according to the current server temperature value includes:
[0374] When the server temperature value is greater than a fifth preset value, the current flow limit percentage of the server is maintained unchanged;
[0375] When the temperature value of the server is less than a fifth preset value, the flow limit percentage of the server is closed.
[0376] In one embodiment, the flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value, including:
[0377] Record the historical data of the server temperature and the corresponding network card flow;
[0378] Creating a mapping relationship between the server temperature and the corresponding network card flow rate according to the historical data of the server temperature and the corresponding network card flow rate;
[0379] The server temperature control is optimized and adjusted according to the mapping relationship between the server temperature and the corresponding network card flow.
[0380] In one embodiment, the method further comprises:
[0381] Monitor the load of each server through a load balancer;
[0382] Reassign tasks to servers through intelligent scheduling algorithms and the current server workload, wherein the scheduling algorithms include polling algorithms, least connection algorithms, and IP hash algorithms;
[0383] Automatically adjust the number of servers according to the server load task ratio;
[0384] The automatic correction of the number of servers according to the server load task ratio includes:
[0385] When the server load task increases and the server temperature is greater than a first preset value, an additional server is started, part of the load is transferred to the additional server through a load balancer, and the server temperature is controlled;
[0386] When the server load task decreases and the server temperature is less than a first preset value, the redundant servers are shut down;
[0387] When the server is in off-peak hours, the hardware device uses energy-saving mode to automatically reduce the processor speed and / or shut down non-critical components.
[0388] This application reduces the difficulty of implementing server temperature control and reduces the cost of temperature control by determining the flow limit point that meets the demand and avoiding complex scheduling algorithms.
[0389] Figure 6 An exemplary system provided for Embodiment 7 of the present application that can be used to implement various embodiments described in the present application;
[0390] like Figure 6 As shown, in some embodiments, the system can be used as any of the above-mentioned devices for temperature control in each of the described embodiments. In some embodiments, the system may include one or more computer-readable media (e.g., system memory or NVM / storage device) having results and one or more processors (e.g., (one or more) processors) coupled to the one or more computer-readable media and configured to execute the results to implement the module to perform the actions described in this application.
[0391] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0392] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0393] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A temperature control method, characterized in that: The method is applied to a server, and the method comprises: Obtaining the temperature value of the server; Comparing the server temperature value with a first preset value; In response to the server temperature value being greater than a first preset value, starting a server temperature calculation control process; Calculate the server temperature change rate based on time and server temperature change; The linear regression slope was calculated by monitoring the temperature at multiple time points; In response to the linear regression slope being greater than a second preset value, a flow limit percentage is calculated according to the server temperature change rate, and the server temperature is controlled by the flow limit percentage until the server temperature value is less than a first preset value.
2. The temperature control method according to claim 1, characterized in that: The calculating the server temperature change rate according to time and server temperature change includes: Get the time change threshold Δt and the current server temperature value T t+1 , initial server temperature value T t ; By formula: ΔT = T t+1 -T t / Δt, calculate the server temperature change rate ΔT.
3. The temperature control method according to claim 1, characterized in that: The linear regression slope is calculated by monitoring the temperature at multiple time points, including: Get the value ti of the i-th monitoring time point and the average value of all monitoring time points The total number of monitoring time points n; Get the server temperature value Ti corresponding to the i-th time point and the average value of the server temperature at all time points By formula Calculate the linear regression slope k.
4. The temperature control method according to claim 2, characterized in that: The calculating the flow limit percentage according to the server temperature change rate and controlling the server temperature by the flow limit percentage includes: Obtain the initial flow limit percentage L1 of the server network card and the temperature change rate ΔT of the server; The current flow limit percentage L2 of the server network card is calculated by the formula L2=L1+ΔT; Controlling the server temperature by using the current flow limit percentage of the server network card; The controlling the server temperature by the current flow limit percentage of the server network card includes: When the current flow limit percentage of the server network card is a third preset value, the time change threshold t2-t1, the server temperature value T2 at time t2, and the server temperature value T1 at time t1 are obtained; The temperature change rate k1 of the first server is calculated by the formula: k1=T2-T1 / t2-t1; In response to the temperature change rate of the first server being greater than a second preset value, the flow limit percentage of the server network card is continued to be increased, and the current flow limit percentage of the server network card is set to a fourth preset value; When the current flow limit percentage of the server network card is a fourth preset value, obtaining a time change threshold t4-t3, a server temperature value T3 at time t3, and a server temperature value T4 at time t4; The temperature change rate k2 of the second server is calculated by the formula: k2=T3-T4 / t4-t3; In response to the temperature change rate of the second server being greater than the second preset value, the current flow limit percentage of the server network card is maintained at a fourth preset value to control the server temperature.
5. The temperature control method according to claim 1, characterized in that: The method further comprises: In response to the linear regression slope being less than a second preset value, controlling the flow restriction percentage according to the current server temperature value; The controlling of the flow limit percentage according to the current server temperature value includes: When the server temperature value is greater than a fifth preset value, the current flow limit percentage of the server is maintained unchanged; When the temperature value of the server is less than a fifth preset value, the flow limit percentage of the server is closed.
6. The temperature control method according to claim 1, characterized in that: The method of calculating the flow limit percentage according to the server temperature change rate and controlling the server temperature by the flow limit percentage until the server temperature value is less than a first preset value includes: Record the historical data of the server temperature and the corresponding network card flow; Creating a mapping relationship between the server temperature and the corresponding network card flow rate according to the historical data of the server temperature and the corresponding network card flow rate; The server temperature control is optimized and adjusted according to the mapping relationship between the server temperature and the corresponding network card flow.
7. The temperature control method according to claim 1, characterized in that: The method further comprises: Monitor the load of each server through a load balancer; Reassign tasks to servers through intelligent scheduling algorithms and the current server workload, wherein the scheduling algorithms include polling algorithms, least connection algorithms, and IP hash algorithms; Automatically adjust the number of servers according to the server load task ratio; The automatic correction of the number of servers according to the server load task ratio includes: When the server load task increases and the server temperature is greater than a first preset value, an additional server is started, part of the load is transferred to the additional server through a load balancer, and the server temperature is controlled; When the server load task decreases and the server temperature is less than a first preset value, the redundant servers are shut down; When the server is in off-peak hours, the hardware device uses energy-saving mode to automatically reduce the processor speed and / or shut down non-critical components.
8. A temperature control device, characterized in that: The device is applied to a server, and comprises: An acquisition module, used to acquire the temperature value of the server; A calculation module is used to calculate the server temperature change rate according to time and server temperature change; and to calculate the linear regression slope by monitoring the temperature at multiple time points; A comparison module, used for comparing the server temperature value with a first preset value; An activation module, configured to activate a server temperature calculation control process in response to the server temperature value being greater than a first preset value; The control module is used to calculate the flow limit percentage according to the server temperature change rate in response to the linear regression slope being greater than the second preset value, and control the server temperature by the flow limit percentage until the server temperature value is less than the first preset value.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the temperature control method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the temperature control method according to any one of claims 1 to 7 are implemented.