Energy-saving control method, device, equipment and storage medium for servers in a cluster

By obtaining the total dormant duration and balanced duration of the server in the intelligent computing cluster, and accurately selecting the server to be woken up, the problem of server wake-up delay affecting task processing is solved, and efficient energy management and system performance balance is achieved.

CN119356891BActive Publication Date: 2025-04-01PENG CHENG LAB
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411930328.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-26
Publication Date
2025-04-01
Estimated Expiration
2044-12-26

AI Technical Summary

Technical Problem

In smart computing clusters, the delay in changing the server from sleep to normal working state is long, which may affect the timely processing of tasks, especially in application scenarios with high real-time requirements.

Method used

By obtaining the total sleep time and balanced time of each server in the hibernation state in the cluster, select the server whose total sleep time is greater than or equal to the hibernation period as the server to be woken up, and control its exit from the hibernation state.

Benefits of technology

On the premise of reducing the overall energy consumption of the cluster, it avoids affecting the system performance, realizes more refined energy management, minimizes the impact on the system processing performance, and improves the overall energy efficiency level.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119356891B_ABST
    Figure CN119356891B_ABST
Patent Text Reader

Abstract

This application provides an energy-saving control method, apparatus, device, and storage medium for servers in a cluster, relating to the field of server technology. The method obtains the total sleep time of each hibernating server in the cluster, obtains the balanced sleep time of each hibernating server, selects hibernating servers with a total sleep time greater than or equal to the balanced sleep time as servers to be woken up, and controls at least one server to exit the hibernation state. The balanced sleep time is used as a criterion for evaluating whether to end the hibernation state to determine under what circumstances waking up a hibernating server can most effectively reduce energy consumption. The server with the greatest potential energy-saving value is selected from the cluster to perform hibernation or wake-up operations, rather than simply based on whether the server is idle. This not only achieves more refined energy management but also minimizes the impact on system processing performance, thereby improving overall energy efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of server technology, and in particular to an energy-saving control method, device, equipment and storage medium for servers in a cluster. Background Art

[0002] In the intelligent computing cluster, server energy consumption management is to monitor the working status of the server and take measures to reduce energy consumption during the idle period of the server according to the energy consumption management strategy. It involves real-time monitoring and analysis of multi-dimensional load data such as server CPU usage, memory usage, network transmission, etc., so as to optimize energy utilization efficiency.

[0003] In the related technology, the energy consumption management of intelligent computing clusters adopts the strategy of immediately putting idle servers to sleep. Although this strategy can reduce the overall energy consumption of the cluster to a certain extent, the delay for the server to switch from sleep state to normal working state is generally several minutes to more than ten minutes. The accumulation of too many server wake-up delays may affect the timely processing of tasks, especially in application scenarios with high real-time requirements, which may lead to problems such as untimely data processing and delayed calculation results. Summary of the invention

[0004] The main purpose of the embodiments of the present application is to propose an energy-saving control method, device, equipment and storage medium for servers in a cluster, so as to avoid affecting system performance while reducing the overall energy consumption of the cluster.

[0005] To achieve the above object, a first aspect of an embodiment of the present application proposes an energy-saving control method for a server in a cluster, comprising:

[0006] Get the total sleep time of each dormant server in the cluster;

[0007] Obtaining the balanced duration of each of the dormant servers, the balanced duration being the duration corresponding to when the total energy consumption value generated in the process of the servers in the cluster switching from the standby state to the dormant state and then recovering from the dormant state to the standby state is equal to the standby energy consumption value of maintaining the standby state;

[0008] The dormant servers whose total dormant time is greater than or equal to the balanced time are selected as servers to be awakened, and at least one of the servers to be awakened is controlled to exit the dormant state.

[0009] In some embodiments, the calculation process of the equalization duration includes the following steps:

[0010] Acquire a first energy consumption value of the server when the server changes from a standby state to a dormant state, a second energy consumption value when the server maintains the dormant state, and a third energy consumption value when the server recovers from the dormant state to the standby state, wherein the representation of the second energy consumption value includes the balancing duration;

[0011] Acquire the standby energy consumption value of the server maintaining the standby state, wherein the representation of the standby energy consumption value includes the equilibrium duration;

[0012] Calculating the sum of the first energy consumption value, the second energy consumption value and the third energy consumption value as the total energy consumption value;

[0013] When the total energy consumption value and the standby energy consumption value are the same, the equilibrium duration is obtained.

[0014] In some embodiments, obtaining a first energy consumption value of the server when the server changes from a standby state to a dormant state includes:

[0015] Obtaining a first conversion duration corresponding to a first conversion process of the server from a standby state to a dormant state and a first average power during the first conversion process;

[0016] The product of the first conversion time and the first average power is calculated to obtain the first energy consumption value.

[0017] In some embodiments, obtaining a third energy consumption value when the server is restored from a dormant state to a standby state includes:

[0018] Acquire a second conversion duration corresponding to a second conversion process of the server recovering from a dormant state to a standby state and a second average power in the second conversion process;

[0019] The product of the second conversion time and the second average power is calculated to obtain the third energy consumption value.

[0020] In some embodiments, obtaining a second energy consumption value of the server maintained in a dormant state includes:

[0021] Obtaining the sleep power of the server in a sleep state;

[0022] Setting the balance time minus the first conversion time and the second conversion time as the sleep time;

[0023] The product of the sleep time and the sleep power is calculated to obtain the second energy consumption value.

[0024] In some embodiments, selecting the dormant server whose total dormant time is greater than or equal to the balanced time as the server to be awakened includes:

[0025] Identify in real time the relationship between the total sleep duration and the balanced duration of each sleep server, and when the total sleep duration is less than the balanced duration, generate a first sleep identifier of the sleep server, otherwise generate a second sleep identifier;

[0026] The dormant server corresponding to the second dormant identifier is selected as the server to be awakened.

[0027] In some embodiments, after selecting the dormant server whose total dormant duration is greater than or equal to the equilibrium duration as the server to be awakened, the method further includes:

[0028] Obtaining the candidate number of the servers to be awakened, the standby number corresponding to the servers in the cluster in standby state, and the preset server redundancy number;

[0029] When the redundant number of servers is greater than the standby number, calculating a first difference between the redundant number of servers and the standby number;

[0030] When the first difference is less than or equal to the number of candidates, the second difference between the number of candidates and the first difference is calculated, and the servers corresponding to the number of the second difference are removed from the servers to be awakened; when the first difference is greater than the number of candidates, the third difference between the first difference and the number of candidates is calculated, and other servers corresponding to the number of the third difference are selected from the dormant servers and added to the servers to be awakened, or servers in idle state corresponding to the number of the third difference are selected from the cluster and switched to standby state.

[0031] To achieve the above-mentioned purpose, a second aspect of an embodiment of the present application proposes an energy-saving control device for a server in a cluster, comprising:

[0032] Total sleep time acquisition module: used to obtain the total sleep time of each dormant server in the cluster;

