Method and device for dynamically adjusting output power of equipment
By introducing multiple sub-power modules into the power module of the data server and adjusting their status based on real-time and historical power data, the problem of resource waste in the low-consumption state of data center equipment is solved and efficient utilization of power resources is achieved.
Patent Information
- Application Number
- CN202110961948.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-08-20
- Publication Date
- 2024-10-25
- Estimated Expiration
- 2041-08-20
AI Technical Summary
Data center equipment is often in a low consumption state during actual operation, resulting in a serious waste of resources. The existing technology lacks effective dynamic adjustment methods to optimize power usage.
By introducing at least two sub-power modules into the power module of the data server, the working status of the sub-power modules is dynamically adjusted based on current real-time power and historical power data to ensure that only the required power modules are started to match the actual power demand.
It achieves dynamic adjustment of the output power of the device, avoids waste of resources, and saves the use of power resources.
Smart Images

Figure CN113821071B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a method and a device for dynamically adjusting output power of equipment. Background Art
[0002] With the rapid development of information technology, the scope of use of data centers is becoming increasingly wider, and the number of devices included in data centers is also increasing.
[0003] Typically, the equipment included in a data center is equipped with a power module to power the entire device. The device output power of the power module is the rated power. However, during the actual operation of the equipment, it is sometimes in a low-consumption state and does not always require such a large consumption as the rated power, which will cause a serious waste of resources.
[0004] Therefore, there is an urgent need for a method for dynamically adjusting the output power of a device to avoid serious waste of resources and to make rational use of resources. Summary of the invention
[0005] The embodiment of the present invention provides a method and a device for dynamically adjusting the output power of a device, so as to solve the problem of serious waste of resources existing in the prior art.
[0006] According to an embodiment of the present invention, a method for dynamically adjusting the output power of a device is provided, which is applied to a data server connected to at least one device, wherein the power supply module of the at least one device includes at least two sub-power supply modules, and the method includes:
[0007] After the current collection cycle expires, the current real-time power of the device to be adjusted in the current collection cycle and the historical real-time power of a set number of historical collection cycles before the current collection cycle are obtained;
[0008] Selecting the device output power from the current real-time power and the set number of historical real-time powers;
[0009] The working states of at least two sub-power modules included in the device to be adjusted are adjusted according to the output power of the device.
[0010] Specifically, obtaining the current real-time power of the device to be adjusted in the current collection period specifically includes:
[0011] Determine the current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle;
[0012] The current power consumption of each function is added together to obtain the current real-time power of the device to be adjusted in the current collection period.
[0013] Specifically, determining the current power consumption of each function implemented by the device to be adjusted in the current collection period specifically includes:
[0014] The current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle is:
[0015] Pnow(i)=(Nnow(i) / Nmax(i))(1+α)Pmax(i);
[0016] Among them, Pnow(i) is the current power consumption of each function, Nnow(i) is the actual usage granularity of each function, Nmax(i) is the maximum usage granularity of each function, Pmax(i) is the maximum power consumption of each function, and α is the weight of each function.
[0017] Specifically, selecting the device output power from the current real-time power and the set number of historical real-time powers specifically includes:
[0018] sorting the current real-time power and the set number of historical real-time powers;
[0019] Get the maximum value after sorting and obtain the device output power.
[0020] Specifically, adjusting the working states of at least two sub-power modules of the device to be adjusted according to the output power of the device specifically includes:
[0021] Divide the output power of the device by the rated power of the at least two sub-power modules and take the smallest integer to obtain the required quantity;
[0022] Selecting the required number of sub-power modules from the at least two sub-power modules;
[0023] The required number of sub-power modules are started, and the sub-power modules other than the required number of sub-power modules among the at least two sub-power modules are shut down.
[0024] According to an embodiment of the present invention, there is also provided a device for dynamically adjusting the output power of a device, which is applied to a data server connected to at least one device, wherein the power supply module of the at least one device includes at least two sub-power supply modules, and the device includes:
[0025] An acquisition module, used for acquiring, after the current acquisition cycle expires, the current real-time power of the device to be adjusted in the current acquisition cycle and the historical real-time power of a set number of historical acquisition cycles before the current acquisition cycle;
[0026] A selection module, used to select the device output power from the current real-time power and the set number of historical real-time powers;
[0027] The adjustment module is used to adjust the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device.
[0028] Specifically, the acquisition module is used to acquire the current real-time power of the device to be adjusted in the current acquisition period, specifically for:
[0029] Determine the current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle;
[0030] The current power consumption of each function is added together to obtain the current real-time power of the device to be adjusted in the current collection period.
[0031] Specifically, the acquisition module is used to determine the current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle, specifically for:
[0032] The current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle is:
[0033] Pnow(i)=(Nnow(i) / Nmax(i))(1+α)Pmax(i);
[0034] Among them, Pnow(i) is the current power consumption of each function, Nnow(i) is the actual usage granularity of each function, Nmax(i) is the maximum usage granularity of each function, Pmax(i) is the maximum power consumption of each function, and α is the weight of each function.
[0035] Specifically, the selection module is used to select the device output power from the current real-time power and the set number of historical real-time powers, specifically for:
[0036] sorting the current real-time power and the set number of historical real-time powers;
[0037] Get the maximum value after sorting and obtain the device output power.
[0038] Specifically, the adjustment module is used to adjust the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device, and is specifically used to:
[0039] Divide the output power of the device by the rated power of the at least two sub-power modules and take the smallest integer to obtain the required quantity;
[0040] Selecting the required number of sub-power modules from the at least two sub-power modules;
[0041] The required number of sub-power modules are started, and the sub-power modules other than the required number of sub-power modules among the at least two sub-power modules are shut down.
[0042] According to an embodiment of the present invention, there is also provided an electronic device, the electronic device comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;
[0043] Memory, used to store computer programs;
[0044] The processor is used to implement the above method steps when executing the program stored in the memory.
[0045] According to an embodiment of the present invention, a computer-readable storage medium is further provided, wherein the computer-readable storage medium stores a computer program, and the computer program implements the above method steps when executed by a processor.
[0046] The beneficial effects of the present invention are as follows:
[0047] The embodiment of the present invention provides a method and device for dynamically adjusting the output power of a device. After the current collection cycle expires, the current real-time power of the device to be adjusted in the current collection cycle and the historical real-time power of a set number of historical collection cycles before the current collection cycle are obtained; the device output power is selected from the current real-time power and the set number of historical real-time powers; and the working states of at least two sub-power modules included in the device to be adjusted are adjusted according to the device output power. In this solution, the real-time power of the device can be determined according to the current real-time power and the set number of historical real-time powers, and then the working states of at least two sub-power modules included in the device to be adjusted are adjusted, thereby realizing dynamic adjustment of the output power of the device, avoiding the problem of serious waste of resources in the prior art, and saving resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 This is a flow chart of a method for dynamically adjusting output power of a device in an embodiment of the present invention;
[0049] Figure 2 It is a structural schematic diagram of a device for dynamically adjusting output power of a device in an embodiment of the present invention;
[0050] Figure 3 This is a schematic diagram of the structure of an electronic device shown in this application. DETAILED DESCRIPTION
[0051] In view of the serious waste of resources in the prior art, an embodiment of the present invention provides a method for dynamically adjusting the output power of a device, which is applied to a data server connected to at least one device, wherein the power module of at least one device includes at least two sub-power modules. The process of the method is as follows: Figure 1 As shown, the execution steps are as follows:
[0052] S11: After the current collection cycle expires, the current real-time power of the device to be adjusted in the current collection cycle and the historical real-time power of a set number of historical collection cycles before the current collection cycle are obtained.
[0053] At least one device connected to the data server can be used as a device to be adjusted. At least one device can be a terminal, a network device, etc. The collection period can be set in advance, and the size of the collection period can be set according to actual needs, for example, set to 1 second, 2 seconds, 5 seconds, etc.
[0054] The device to be adjusted will have real-time power in each collection cycle. The real-time power of the current collection cycle can be defined as the current real-time power, and the real-time power of the historical collection cycle can be defined as the historical real-time power. The current real-time power and the historical real-time power of a set number of historical collection cycles can be obtained. The set number can be set according to actual needs, for example, it can be set to 10, 15, 20, etc.
[0055] S12: Select the device output power from the current real-time power and a set number of historical real-time powers.
[0056] The device output power is the output power that the device to be adjusted will adjust.
[0057] S13: Adjusting the working states of at least two sub-power modules included in the device to be adjusted according to the device output power.
[0058] Since the power module of the device to be adjusted includes at least two sub-power modules, it is necessary to adjust the working states of the at least two sub-power modules to adjust the device output power of the device to be adjusted.
[0059] In this scheme, the real-time power of the device can be determined based on the current real-time power and a set number of historical real-time powers, and then the working states of at least two sub-power modules included in the device to be adjusted can be adjusted, thereby dynamically adjusting the output power of the device, avoiding the problem of serious waste of resources in the prior art and saving resources.
[0060] Specifically, the process of obtaining the current real-time power of the device to be adjusted in the current collection period in S11 includes:
[0061] Determine the current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle;
[0062] The current power consumption of each function is added together to obtain the current real-time power of the device to be adjusted in the current collection period.
[0063] The device to be adjusted usually implements multiple functions. For example, for a network device, multiple functions such as route lookup, bidirectional forwarding detection (BFD) session, etc. can be implemented. Therefore, when obtaining the current real-time power of the device to be adjusted in the current collection period, the current power consumption of each function implemented by the device to be adjusted in the current collection period can be first determined, and then the current power consumption of each function is added to obtain the current real-time power of the device to be adjusted in the current collection period.
[0064] Specifically, the above determination of the current power consumption of each function implemented by the device to be adjusted in the current collection cycle specifically includes:
[0065] The current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle is:
[0066] Pnow(i)=(Nnow(i) / Nmax(i))(1+α)Pmax(i);
[0067] Among them, Pnow(i) is the current power consumption of each function, Nnow(i) is the actual usage granularity of each function, Nmax(i) is the maximum usage granularity of each function, Pmax(i) is the maximum power consumption of each function, and α is the weight of each function.
[0068] Continuing with the above example, assuming that the function is route lookup, the actual usage granularity and the maximum usage granularity are the number of routes actually used and the maximum number of routes used respectively; assuming that the function is BFD session, the actual usage granularity and the maximum usage granularity are the number of BFD sessions actually used and the maximum number of BFD sessions used respectively.
[0069] The weight of each function may be set to a value less than 1 according to actual needs or the importance level of the function.
[0070] Specifically, the process of selecting the device output power from the current real-time power and the set number of historical real-time powers in S12 includes:
[0071] Sort the current real-time power and the set number of historical real-time powers;
[0072] Get the maximum value after sorting and obtain the device output power.
[0073] When selecting the device output power from the current real-time power and the set number of historical real-time powers, there are many ways to implement it. For example, the current real-time power and the set number of historical real-time powers can be sorted, and the maximum value after sorting is obtained to obtain the device output power. This is just one implementation method. Of course, there are many other implementation methods, which will not be described here one by one.
[0074] Specifically, the above S13 adjusts the working states of at least two sub-power modules included in the device to be adjusted according to the device output power, and the implementation process specifically includes:
[0075] Divide the output power of the device by the rated power of at least two sub-power modules and take the smallest integer to obtain the required quantity;
[0076] Selecting a required number of sub-power modules from at least two sub-power modules;
[0077] A required number of sub-power modules are started, and sub-power modules other than the required number of sub-power modules among at least two sub-power modules are shut down.
[0078] Since the power module of the device to be adjusted includes at least two sub-power modules, when adjusting the working states of the at least two sub-power modules included in the device to be adjusted according to the device output power, since the rated powers of the at least two sub-power modules are also the same, the device output power can be first divided by the rated powers of the at least two sub-power modules and the minimum integer is taken to obtain the required number, which is the number of sub-power modules required; then the required number of sub-power modules are selected from the at least two sub-power modules, specifically by random selection or sequential selection, etc.; finally, the required number of sub-power modules are started, and the sub-power modules other than the required number of sub-power modules in the at least two sub-power modules are turned off, so that real-time adjustment of the output power of the device to be adjusted can be achieved.
[0079] Based on the same inventive concept, an embodiment of the present invention provides a device for dynamically adjusting the output power of a device, which is applied to a data server connected to at least one device, wherein the power module of at least one device includes at least two sub-power modules. The structure of the device is as follows: Figure 2 As shown, including:
[0080] The acquisition module 21 is used to acquire the current real-time power of the device to be adjusted in the current acquisition cycle and the historical real-time power of a set number of historical acquisition cycles before the current acquisition cycle after the current acquisition cycle expires;
[0081] A selection module 22, used to select the device output power from the current real-time power and a set number of historical real-time powers;
[0082] The adjustment module 23 is used to adjust the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device.
[0083] In this scheme, the real-time power of the device can be determined based on the current real-time power and a set number of historical real-time powers, and then the working states of at least two sub-power modules included in the device to be adjusted can be adjusted, thereby dynamically adjusting the output power of the device, avoiding the problem of serious waste of resources in the prior art and saving resources.
[0084] Specifically, the acquisition module 21 is used to obtain the current real-time power of the device to be adjusted in the current acquisition cycle, specifically for:
[0085] Determine the current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle;
[0086] The current power consumption of each function is added together to obtain the current real-time power of the device to be adjusted in the current collection period.
[0087] Specifically, the acquisition module 21 is used to determine the current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle, specifically for:
[0088] The current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle is:
[0089] Pnow(i)=(Nnow(i) / Nmax(i))(1+α)Pmax(i);
[0090] Among them, Pnow(i) is the current power consumption of each function, Nnow(i) is the actual usage granularity of each function, Nmax(i) is the maximum usage granularity of each function, Pmax(i) is the maximum power consumption of each function, and α is the weight of each function.
[0091] Specifically, the selection module 22 is used to select the device output power from the current real-time power and a set number of historical real-time powers, specifically for:
[0092] Sort the current real-time power and the set number of historical real-time powers;
[0093] Get the maximum value after sorting and obtain the device output power.
[0094] Specifically, the adjustment module 23 is used to adjust the working states of at least two sub-power modules included in the device to be adjusted according to the device output power, specifically for:
[0095] Divide the output power of the device by the rated power of at least two sub-power modules and take the smallest integer to obtain the required quantity;
[0096] Selecting a required number of sub-power modules from at least two sub-power modules;
[0097] A required number of sub-power modules are started, and sub-power modules other than the required number of sub-power modules among at least two sub-power modules are shut down.
[0098] The present application also provides an electronic device. Figure 3 As shown, it includes a processor 310 , a communication interface 320 , a memory 330 and a communication bus 340 , wherein the processor 310 , the communication interface 320 , and the memory 330 communicate with each other via the communication bus 340 .
[0099] Memory 330, for storing computer programs;
[0100] The processor 310 is used to implement the method for dynamically adjusting the output power of the device described in any of the above embodiments when executing the program stored in the memory 330.
[0101] The communication interface 320 is used for communication between the above electronic device and other devices.
[0102] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
[0103] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0104] In this scheme, the real-time power of the device can be determined based on the current real-time power and a set number of historical real-time powers, and then the working states of at least two sub-power modules included in the device to be adjusted can be adjusted, thereby dynamically adjusting the output power of the device, avoiding the problem of serious waste of resources in the prior art and saving resources.
[0105] Accordingly, an embodiment of the present application further provides a computer-readable storage medium, which stores instructions. When the computer-readable storage medium is executed on a computer, the computer executes the method for dynamically adjusting the output power of a device as described in any of the above embodiments.
[0106] In this scheme, the real-time power of the device can be determined based on the current real-time power and a set number of historical real-time powers, and then the working states of at least two sub-power modules included in the device to be adjusted can be adjusted, thereby dynamically adjusting the output power of the device, avoiding the problem of serious waste of resources in the prior art and saving resources.
[0107] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0108] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0109] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0110] Although the optional embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the optional embodiments and all changes and modifications that fall within the scope of the present invention.
[0111] Obviously, those skilled in the art can make various changes and modifications to the embodiments of the present invention without departing from the spirit and scope of the embodiments of the present invention. Thus, if these modifications and variations of the embodiments of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A method for dynamically adjusting device output power, applied to a data server connected to at least one device, characterized in that: The power supply module of the at least one device includes at least two sub-power supply modules, and the method includes: After the current collection cycle expires, the current real-time power of the device to be adjusted in the current collection cycle and the historical real-time power of a set number of historical collection cycles before the current collection cycle are obtained; Selecting the device output power from the current real-time power and the set number of historical real-time powers; Adjusting the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device specifically includes: determining the required number according to the output power of the device and the rated power of the at least two sub-power modules, and selecting the required number of sub-power modules from the at least two sub-power modules; starting the required number of sub-power modules, and shutting down the sub-power modules except the required number of sub-power modules among the at least two sub-power modules.
2. The method according to claim 1, characterized in that Obtaining the current real-time power of the device to be adjusted in the current acquisition cycle specifically includes: Determine the current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle; The current power consumption of each function is added together to obtain the current real-time power of the device to be adjusted in the current collection period.
3. The method according to claim 2, characterized in that Determining the current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle, specifically including: The current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle is: P now (i)=(N now (i) / N max (i))(1+α)P max (i); Among them, P now (i) is the current power consumption of each power, N now (i) is the actual usage granularity of each function, N max (i) is the maximum usage granularity of each function, P max (i) is the maximum power consumption of each function, and α is the weight of each function.
4. The method according to claim 1, characterized in that Selecting the device output power from the current real-time power and the set number of historical real-time powers specifically includes: sorting the current real-time power and the set number of historical real-time powers; Get the maximum value after sorting and obtain the device output power.
5. The method according to any one of claims 1 to 4, characterized in that: Adjusting the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device specifically includes: Divide the output power of the device by the rated power of the at least two sub-power modules and take the smallest integer to obtain the required quantity; Selecting the required number of sub-power modules from the at least two sub-power modules; The required number of sub-power modules are started, and the sub-power modules other than the required number of sub-power modules among the at least two sub-power modules are shut down.
6. A device for dynamically adjusting output power of a device, applied to a data server connected to at least one device, characterized in that: The power supply module of at least one device includes at least two sub-power supply modules, and the device includes: An acquisition module, used for acquiring, after the current acquisition cycle expires, the current real-time power of the device to be adjusted in the current acquisition cycle and the historical real-time power of a set number of historical acquisition cycles before the current acquisition cycle; A selection module, used to select the device output power from the current real-time power and the set number of historical real-time powers; An adjustment module is used to adjust the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device, and is specifically used to: determine the required number according to the output power of the device and the rated power of the at least two sub-power modules, and select the required number of sub-power modules from at least two sub-power modules; start the required number of sub-power modules, and shut down the sub-power modules of the at least two sub-power modules except the required number of sub-power modules.
7. The device according to claim 6, characterized in that The acquisition module is used to acquire the current real-time power of the device to be adjusted in the current acquisition period, specifically for: Determine the current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle; The current power consumption of each function is added together to obtain the current real-time power of the device to be adjusted in the current collection period.
8. The device according to claim 7, characterized in that The acquisition module is used to determine the current power consumption of each function implemented by the device to be adjusted in the current acquisition cycle, specifically for: The current power consumption of each function implemented by the device to be adjusted during the current acquisition cycle is: P now (i)=(N now (i) / N max (i))(1+α)P max (i); Among them, P now (i) is the current power consumption of each power, N now (i) is the actual usage granularity of each function, N max (i) is the maximum usage granularity of each function, P max (i) is the maximum power consumption of each function, and α is the weight of each function.
9. The device according to claim 6, characterized in that The selection module is used to select the device output power from the current real-time power and the set number of historical real-time powers, and is specifically used to: sorting the current real-time power and the set number of historical real-time powers; Get the maximum value after sorting and obtain the device output power.
10. The device according to any one of claims 6 to 9, characterized in that: The adjustment module is used to adjust the working states of at least two sub-power modules included in the device to be adjusted according to the output power of the device, and is specifically used to: Divide the output power of the device by the rated power of the at least two sub-power modules and take the smallest integer to obtain the required quantity; Selecting the required number of sub-power modules from the at least two sub-power modules; The required number of sub-power modules are started, and the sub-power modules other than the required number of sub-power modules among the at least two sub-power modules are shut down.
11. An electronic device, characterized in that: The electronic device comprises a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; Memory, used to store computer programs; A processor, for implementing the method steps described in any one of claims 1 to 5 when executing a program stored in a memory.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps described in any one of claims 1 to 5 are implemented.
