IP Library › Granted Patent US 11,194,623
Granted Patent B2
US 11,194,623 · App. 16/558,983 · Granted Dec 7, 2021

Resource scheduling method and related apparatus

Inventors: Jia Li (Xi'an, CN); Jie Liu (Xi'an, CN); Lifei Dang (Xi'an, CN); Lingzhi Mao (Shenzhen, CN)
Assignee: HUAWEI TECHNOLOGIES CO., LTD.
G06F9/4881G06F3/061G06F3/0659G06F3/0674G06F9/3855G06F9/546G06F12/08G06F12/0871G06F12/123
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,194,623
App. No.
16/558,983
Granted
Dec 7, 2021
Kind
B2
Abstract

A resource scheduling method and a related resource scheduling apparatus to improve data input/output (I/O) efficiency, where the method includes determining a current task queue, where the current task queue includes a plurality of to-be-executed application tasks, determining, for data blocks on a disk to be accessed by the application tasks, a quantity of times that each data block is to be accessed by the application tasks, determining a hotspot data block according to the quantity of times that each data block is to be accessed by the application tasks, and sending a move-in instruction to a local node of the hotspot data block, where the move-in instruction instructs to move the hotspot data block into a memory such that the hotspot data block can be accessed in the memory.

Claims (64)

1. A resource scheduling method for a resource scheduling apparatus in a storage system in which data is grouped into a plurality of data blocks and each data block is stored on a corresponding local node, comprising:

accessing a task queue in the resource scheduling apparatus, wherein the task queue comprises a plurality of to-be-executed application tasks;

determining, for data blocks to be accessed by the plurality of to-be-executed application tasks, a quantity of times that each data block is to be accessed by the plurality of to-be-executed application tasks;

determining a hotspot data block according to the quantity of times that each data block is to be accessed by the plurality of to-be-executed application tasks rather than according to a frequency in which each data block was accessed;

sending a move-in instruction to a local node of the hotspot data block, wherein the move-in instruction instructs moving the hotspot data block from a local storage device of the local node into a memory of the local node, and wherein an input/output (I/O) rate of the memory is faster than an I/O rate of the local storage device;

determining a current task queue in the resource scheduling apparatus;

receiving an instruction for executing a to-be-executed job delivered by a client within a preset time period;

dividing the to-be-executed job into the plurality of to-be-executed application tasks; and

determining the plurality of to-be-executed application tasks as the current task queue.

2. The resource scheduling method according to claim 1 , wherein determining the hotspot data block comprises determining, as hotspot data blocks, top M data blocks to be accessed by the plurality of to-be-executed application tasks most frequently, and wherein M is a preset value.

3. The resource scheduling method according to claim 1 , wherein determining the hotspot data block comprises determining, as the hotspot data block, a data block to be accessed by the plurality of to-be-executed application tasks for at least N times, and wherein N is a preset value.

4. The resource scheduling method according to claim 1 , further comprising scheduling an application task of the plurality of to-be-executed application tasks corresponding to the hotspot data block to the local node of the hotspot data block when the local node of the hotspot data block comprises a current vacant slot such that the application task does not access the hotspot data block across another node.

5. The resource scheduling method according to claim 1 , further comprising sequentially executing, in descending order of quantities of times that all hotspot data blocks are to be accessed by the plurality of to-be-executed application tasks, application tasks of the plurality of to-be-executed application tasks corresponding to all of the hotspot data blocks.

6. The resource scheduling method according to claim 1 , further comprising:

determining a quantity of hotspot data blocks to be accessed by each application task; and

sequentially executing the plurality of to-be-executed application tasks in descending order of the quantity of the hotspot data blocks to be accessed by the plurality of to-be-executed application tasks after sending the move-in instruction to the local node of the hotspot data block.

7. The resource scheduling method according to claim 1 , further comprising:

determining a quantity of times that each data block in the memory is to be accessed by the plurality of to-be-executed application tasks;

determining, as non-hotspot data blocks, top P data blocks in the memory to be accessed by the plurality of to-be-executed application tasks least frequently, wherein P is a preset value; and

sending a move-out instruction to a local node of the non-hotspot data block, wherein the move-out instruction instructs moving the non-hotspot data block out of the memory.

8. The resource scheduling method according to claim 1 , further comprising:

determining a quantity of times that each data block in the memory is to be accessed by the plurality of to-be-executed application tasks;

determining, as a non-hotspot data block, a data block in the memory to be accessed by the plurality of to-be-executed application tasks for a maximum of Q times, wherein Q is a preset value; and

sending a move-out instruction to a local node of the non-hotspot data block, wherein the move-out instruction instructs moving the non-hotspot data block out of the memory.

9. A resource scheduling apparatus, comprising:

an input apparatus;

an output apparatus coupled to the input apparatus;

a processor coupled to the input apparatus and the output apparatus; and

a memory comprising instructions and coupled to the input apparatus, the output apparatus, and the processor, wherein the instructions cause the processor to be configured to:

access a task queue comprising a plurality of to-be-executed application tasks;

determine, for data blocks to be accessed by the plurality of to-be-executed application tasks, a quantity of times that each data block is to be accessed by the plurality of to-be-executed application tasks;

determine a hotspot data block according to the quantity of times that each data block is to be accessed by the plurality of to-be-executed application tasks rather than according to a frequency in which each data block was accessed;

send a move-in instruction to a local node of the hotspot data block, wherein the move-in instruction instructs moving the hotspot data block from a storage device of the local node into a local memory of the local node, and wherein an input/output (I/O) rate of the local memory is faster than an I/O rate of the storage device;

receive an instruction for executing a to-be-executed job delivered by a client within a preset time period;

divide the to-be-executed job into the plurality of to-be-executed application tasks; and

determine the plurality of to-be-executed application tasks as a current task queue in the resource scheduling apparatus.

10. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to determine, as hotspot data blocks, top M data blocks to be accessed by the plurality of to-be-executed application tasks most frequently, and wherein M is a preset value.

11. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to determine, as the hotspot data block, a data block to be accessed by the plurality of to-be-executed application tasks for at least N times, and wherein N is a preset value.

12. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to schedule an application task of the plurality of to-be-executed application tasks corresponding to the hotspot data block to the local node of the hotspot data block when the local node of the hotspot data block comprises a current vacant slot.

13. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to sequentially execute, in descending order of quantities of times that all hotspot data blocks are to be accessed by the plurality of to-be-executed application tasks, application tasks of the plurality of to-be-executed application tasks corresponding to all the hotspot data blocks.

14. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to:

determine a quantity of hotspot data blocks to be accessed by each application task; and

sequentially execute the plurality of to-be-executed application tasks in descending order of the quantity of the hotspot data blocks to be accessed by the plurality of to-be-executed application tasks.

15. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to:

determine a quantity of times that each data block in the local memory is to be accessed by the plurality of to-be-executed application tasks;

determine, as non-hotspot data blocks, top P data blocks in the local memory to be accessed by the plurality of to-be-executed application tasks least frequently, wherein P is a preset value; and

send a move-out instruction to a local node of the non-hotspot data block, wherein the move-out instruction instructs moving the non-hotspot data block out of the local memory.

16. The resource scheduling apparatus according to claim 9 , wherein the instructions further cause the processor to be configured to:

determine a quantity of times that each data block in the local memory is to be accessed by the plurality of to-be-executed application tasks;

determine, as a non-hotspot data block, a data block in the local memory and to be accessed by the plurality of to-be-executed application tasks for a maximum of Q times, wherein Q is a preset value; and

send a move-out instruction to a local node of the non-hotspot data block, wherein the move-out instruction instructs moving the non-hotspot data block out of the local memory.

17. A non-transitory computer-readable storage medium comprising instructions that, when executed by a computer of a resource scheduling apparatus, cause the computer to implement a method comprising:

accessing a task queue in the resource scheduling apparatus, wherein the task queue comprises a plurality of to-be-executed application tasks;

determining, for data blocks to be accessed by the plurality of to-be-executed application tasks, a quantity of times that each data block is to be accessed by the plurality of to-be-executed application tasks;

determining a hotspot data block according to the quantity of times that each data block is to be accessed by the plurality of to-be-executed application tasks rather than according to a frequency in which each data block was accessed;

sending a move-in instruction to a local node of the hotspot data block, wherein the move-in instruction instructs moving the hotspot data block from a storage device of the local node into a memory of the local node, and wherein an input/output (I/O) rate of the memory is faster than an I/O rate of the storage device;

determining a current task queue in the resource scheduling apparatus;

receiving an instruction for executing a to-be-executed job delivered by a client within a preset time period;

dividing the to-be-executed job into the plurality of to-be-executed application tasks; and

determining the plurality of to-be-executed application tasks as the current task queue.

18. The non-transitory computer-readable storage medium according to claim 17 , wherein determining the hotspot data block comprises determining, as hotspot data blocks, top M data blocks to be accessed by the plurality of to-be-executed application tasks most frequently, and wherein M is a preset value.

19. The non-transitory computer-readable storage medium according to claim 17 , wherein the method further comprises:

determining, as a non-hotspot data block, a data block in the memory to be accessed by the plurality of to-be-executed application tasks for a preset maximum number of times; and

sending a move-out instruction to a local node of the non-hotspot data block, wherein the move-out instruction instructs moving the non-hotspot data block.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Mar 1, 2022
From: HUAWEI TECHNOLOGIES CO., LTD.
To: HUAWEI CLOUD COMPUTING TECHNOLOGIES CO., LTD.
Reel/Frame 059267/0088 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 28, 2020
From: LI, JIA; LIU, JIE; DANG, LIFEI; MAO, LINGZHI
To: HUAWEI TECHNOLOGIES CO., LTD.
Reel/Frame 054752/0907 →
Continuity (3)
Continuation 15584661 · May 2, 2017
Continuation PCTCN2014094581 · Dec 23, 2014
Related Publication 20190391847A1 · Dec 26, 2019