[0033] Balanced duration acquisition module: used to obtain the balanced duration of each of the dormant servers, the balanced duration being the duration corresponding to the time when the total energy consumption value generated in the process of the servers in the cluster switching from the standby state to the dormant state and then recovering from the dormant state to the standby state is equal to the standby energy consumption value of maintaining the standby state;

[0034] A wake-up selection module is used to select the dormant servers whose total dormancy duration is greater than or equal to the equilibrium duration as servers to be awakened, and control at least one of the servers to be awakened to exit the dormant state.

[0035] To achieve the above objectives, a third aspect of an embodiment of the present application proposes an electronic device, which includes a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the method described in the first aspect is implemented.

[0036] To achieve the above-mentioned purpose, the fourth aspect of an embodiment of the present application proposes a storage medium, which is a storage medium. The storage medium stores a computer program, and when the computer program is executed by a processor, the method described in the first aspect is implemented.

[0037] The energy-saving control method, device, equipment and storage medium of the server in the cluster proposed in the embodiment of the present application obtains the total sleep time of each dormant server in the cluster in a dormant state, obtains the balanced time of each dormant server, and the balanced time is the time corresponding to the total energy consumption value generated in the process of the server changing from the standby state to the dormant state and then recovering from the dormant state to the standby state when the total energy consumption value is equal to the standby energy consumption value of the standby state, and finally selects the dormant server whose total sleep time is greater than or equal to the balanced time as the server to be awakened, and controls at least one server to be awakened to exit the dormant state. The embodiment of the present application uses the balanced time as a criterion for evaluating whether to end the dormant state, so as to determine under what circumstances waking up the dormant server can most effectively reduce energy consumption. Specifically, the balanced time corresponds to the energy consumption balance point of energy saving. When the total sleep time of a dormant server has exceeded its balanced time, it indicates that the dormant energy consumption of the server is better than the standby energy consumption, that is, higher than the energy consumption balance point, so that the energy saving effect has been generated. When the total sleep time does not reach the balanced time, that is, it is lower than the energy consumption balance point, it means that the dormant server needs to continue to be in a dormant state for a period of time to reach the energy consumption balance point. If the server needs to be woken up at this time, priority will be given to waking up those servers whose total sleep time is higher than the energy consumption balance point to achieve better energy saving effects. This method can accurately select servers with the greatest potential energy saving value from the cluster to perform sleep or wake-up operations, rather than making decisions based solely on whether the server is idle. This approach not only achieves more refined energy management, but also minimizes the impact on system processing performance, thereby improving overall energy efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] Figure 1 It is a flow chart of the energy-saving control method of the server in the cluster provided in the embodiment of the present application.

[0039] Figure 2 It is a flow chart of the calculation process of the equalization duration provided in an embodiment of the present application.

[0040] Figure 3 This is a flowchart for obtaining a first energy consumption value when a server switches from a standby state to a sleep state, provided in an embodiment of the present application.

[0041] Figure 4 This is a schematic diagram of the change in server power over time during the calculation of the balancing duration provided in an embodiment of the present application.

[0042] Figure 5 This is a flowchart for obtaining a third energy consumption value when a server is restored from a sleep state to a standby state, provided in an embodiment of the present application.

[0043] Figure 6 This is a flowchart for obtaining a second energy consumption value of a server maintained in a sleep state provided by an embodiment of the present application.

[0044] Figure 7 It is a schematic diagram of the relationship between the balancing time and energy consumption provided in an embodiment of the present application.

[0045] Figure 8 This is a flowchart of selecting a dormant server whose total dormancy time is greater than or equal to the equilibrium time as a server to be awakened, provided in an embodiment of the present application.

[0046] Fig. 9 This is a flowchart for adjusting the number of servers to be awakened provided in an embodiment of the present application.

[0047] Fig.10 This is a structural block diagram of an energy-saving control device for servers in a cluster provided in another embodiment of the present application.

[0048] Fig.11 It is a schematic diagram of the hardware structure of the electronic device provided in the embodiment of the present application. DETAILED DESCRIPTION

[0049] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0050] It should be noted that although the functional modules are divided in the device schematic and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart.

[0051] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0052] With the rapid development of science and technology, intelligent computing clusters (hereinafter referred to as intelligent computing clusters) are playing an increasingly important role in the field of artificial intelligence research. However, the huge computing power of these intelligent computing clusters is often accompanied by high energy consumption requirements. For supercomputing centers around the world, energy consumption has become a challenge that cannot be ignored. Taking the current world-leading intelligent computing cluster as an example, the peak power consumption of the Frontier supercomputer system reached 22.7 megawatts, while the peak power consumption of the Aurora supercomputer system was even higher, reaching 24.7 megawatts. This shows that while performance is improving, the energy consumption of intelligent computing clusters is also continuing to increase.

[0053] One of the main reasons for the increase in energy consumption is that the large-scale AI model training tasks running on the intelligent computing cluster consume a lot of energy. With the advancement of deep learning and neural network technology, the amount of computing and energy consumption required to train a top AI model is also rising sharply. For example, the energy consumed by OpenAI's GPT-3 model during training is estimated to be hundreds of thousands of kilowatt-hours; the ChatGPT model responds to about 200 million requests per day, consuming more than 500,000 degrees of electricity in the process. With the expansion of model parameter scale and the increase in computing requirements, the energy consumption demand of intelligent computing clusters for these tasks has become very huge. In the future, with the development and deployment of larger-scale and more complex AI models, the energy consumption problem of intelligent computing clusters will become more and more serious.

[0054] It can be seen that how to reduce the energy consumption of intelligent computing clusters while improving computing power has become one of the key challenges for the future development of science and technology. The energy consumption problem of intelligent computing clusters is not only a technical problem, but also an environmental problem. Faced with the pressure of global climate change, how to reduce the energy consumption of intelligent computing clusters while improving computing power has become one of the key challenges for the future development of science and technology. In the development of intelligent computing clusters, we should not only focus on the improvement of computing power, but also strive to optimize energy consumption to achieve the goal of sustainable development. In intelligent computing clusters, server energy consumption management is to monitor the working status of the server and take measures to reduce energy consumption during the idle period of the server according to the energy consumption management strategy. It involves real-time monitoring and analysis of multi-dimensional load data such as server CPU usage, memory usage, network transmission, etc., so as to optimize energy utilization efficiency.

[0055] Server hibernation is a technology that puts idle servers into a state of minimum power consumption. When a server enters hibernation mode, the data in its memory is saved to disk, and then components such as the CPU, GPU, and memory are put into a state of minimum power consumption. The benefit of this approach is that when the server is not in operation, its standby power consumption can be significantly reduced. Once a new computing task needs to be executed, the server can be awakened from the hibernation state and restored to full power operation.

[0056] In large intelligent computing clusters, due to the randomness of the time when users submit computing tasks and the fluctuation of computing demand caused by the day and night periodicity, usually not all servers need to be in operation all the time. Therefore, server hibernation technology has significant application value in this environment. For example, at night or during non-peak hours, when computing tasks are reduced, some servers can enter a dormant state, thereby effectively reducing the energy consumption of the entire intelligent computing cluster. When computing demand rises again, these servers can be quickly awakened and put into work to ensure timely processing of computing tasks.

[0057] The value of server hibernation technology in intelligent computing clusters is not only reflected in the reduction of energy consumption, but also in the positive impact on the environment and the reduction of operating costs. By properly managing the operating status of the server, the data center can significantly reduce power consumption and reduce carbon footprint while meeting computing needs. In addition, with the continuous development of server hibernation technology, its wake-up speed and energy consumption management are also being optimized. This means that in the future, intelligent computing clusters will be able to respond to dynamic computing needs more flexibly and efficiently, and achieve higher resource utilization. The value of server hibernation technology in intelligent computing clusters is not only reflected in the reduction of energy consumption, but also in the positive impact on the environment and the reduction of operating costs. By properly managing the operating status of the server, the data center can significantly reduce power consumption and reduce carbon footprint while meeting computing needs. In addition, with the continuous development of server hibernation technology, its wake-up speed and energy consumption management are also being optimized. This means that in the future, intelligent computing clusters will be able to respond to dynamic computing needs more flexibly and efficiently, and achieve higher resource utilization.

[0058] In the related art, the energy consumption management of the intelligent computing cluster adopts the strategy of immediately hibernating idle servers. The server can enter the hibernation state immediately when there is no task running, and quickly reduce its power consumption to the minimum. This method enables the intelligent computing cluster to significantly reduce energy consumption when it is under low load or idle, thereby reducing the overall operating cost and reducing the negative impact on the environment. This has a significant energy-saving effect for large clusters that run around the clock. However, under this strategy, the delay for the server to switch from the hibernation state to the normal working state is generally a few minutes to more than ten minutes. When a large number of tasks suddenly arrive, the server in the hibernation state needs to be re-awakened, and this process will bring a certain amount of time delay. The superposition of the wake-up delay of too many servers may affect the timely processing of tasks, especially in application scenarios with high real-time requirements, which may lead to problems such as untimely data processing and delayed calculation results. In addition, the sleep and wake-up process itself also consumes a certain amount of energy. If sleep and wake-up occur frequently, and the server needs to enter the sleep state again immediately after wake-up, this energy consumption may offset the energy-saving effect it brings.

[0059] Based on this, the embodiment of the present application provides an energy-saving control method, device, equipment and storage medium for servers in a cluster, using the balanced duration as a standard for evaluating whether to end the dormant state, so as to determine under what circumstances waking up the dormant server can most effectively reduce energy consumption. Specifically, the balanced duration corresponds to the energy consumption balance point of energy saving. When the total dormant duration of a dormant server has exceeded its balanced duration, it indicates that the dormant energy consumption of the server is better than the standby energy consumption, that is, higher than the energy consumption balance point, and energy saving effect has been achieved. When the total dormant duration does not reach the balanced duration, that is, lower than the energy consumption balance point, it means that the dormant server needs to continue to be in a dormant state for a period of time to reach the energy consumption balance point. At this time, if the server needs to be woken up, those servers whose total dormant duration is higher than the energy consumption balance point are woken up first to obtain better energy saving effect. This method can accurately select servers with the greatest potential energy saving value from the cluster to perform dormancy or wake-up operations, rather than making decisions based solely on whether the server is in an idle state. This method not only achieves more refined energy management, but also minimizes the impact on system processing performance, thereby improving the overall energy efficiency level.

[0060] The embodiments of the present application provide an energy-saving control method, apparatus, device and storage medium for servers in a cluster, which are specifically described through the following embodiments. First, the energy-saving control method for servers in a cluster in the embodiments of the present application is described.

[0061] The energy-saving control method of the server in the cluster provided by the embodiment of the present application relates to the field of server technology. The energy-saving control method of the server in the cluster provided by the embodiment of the present application can be applied to the terminal, can also be applied to the server side, and can also be a computer program running in the terminal or the server side. For example, the computer program can be a native program or software module in the operating system; it can be a local (Native) application (Application, APP), that is, a program that needs to be installed in the operating system to run, such as a client that supports energy-saving control of the server in the cluster, that is, a program that can be run only by downloading it to the browser environment; it can also be a small program that can be embedded in any APP. In short, the above-mentioned computer program can be any form of application, module or plug-in. Among them, the terminal communicates with the server through a network. The energy-saving control method of the server in the cluster can be executed by the terminal or the server, or by the terminal and the server in collaboration.

[0062] In some embodiments, the terminal may be a smart phone, tablet computer, laptop computer, desktop computer or smart watch, etc. The server may be an independent server, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms; or a service node in a blockchain system, where each service node in the blockchain system forms a peer-to-peer (P2P) network, and the P2P protocol is an application layer protocol running on the Transmission Control Protocol (TCP) protocol. The terminal and the server may be connected via Bluetooth, Universal Serial Bus (USB) or network communication connection methods, which are not limited in this embodiment.

[0063] The present application can be used in many general or special computer system environments or configurations. For example: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, etc. The present application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. The present application can also be practiced in distributed computing environments, in which tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules can be located in local and remote computer storage media including storage devices.

[0064] The following describes an energy-saving control method for servers in a cluster in an embodiment of the present application.

[0065] Figure 1 is an optional flow chart of the energy-saving control method for servers in a cluster provided in an embodiment of the present application. Figure 1 The method may include but is not limited to steps 110 to 130. It can also be understood that this embodiment Figure 1 The order of step 110 to step 130 is not specifically limited, and the order of steps can be adjusted or some steps can be reduced or added according to actual needs.

[0066] Step 110: Obtain the total sleep time of each sleep server in the cluster that is in a sleep state.

[0067] In one embodiment, there are multiple servers in the cluster. The purpose of this embodiment is to determine whether the server in the dormant state continues to execute the dormant process or wakes up. Therefore, the total dormant time of each dormant server in the cluster is first obtained. It is understandable that any server in the cluster can be considered a dormant server if it is in a dormant state.

[0068] The servers in the cluster here are divided into three categories: servers in idle state, servers in standby state, and servers in hibernation state. Among them, when the server is in idle state, although there are no user requests or tasks being processed, the system is still in full operation mode, and all components are powered on, ready to accept new work at any time. Standby state is a low-power mode, in which some components of the server will enter low-power operation or suspend work. For example, some non-critical hardware modules may reduce the operating frequency or suspend operation to reduce power consumption. In hibernation state, the server will save the current system state to storage devices such as hard disks, and then turn off the power of most hardware components. It is a deep energy-saving mode.

[0069] Step 120: Obtain the balanced duration of each dormant server.

[0070] In one embodiment, each server in the cluster has a corresponding equilibrium duration, and the equilibrium duration is the duration corresponding to the time when the total energy consumption value generated in the process of the server switching from the standby state to the dormant state and then recovering from the dormant state to the standby state is equal to the standby energy consumption value of maintaining the standby state. In other words, an equilibrium duration is defined for all servers in the cluster, and the equilibrium duration is used to evaluate the cost-effectiveness of the server's dormant process to energy consumption. At this time, the equilibrium duration corresponding to each dormant server is obtained.

[0071] The following describes how to calculate the equilibrium duration for each server in the cluster.

[0072] In one embodiment, the calculation process of the equilibrium duration of each server is performed in advance, referring to Figure 2 , Figure 2 : is a flow chart of the calculation process of the equalization duration provided in the embodiment of the present application, which specifically includes the following steps:

[0073] Step 210: Obtain a first energy consumption value when the server changes from a standby state to a sleep state, a second energy consumption value when the server maintains in the sleep state, and a third energy consumption value when the server recovers from the sleep state to the standby state.

[0074] In one embodiment, when calculating the balanced duration of the server, it is necessary to control the server to change from a standby state (normal working state) to a sleep state, and after a period of time (theoretically, this time can also be zero) in the sleep state, it is necessary to change from the sleep state to the standby state, and measure the server energy consumption in different states and the corresponding duration in this process.

[0075] In one embodiment, the process of entering the hibernation state from the standby state is first analyzed. When the server enters the hibernation state from the standby state, the computer system performs a series of operations to reduce energy consumption. First, the data in the memory will be saved to the hard disk or solid-state drive, and this process is called memory dump. Then the main hardware components such as the CPU, GPU, and memory will enter a low-power state and almost stop all activities. The duration and energy consumption of the whole process depend on the hardware configuration of the server, the operating system version, and the system services running. For example, some small servers may only take a few seconds to complete the memory dump, while more complex systems may take longer. At the same time, servers running more system services will also have longer memory dump times.

[0076] In this process, the first energy consumption value of the server when it changes from standby state to sleep state is obtained. Figure 3 , Figure 3 The flowchart of obtaining the first energy consumption value of the server from the standby state to the sleep state provided by the embodiment of the present application specifically includes the following steps:

[0077] Step 310: Obtain a first conversion duration corresponding to a first conversion process of the server from a standby state to a sleep state and a first average power in the first conversion process.

[0078] In one embodiment, referring to Figure 4 , Figure 4 This is a schematic diagram of the change in server power over time during the calculation of the balancing duration provided in an embodiment of the present application. Figure 4 In the whole process of the server switching from standby state to sleep state and then switching from sleep state to standby state, the power value of the server corresponding to each moment is obtained according to the collection time, and then the power value is plotted over time. Figure 4 It can be seen that in the idle state, the server has almost no additional activities except for a small amount of system service activities. When the server is continuously in the idle state with no tasks running, the power meter is used to measure the idle power of the server in this state. , standby power value It hardly changes over time and is in a stable state. When the server enters hibernation, due to the need for additional memory dump and other operations, the power value will increase first and then decrease until it enters hibernation completely. Use a power meter to accurately measure the first transition process of the server from standby to hibernation, corresponding to the first transition duration. and the first average power during the first conversion .

[0079] It is understandable that, since the server activity is relatively active during the first conversion process, the first average power Greater than standby power .

[0080] Step 320: Calculate the product of the first conversion time and the first average power to obtain a first energy consumption value.

[0081] In one embodiment, the first conversion duration is obtained And the first average power After that, calculate the first conversion duration And the first average power The product of , expressed as:

[0082] .

[0083] Next, combine Figure 4 Analyze the process of the server recovering from hibernation to standby. When the server recovers from hibernation to standby, that is, wakes up, the system will first restore the memory data from the storage device to the memory, and then restart the key hardware components such as the CPU and GPU in turn to restore the server to normal working state. Similar to the hibernation process, the duration and energy consumption required for waking up also depend on the server's hardware and software configuration, operating system, and running system services.

[0084] In this process, the third energy consumption value of the server when it returns from the sleep state to the standby state is obtained. Figure 5 , Figure 5 This is a flowchart of obtaining a third energy consumption value of a server when it is restored from a dormant state to a standby state provided by an embodiment of the present application, and specifically includes the following steps:

[0085] Step 510: Obtain a second conversion duration corresponding to a second conversion process of the server recovering from a dormant state to a standby state and a second average power in the second conversion process.

[0086] In one embodiment, in combination Figure 4 It can be seen that when in sleep mode, the server's sleep power In a stable state, after entering the wake-up process, the server's power will increase and last for a period of time, and then stabilize after entering the standby state. At this time, the power meter is used to accurately measure the second conversion process of the server's dormant state returning to the standby state, corresponding to the second conversion time. and the second average power during the second conversion process .

[0087] It can be understood that, since the server activity is relatively active during the second conversion process, the second average power Greater than standby power .

[0088] Step 520: Calculate the product of the second conversion time and the second average power to obtain a third energy consumption value.

[0089] In one embodiment, the second conversion duration is obtained and the second average power After that, calculate the second conversion duration and the second average power The product of the third energy consumption is , expressed as:

[0090]

[0091] Next, refer to Figure 4 Analyze the power changes when the server is in a sleep state. When the server is in a sleep state for a long time, use a power meter to measure the sleep power of the server in this state. Since there is no additional activity when the server is in sleep mode, the sleep power consumption is The value of does not change over time. Generally speaking, the sleep power consumption The value is significantly smaller than the standby power consumption For example, on an intelligent computing server with a peak power consumption of 4,000 watts, the standby power consumption is 1,600 watts, while the hibernation power consumption is less than 500 watts.

[0092] In this process, a second energy consumption value of the server in a dormant state is obtained. Figure 6 , Figure 6 This is a flowchart of obtaining a second energy consumption value of a server maintained in a dormant state provided by an embodiment of the present application, which specifically includes the following steps:

[0093] Step 610: Obtain the sleep power of the server in the sleep state.

[0094] In one embodiment, in the sleep state, the sleep power The value of usually does not change over time, so the sleep power can be directly obtained .

[0095] Step 620: Set the sleep time as the balance time minus the first conversion time and the second conversion time.

[0096] In one embodiment, there are two different energy consumption states for the operation scenario of the server: the standby state has continuous standby energy consumption and the total energy consumption value generated by the wake-up process from the standby state to the dormant state and then from the dormant state to the standby state. Therefore, the duration corresponding to the total energy consumption value generated by the process of the server switching from the standby state to the dormant state and then recovering from the dormant state to the standby state is defined as the equilibrium duration. This means that if the server stays in standby mode for longer than the equilibrium time, the energy it consumes will exceed the energy required to directly enter the dormant state and then resume. Therefore, the embodiment of the present application uses the equilibrium time to evaluate the energy consumption balance of the server under different state transitions.

[0097] In one embodiment, the sleep duration is expressed as:

[0098]

[0099] Among them, the balance time Must be greater than the total duration of executing a transition from standby state to hibernation state and from hibernation state to standby state , otherwise this period of time will not be enough to perform a sleep and wake-up operation.

[0100] Step 630: Calculate the product of the sleep time and the sleep power to obtain a second energy consumption value.

[0101] In one embodiment, the second energy consumption value is expressed as:

[0102]

[0103] It can be seen that the representation of the second energy consumption value includes the balancing duration;

[0104] Step 220: Obtain the standby energy consumption value of the server to maintain the standby state.

[0105] In one embodiment, in combination Figure 4 First, obtain the standby power required for the server to maintain standby status Then, the standby energy consumption value of the server in the standby state is calculated according to the equilibrium time. The standby energy consumption value is the product of the equilibrium time and the standby power, which is expressed as: It can be seen that the representation of the standby energy consumption value includes the equilibrium duration.

[0106] Step 230: Calculate the sum of the first energy consumption value, the second energy consumption value and the third energy consumption value as the total energy consumption value.

[0107] In one embodiment, the total energy consumption value is expressed as:

[0108]

[0109] Step 240: When the total energy consumption value and the standby energy consumption value are the same, the equilibrium duration is obtained.

[0110] In one embodiment, the total energy consumption value and the standby energy consumption value are defined to be the same, which is expressed as:

[0111]

[0112] Therefore, the equilibrium duration is expressed as:

[0113]

[0114] For example, for a server in a smart computing cluster, its standby power =1600W, sleep power =450W, first conversion time =3min, second conversion time =12min, first energy consumption value =360kJ, the second energy consumption value =1440kJ. Then the equilibrium time can be calculated according to the above formula =20.22min.

[0115] It is understandable that due to the different server models, operating systems, and services running, the above balance duration calculation formula has different , , , , , Parameters such as , etc. are different, resulting in differences in the balancing time of different servers. Therefore, in actual applications, the embodiment of the present application can pre-calculate a balancing time for each server in the cluster, or calculate the balancing time of each type of server. The calculated balancing time is then stored in a table according to the corresponding relationship with the server. In addition, considering the hardware loss, the balancing time can be updated and calculated once at intervals. This embodiment does not limit this.

[0116] Step 130: Select a dormant server whose total dormant time is greater than or equal to the balanced time as a server to be awakened, and control at least one server to be awakened to exit the dormant state.

[0117] In one embodiment, if the total sleep duration of a certain sleep server is consistent with its equilibrium duration, it can be considered that the energy consumption benefit generated by the sleep server in the sleep state is equal to the energy consumption benefit generated in the standby state, and it is at the energy consumption balance point of energy saving. At this time, if the sleep operation is continued, more energy saving effects will be produced. If the total sleep duration is less than the equilibrium duration, it means that the sleep operation needs to be performed for a period of time before the energy consumption benefit generated by the sleep server in the sleep state can be equal to the energy consumption benefit generated in the standby state. At this time, if the sleep server is awakened, the energy consumption benefit of sleep is not high, and the sleep operation needs to be continued to achieve energy saving effects.

[0118] In one embodiment, referring to Figure 7 , Figure 7 This is a schematic diagram of the relationship between the equilibrium duration and energy consumption provided by the embodiment of the present application. When the total sleep duration is consistent with the equilibrium duration, it is located at the energy consumption balance point. At this time, the sleep energy consumption benefit is consistent with the standby energy consumption benefit. When the total sleep duration is less than the equilibrium duration, it is located to the left of the energy consumption balance point. At this time, the sleep energy consumption benefit is less than the standby energy consumption benefit. When the total sleep duration is greater than the equilibrium duration, it is located to the right of the energy consumption balance point. At this time, the sleep energy consumption benefit is higher than the standby energy consumption benefit.

[0119] In one embodiment, referring to Figure 8 , Figure 8 The flowchart of selecting a dormant server with a total dormant time greater than or equal to the balanced time as a server to be awakened provided by an embodiment of the present application specifically includes the following steps:

[0120] Step 810: Identify in real time the relationship between the total sleep time and the balanced time of each sleep server. When the total sleep time is less than the balanced time, generate a first sleep flag for the sleep server, otherwise generate a second sleep flag.

[0121] In one embodiment, a sleep flag is added to each server in the cluster, and the sleep flag is used to indicate the relationship between the total sleep duration and the balanced duration of the server. For a sleep server, its total sleep duration changes in real time, so the relationship between the total sleep duration and the balanced duration is determined in real time. If the total sleep duration is less than the balanced duration, a first sleep flag of the sleep server is generated, otherwise a second sleep flag is generated. For example, the sleep status of the i-th sleep server is represented as If the total sleep time is less than the balance time, set is the first sleep flag, otherwise, set The second sleep flag is set to enable fast and real-time monitoring of the wake-up timing of each sleep server in the cluster.

[0122] Step 820: Select the dormant server corresponding to the second dormant identifier as the server to be awakened.

[0123] In one embodiment, if the sleep flag is the second sleep flag, that is, At this time, it means that the dormant energy consumption benefit of the dormant server is relatively high and has met the energy-saving requirements. When it needs to be awakened, it can be awakened first. Therefore, the dormant server corresponding to the second dormant identifier is used as the server to be awakened.

[0124] Through the above process, the servers to be awakened that meet the awakening time are determined from the cluster, which can effectively improve the energy efficiency of the intelligent computing cluster. Especially in scenarios where the task density varies greatly, by giving priority to awakening servers with longer sleep time, unnecessary energy consumption can be avoided, ensuring the energy efficiency and response speed of the cluster operation.

[0125] In one embodiment, all servers to be awakened can be awakened, or the number of awakenings can be minimized while meeting the system performance. That is to say, even if some dormant servers can be awakened, the dormant energy consumption benefits generated by their continued dormancy will continue to increase, and their contribution to energy saving will become greater and greater. At this time, you can choose to wake up only some of the servers to be awakened, maximize the use of dormant time, and reduce the energy waste caused by waking up the servers.

[0126] In one embodiment, referring to Fig. 9 , Fig. 9 This is a flowchart of adjusting the number of servers to be awakened provided by an embodiment of the present application, which specifically includes the following steps:

[0127] Step 910: Obtain the candidate number of servers to be awakened, the number of servers in standby state in the cluster, and the preset redundant number of servers.

[0128] In one embodiment, considering the rapid response during the task peak period, it is necessary to keep a certain number of servers in the intelligent computing cluster in standby state, that is, a state where no tasks are running but not dormant. This number is called the preset server redundancy number. The existence of server redundancy can increase the probability of immediate startup when a new task arrives, and avoid the situation where all task-free servers are in dormant state and cannot process tasks immediately. The setting of the server redundancy number in the embodiment of the present application needs to be determined according to the response speed requirements of different cluster systems. For example, for clusters with high response speed requirements, it is necessary to set a larger server redundancy number value; conversely, for clusters with low response speed requirements, a smaller server redundancy number is set.

[0129] In one embodiment, it is necessary to obtain the number of servers to be awakened as the candidate number, the standby number corresponding to the servers in the cluster in the standby state, and the preset server redundancy number.

[0130] Step 920: When the redundant number of servers is greater than the standby number, a first difference between the redundant number of servers and the standby number is calculated.

[0131] In one embodiment, if the number of redundant servers is less than the number of standby servers, it means that the servers corresponding to the number of standby servers can meet the response speed requirement, so no adjustment is made. If the number of redundant servers is greater than the number of standby servers, it is necessary to calculate the first difference between the number of redundant servers and the number of standby servers. For example, if the number of standby servers is 10 and the number of redundant servers is 14, it means that at least 4 more dormant servers need to be awakened to enter the standby state to meet the response speed requirement. The 4 here refers to the first difference between the number of redundant servers, 14, and the number of standby servers, 10.

[0132] Step 930: When the first difference is less than or equal to the number of candidates, calculate the second difference between the number of candidates and the first difference, and remove the servers corresponding to the number of the second difference from the servers to be awakened; when the first difference is greater than the number of candidates, calculate the third difference between the first difference and the number of candidates, select other servers corresponding to the number of the third difference from the dormant servers and add them to the servers to be awakened, or select idle servers corresponding to the number of the third difference from the cluster and put them into standby mode.

[0133] In one embodiment, the first difference is used to indicate that at least this number of dormant servers need to be awakened and placed in a standby state. At this time, if the first difference is less than or equal to the number of candidates, the second difference between the number of candidates and the first difference is calculated, and the servers corresponding to the number of the second difference are removed from the servers to be awakened. For example, if the first difference is 4, the number of candidates is 10, and the second difference between the number of candidates and the first difference is 6, it means that theoretically there are 6 servers to be awakened that can continue to be in a dormant state, so 6 servers need to be removed from the servers to be awakened, and the remaining 4 servers to be awakened are awakened.

[0134] In addition, if the first difference is greater than the number of candidates, the third difference between the first difference and the number of candidates is calculated, and other servers corresponding to the number of the third difference are selected from the dormant servers and added to the servers to be awakened, or servers in idle state corresponding to the number of the third difference are selected from the cluster and put into standby state.

[0135] For example, if the number of candidates is 2, the first difference and the third difference of the number of candidates is 2. At this time, even if all the servers to be awakened are awakened, the system response speed requirement cannot be met, so two more servers need to be added as standby servers. At this time, there are two selection strategies. The first is to select 2 dormant servers from the dormant servers as the servers to be awakened for awakening operations and convert them to standby state. Another option is to select 2 idle servers in the cluster and convert them to standby state. The number of servers that finally remain in standby state is greater than or equal to the number of server redundancy to ensure that the system has sufficient computing resources available at any time.

[0136] There are two control strategies in the related art. One is the keep-awake strategy, that is, all servers are in a state of being available at any time, which means that when a new computing task arrives, the server can start processing immediately without waiting for the wake-up process, thereby avoiding the time delay caused by the server waking up from a dormant state. This ability to respond immediately is particularly important for some time-sensitive tasks, such as real-time data processing, urgent computing tasks, etc. However, the most obvious disadvantage of this method is the significant waste of energy. Even in the absence of any tasks, the server is still in a high power consumption state, which will result in a large waste of power resources. Another strategy is the idle immediate sleep strategy. When the server has no tasks running, it will immediately enter a dormant state and quickly reduce its power consumption to the minimum. This method allows the intelligent computing cluster to significantly reduce energy consumption when it is under low load or idle, thereby reducing overall operating costs and reducing negative impacts on the environment. This is particularly effective for large clusters that run around the clock. However, this method cannot overcome the problem of system performance degradation caused by wake-up delays.

[0137] The advantages and disadvantages of the energy-saving control method for servers in a cluster provided by the embodiment of the present application and the two strategies in the related art can be seen from the following aspects. First, the energy-saving control method for servers in a cluster provided by the embodiment of the present application can achieve the balance of energy efficiency optimization. Compared with the keep awake strategy, the high power consumption operation of the server when there is no task is avoided through the dynamic management of sleep and wake-up. This means that unnecessary energy waste can be greatly reduced without consuming a lot of electricity like the "keep awake" strategy, especially in low-load periods. Compared with the "idle immediate sleep" strategy, the embodiment of the present application avoids the time delay and additional energy consumption caused by frequent wake-ups by accurately measuring and calculating the equilibrium duration. Based on the balanced duration, the server to be awakened is selected, and the timing for each server to be awakened to choose sleep or stay awake can be determined, and servers with a sleep time longer than the balanced duration are preferentially awakened, and refined energy consumption management is performed to avoid unnecessary energy waste.

[0138] Secondly, the energy-saving control method of the server in the cluster provided by the embodiment of the present application can improve the system response speed. Compared with the "keep awake" strategy, the embodiment of the present application can also maintain efficient task response capabilities, but will not increase operating costs due to excessive energy consumption. Compared with the "idle and sleep immediately" strategy, the embodiment of the present application flexibly adjusts the number of servers to be awakened according to the response speed requirements of the system and the actual situation, ensuring that a certain number of servers are on standby, and ensuring that the system can respond quickly when new tasks arrive without waiting for the wake-up process of the dormant server. This flexibility enables the system to respond better when facing dynamic task loads, and will not affect the timeliness of task processing due to frequent wake-ups. It can reduce overall energy consumption while ensuring that the system computing tasks can respond and process in a timely manner.

[0139] In one embodiment, for example, in an intelligent computing cluster with 9,800 servers, if the average operating power consumption of each server is 3,000 W, the total power consumption of all intelligent computing servers in the cluster is If the system utilization rate is 90%, the remaining 10% of the servers are idle. Assuming the idle power consumption is 1600W, =28.028MW to get the total power consumption. If the energy-saving control provided in the embodiment of the present application is executed, the number of redundant servers is set to 100, and the remaining idle servers enter sleep mode. Assuming that the sleep mode power consumption is 450W, the total power consumption at this time is =27.016MW. Therefore, approximately 3.6% energy saving can be achieved.

[0140] The technical solution provided by the embodiment of the present application is to obtain the total sleep time of each dormant server in the cluster in a dormant state, obtain the balanced time of each dormant server, the balanced time is the time corresponding to the total energy consumption value generated in the process of the server changing from the standby state to the dormant state and then recovering from the dormant state to the standby state when the total energy consumption value is equal to the standby energy consumption value of the standby state, and finally select the dormant server whose total sleep time is greater than or equal to the balanced time as the server to be awakened, and control at least one server to be awakened to exit the dormant state. The embodiment of the present application uses the balanced time as a criterion for evaluating whether to end the dormant state, so as to determine under what circumstances waking up the dormant server can most effectively reduce energy consumption. Specifically, the balanced time corresponds to the energy consumption balance point of energy saving. When the total sleep time of a dormant server has exceeded its balanced time, it indicates that the dormant energy consumption of the server is better than the standby energy consumption, that is, higher than the energy consumption balance point, so that the energy saving effect has been generated. When the total sleep time does not reach the balanced time, that is, it is lower than the energy consumption balance point, it means that the dormant server needs to continue to be in a dormant state for a period of time to reach the energy consumption balance point. If the server needs to be woken up at this time, priority will be given to waking up those servers whose total sleep time is higher than the energy consumption balance point to achieve better energy saving effects. This method can accurately select servers with the greatest potential energy saving value from the cluster to perform sleep or wake-up operations, rather than making decisions based solely on whether the server is idle. This approach not only achieves more refined energy management, but also minimizes the impact on system processing performance, thereby improving overall energy efficiency.

[0141] The embodiment of the present application also provides an energy-saving control device for a server in a cluster, which can implement the energy-saving control method for a server in a cluster, referring to Fig.10 , the device comprises:

[0142] The total sleep duration acquisition module 1010 is used to acquire the total sleep duration of each sleep server in the cluster that is in a sleep state.

[0143] Balanced duration acquisition module 1020: used to obtain the balanced duration of each dormant server. The balanced duration is the duration corresponding to the time when the total energy consumption value generated in the process of the server in the cluster switching from standby state to dormant state and then recovering from dormant state to standby state is equal to the standby energy consumption value of maintaining the standby state.

[0144] The wake-up selection module 1030 is used to select a dormant server whose total dormant time is greater than or equal to the balanced time as a server to be awakened, and control at least one server to be awakened to exit the dormant state.

[0145] In one embodiment, the balanced duration acquisition module 1020 is further used for:

[0146] Acquire a first energy consumption value of the server when the server changes from a standby state to a dormant state, a second energy consumption value when the server maintains the dormant state, and a third energy consumption value when the server recovers from the dormant state to the standby state, wherein the representation of the second energy consumption value includes the balancing duration;

[0147] Acquire the standby energy consumption value of the server maintaining the standby state, wherein the representation of the standby energy consumption value includes the equilibrium duration;

[0148] Calculating the sum of the first energy consumption value, the second energy consumption value and the third energy consumption value as the total energy consumption value;

[0149] When the total energy consumption value and the standby energy consumption value are the same, the equilibrium duration is obtained.

[0150] In one embodiment, the balanced duration acquisition module 1020 is further used for:

[0151] Obtaining a first conversion duration corresponding to a first conversion process of the server from a standby state to a dormant state and a first average power during the first conversion process;

[0152] The product of the first conversion time and the first average power is calculated to obtain the first energy consumption value.

[0153] In one embodiment, the balanced duration acquisition module 1020 is further used for:

[0154] Acquire a second conversion duration corresponding to a second conversion process of the server recovering from a dormant state to a standby state and a second average power in the second conversion process;

[0155] The product of the second conversion time and the second average power is calculated to obtain the third energy consumption value.

[0156] In one embodiment, the balanced duration acquisition module 1020 is further used for:

[0157] Obtaining the sleep power of the server in a sleep state;

[0158] Setting the balance time minus the first conversion time and the second conversion time as the sleep time;

[0159] The product of the sleep time and the sleep power is calculated to obtain the second energy consumption value.

[0160] In some embodiments, the wake-up selection module 1030 is further configured to:

[0161] Identify in real time the relationship between the total sleep duration and the balanced duration of each sleep server, and when the total sleep duration is less than the balanced duration, generate a first sleep identifier of the sleep server, otherwise generate a second sleep identifier;

[0162] The dormant server corresponding to the second dormant identifier is selected as the server to be awakened.

[0163] In some embodiments, the energy-saving control device of the server in the cluster further includes a redundant control module (not shown in the figure), and the redundant control module is used to:

[0164] Obtaining the candidate number of the servers to be awakened, the standby number corresponding to the servers in the cluster in standby state, and the preset server redundancy number;

[0165] When the redundant number of servers is greater than the standby number, calculating a first difference between the redundant number of servers and the standby number;

[0166] When the first difference is less than or equal to the number of candidates, the second difference between the number of candidates and the first difference is calculated, and the servers corresponding to the number of the second difference are removed from the servers to be awakened; when the first difference is greater than the number of candidates, the third difference between the first difference and the number of candidates is calculated, and other servers corresponding to the number of the third difference are selected from the dormant servers and added to the servers to be awakened, or servers in idle state corresponding to the number of the third difference are selected from the cluster and switched to standby state.

[0167] The specific implementation of the energy-saving control device for servers in a cluster of this embodiment is basically the same as the specific implementation of the energy-saving control method for servers in a cluster described above, and will not be described in detail herein.

[0168] The present application also provides an electronic device, including:

[0169] at least one memory;

[0170] at least one processor;

[0171] at least one program;

[0172] The program is stored in the memory, and the processor executes the at least one program to implement the energy-saving control method of the server in the cluster implemented in the present application. The electronic device can be any intelligent terminal including a mobile phone, a tablet computer, a personal digital assistant (PDA), a car computer, etc.

[0173] See also Fig.11 , Fig.11 The hardware structure of an electronic device of another embodiment is illustrated, and the electronic device includes:

[0174] The processor 1101 may be implemented by a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application;

[0175] The memory 1102 can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 1102 can store an operating system and other application programs. When the technical solution provided in the embodiment of this specification is implemented by software or firmware, the relevant program code is stored in the memory 1102, and the processor 1101 calls and executes the energy-saving control method of the server in the cluster of the embodiment of the present application;

[0176] Input / output interface 1103, used to implement information input and output;

[0177] Communication interface 1104, used to realize communication interaction between the device and other devices, which can be realized by wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.); and

[0178] A bus 1105 that transmits information between various components of the device (e.g., the processor 1101, the memory 1102, the input / output interface 1103, and the communication interface 1104);

[0179] The processor 1101 , the memory 1102 , the input / output interface 1103 and the communication interface 1104 are connected to each other in communication within the device via the bus 1105 .

[0180] An embodiment of the present application further provides a storage medium, which is a storage medium storing a computer program. When the computer program is executed by a processor, the energy-saving control method for the server in the cluster is implemented.

[0181] As a non-transitory storage medium, the memory can be used to store non-transitory software programs and non-transitory computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transitory memory, such as at least one disk storage device, a flash memory device, or other non-transitory solid-state storage device. In some embodiments, the memory may optionally include a memory remotely arranged relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0182] The energy-saving control method, device, equipment and storage medium of the server in the cluster proposed in the embodiment of the present application use the equilibrium time as the standard for evaluating whether to end the dormant state, so as to determine under what circumstances waking up the dormant server can most effectively reduce energy consumption. Specifically, the equilibrium time corresponds to the energy consumption balance point of energy saving. When the total dormancy time of a dormant server has exceeded its equilibrium time, it indicates that the dormant energy consumption of the server is better than the standby energy consumption, that is, higher than the energy consumption balance point, so that energy saving effect has been produced. When the total dormancy time does not reach the equilibrium time, that is, it is lower than the energy consumption balance point, it means that the dormant server needs to continue to be in a dormant state for a period of time to reach the energy consumption balance point. At this time, if the server needs to be woken up, those servers whose total dormancy time is higher than the energy consumption balance point are woken up first to obtain better energy saving effect. This method can accurately select servers with the greatest potential energy saving value from the cluster to perform dormancy or wake-up operations, rather than making decisions based solely on whether the server is in an idle state. This method not only achieves more refined energy management, but also minimizes the impact on system processing performance, thereby improving the overall energy efficiency level.

[0183] The embodiments described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.

[0184] Those skilled in the art will appreciate that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.

[0185] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0186] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.

[0187] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0188] It should be understood that in this application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.

[0189] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the above units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0190] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0191] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0192] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including multiple instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store programs.

[0193] The preferred embodiments of the present invention are described above with reference to the accompanying drawings, but the scope of the rights of the present invention is not limited thereto. Any modification, equivalent substitution and improvement made by a person skilled in the art without departing from the scope and essence of the present invention should be within the scope of the rights of the present invention.

Claims

1. A method for energy saving control of a server in a cluster, characterized in that: include: Get the total sleep time of each dormant server in the cluster; Obtaining the balanced duration of each of the dormant servers, the balanced duration being the duration corresponding to when the total energy consumption value generated in the process of the servers in the cluster switching from the standby state to the dormant state and then recovering from the dormant state to the standby state is equal to the standby energy consumption value of maintaining the standby state; Selecting the dormant servers whose total dormancy duration is greater than or equal to the equilibrium duration as servers to be awakened, and controlling at least one of the servers to be awakened to exit the dormant state; The calculation process of the equalization duration includes the following steps: Acquire a first energy consumption value of the server when the server changes from a standby state to a dormant state, a second energy consumption value when the server maintains the dormant state, and a third energy consumption value when the server recovers from the dormant state to the standby state, wherein the representation of the second energy consumption value includes the balancing duration; Acquire the standby energy consumption value of the server maintaining the standby state, wherein the representation of the standby energy consumption value includes the equilibrium duration; Calculating the sum of the first energy consumption value, the second energy consumption value and the third energy consumption value as the total energy consumption value; When the total energy consumption value and the standby energy consumption value are the same, obtaining the equilibrium duration; Obtaining a first energy consumption value of the server when the server changes from a standby state to a dormant state, comprising: Obtaining a first conversion duration corresponding to a first conversion process of the server from a standby state to a dormant state and a first average power during the first conversion process; Calculating the product of the first conversion time and the first average power to obtain the first energy consumption value; Obtaining a third energy consumption value when the server is restored from a dormant state to a standby state includes: Acquire a second conversion duration corresponding to a second conversion process of the server recovering from a dormant state to a standby state and a second average power in the second conversion process; Calculating the product of the second conversion time and the second average power to obtain the third energy consumption value; Obtaining a second energy consumption value of the server maintained in a dormant state, comprising: Obtaining the sleep power of the server in a sleep state; Setting the balance time minus the first conversion time and the second conversion time as the sleep time; The product of the sleep time and the sleep power is calculated to obtain the second energy consumption value.

2. The energy-saving control method for servers in a cluster according to claim 1, characterized in that: The step of selecting the dormant server whose total dormancy duration is greater than or equal to the equilibrium duration as the server to be awakened includes: Identify in real time the relationship between the total sleep duration and the balanced duration of each sleep server, and when the total sleep duration is less than the balanced duration, generate a first sleep identifier of the sleep server, otherwise generate a second sleep identifier; The dormant server corresponding to the second dormant identifier is selected as the server to be awakened.

3. The energy-saving control method for servers in a cluster according to claim 1, characterized in that: After selecting the dormant server whose total dormancy duration is greater than or equal to the equilibrium duration as the server to be awakened, the method further includes: Obtaining the candidate number of the servers to be awakened, the standby number corresponding to the servers in the cluster in standby state, and the preset server redundancy number; When the redundant number of servers is greater than the standby number, calculating a first difference between the redundant number of servers and the standby number; When the first difference is less than or equal to the number of candidates, the second difference between the number of candidates and the first difference is calculated, and the servers corresponding to the number of the second difference are removed from the servers to be awakened; when the first difference is greater than the number of candidates, the third difference between the first difference and the number of candidates is calculated, and other servers corresponding to the number of the third difference are selected from the dormant servers and added to the servers to be awakened, or servers in idle state corresponding to the number of the third difference are selected from the cluster and switched to standby state.

4. An energy-saving control device for a server in a cluster, characterized in that: include: Total sleep time acquisition module: used to obtain the total sleep time of each dormant server in the cluster; Balanced duration acquisition module: used to obtain the balanced duration of each of the dormant servers, the balanced duration being the duration corresponding to the time when the total energy consumption value generated in the process of the servers in the cluster switching from the standby state to the dormant state and then recovering from the dormant state to the standby state is equal to the standby energy consumption value of maintaining the standby state; A wake-up selection module: used for selecting the dormant servers whose total dormancy duration is greater than or equal to the equilibrium duration as servers to be awakened, and controlling at least one of the servers to be awakened to exit the dormant state; The calculation process of the equalization duration includes the following steps: Acquire a first energy consumption value of the server when the server changes from a standby state to a dormant state, a second energy consumption value when the server maintains the dormant state, and a third energy consumption value when the server recovers from the dormant state to the standby state, wherein the representation of the second energy consumption value includes the balancing duration; Acquire the standby energy consumption value of the server maintaining the standby state, wherein the representation of the standby energy consumption value includes the equilibrium duration; Calculating the sum of the first energy consumption value, the second energy consumption value and the third energy consumption value as the total energy consumption value; When the total energy consumption value and the standby energy consumption value are the same, obtaining the equilibrium duration; The calculation process of the equalization duration includes the following steps: Acquire a first energy consumption value of the server when the server changes from a standby state to a dormant state, a second energy consumption value when the server maintains the dormant state, and a third energy consumption value when the server recovers from the dormant state to the standby state, wherein the representation of the second energy consumption value includes the balancing duration; Acquire the standby energy consumption value of the server maintaining the standby state, wherein the representation of the standby energy consumption value includes the equilibrium duration; Calculating the sum of the first energy consumption value, the second energy consumption value and the third energy consumption value as the total energy consumption value; When the total energy consumption value and the standby energy consumption value are the same, obtaining the equilibrium duration; Obtaining a first energy consumption value of the server when the server changes from a standby state to a dormant state, comprising: Obtaining a first conversion duration corresponding to a first conversion process of the server from a standby state to a dormant state and a first average power during the first conversion process; Calculating the product of the first conversion time and the first average power to obtain the first energy consumption value; Obtaining a third energy consumption value when the server is restored from a dormant state to a standby state includes: Acquire a second conversion duration corresponding to a second conversion process of the server recovering from a dormant state to a standby state and a second average power in the second conversion process; Calculating the product of the second conversion time and the second average power to obtain the third energy consumption value; Obtaining a second energy consumption value of the server maintained in a dormant state, comprising: Obtaining the sleep power of the server in a sleep state; Setting the balance time minus the first conversion time and the second conversion time as the sleep time; The product of the sleep time and the sleep power is calculated to obtain the second energy consumption value.

5. An electronic device, characterized in that: The electronic device includes a memory and a processor, the memory stores a computer program, and the processor implements the energy-saving control method for servers in a cluster as claimed in any one of claims 1 to 3 when executing the computer program.

6. A storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the energy-saving control method for a server in a cluster according to any one of claims 1 to 3 is implemented.

Citation Information

Patent Citations

  • Method and device for adjusting cluster nodes and electronic equipment

    CN118939433A