IP Library › Granted Patent US 10,642,822
Granted Patent B2
US 10,642,822 · App. 15/639,675 · Granted May 5, 2020

Resource coordination method, apparatus, and system for database cluster

Inventors: Yulei Xiao (Shenzhen, CN); Tao Ye (Beijing, CN)
Assignee: HUAWEI TECHNOLOGIES CO., LTD.
G06F16/2365G06F3/06G06F11/2043G06F11/3006G06F11/3433G06F16/2358G06F16/27G06F2201/81G06F2201/885
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 10,642,822
App. No.
15/639,675
Granted
May 5, 2020
Kind
B2
Abstract

A resource coordination method, an apparatus, and a system for a database cluster, which include an active coordinator node obtains status information corresponding to each processing node in multiple processing nodes, where the status information is used to indicate an operating load status of the processing node, determines, according to the status information corresponding to each processing node in multiple processing nodes, whether the active coordinator node has an idle resource whose capacity is a preset threshold X, and if the active coordinator node has the idle resource whose capacity is the preset threshold X, instructs each processing node to upload subsequently generated clean page data to the active coordinator node.

Claims (66)

1. A resource coordination method for a database cluster, wherein the database cluster comprises a plurality of processing nodes and an active coordinator node, the method comprising:

obtaining status information corresponding to each processing node, wherein the status information is used to indicate an operating load status of the processing node;

determining, according to the status information, when the active coordinator node has an idle resource whose capacity is a preset threshold X; and either

instructing each processing node to upload subsequently generated clean page data to the active coordinator node; or

determining, according to the status information corresponding to each processing node in the plurality of processing nodes, when each processing node is to upload dirty page data whose data volume is less than the preset threshold X within a preset time period, and when each processing node is to upload the dirty page data whose data volume is less than the preset threshold X within the preset time period, instructing each processing node to upload subsequently generated clean page data to the active coordinator node.

2. The method according to claim 1 , wherein after instructing each processing node to upload subsequently generated clean page data to the active coordinator node, the method further comprises:

monitoring the idle resource of the active coordinator node in real time; and

instructing, when the capacity of the idle resource of the active coordinator node is less than a preset threshold Z, each processing node not to upload the generated clean page data to the active coordinator node any more, wherein Z is less than X.

3. The method according to claim 2 , wherein after instructing each processing node not to upload the generated clean page data to the active coordinator node any more, the method further comprises removing the clean page data cached on the active coordinator node when the active coordinator node receives newly generated dirty page data.

4. The method according to claim 2 , wherein after instructing each processing node not to upload the generated clean page data to the active coordinator node any more, wherein the active coordinator node receives newly generated dirty page data, and wherein a data volume of the newly generated dirty page data is greater than a data volume of the clean page data cached on the active coordinator node, the method further comprises:

removing the clean page data cached on the active coordinator node; and

storing the newly generated dirty page data in a storage device of the database cluster.

5. The method according to claim 1 , wherein after determining that each processing node in the multiple processing nodes is to upload the dirty page data whose data volume is less than the preset threshold X within the preset time period, the method further comprises generating a cache policy of the active coordinator node according to the status information corresponding to each processing node, wherein the cache policy of the active coordinator node comprises a policy for uploading clean page data by each processing node in the multiple processing nodes to the active coordinator node, and wherein instructing each processing node to upload subsequently generated clean page data to the active coordinator node comprises instructing each processing node to upload the subsequently generated clean page data to the active coordinator node according to the cache policy of the active coordinator node.

6. The method according to claim 5 , wherein generating the cache policy of the active coordinator node comprises:

calculating, according to the status information corresponding to each processing node, a proportion of dirty page data generated by each processing node in a current unit of time; and

generating the cache policy of the active coordinator node according to the proportion of the dirty page data generated by each processing node in the current unit of time.

7. An active coordinator node for a database cluster, comprising:

a high-speed network channel configured to communicate with a plurality of processing nodes in the database cluster; and

a processor coupled to the high-speed network channel, the processor configured to:

obtain status information corresponding to each processing node in a plurality of processing nodes, wherein the status information is used to indicate an operating load status of the processing node;

determine, according to the status information corresponding to each processing node, when the active coordinator node has an idle resource whose capacity is a preset threshold X;

determine, according to the status information corresponding to each processing node, when each processing node is to upload dirty page data whose data volume is less than the preset threshold X within a preset time period when the active coordinator node has the idle resource whose capacity is the preset threshold X; and

instruct each processing node to upload subsequently generated clean page data to the active coordinator node when a determining result of the first determining module is that the active coordinator node has the idle resource whose capacity is the preset threshold X.

8. The active coordinator node according to claim 7 , wherein the processor is further configured to:

monitor the idle resource of the active coordinator node in real time; and

instruct, when the capacity of the idle resource of the active coordinator node is less than a preset threshold Z, each processing node not to upload the generated clean page data to the active coordinator node any more, wherein Z is less than X.

9. The active coordinator node according to claim 8 , wherein the processor is further configured to remove the clean page data cached on the active coordinator node after instructing each processing node not to upload the generated clean page data to the active coordinator node anymore and when the active coordinator node receives newly generated dirty page data.

10. The active coordinator node according to claim 8 , wherein the processor is further configured to, after the execution module instructs each processing node not to upload the generated clean page data to the active coordinator node any more, when the active coordinator node receives newly generated dirty page data, and when a data volume of the newly generated dirty page data is greater than a data volume of the clean page data cached on the active coordinator node,

remove the clean page data cached on the active coordinator node; and

store the newly generated dirty page data in a storage device of the database cluster.

11. The active coordinator node according to claim 7 , wherein after determining that each processing node is to upload dirty page data whose data volume is less than the preset threshold X within a preset time period when the active coordinator node has the idle resource whose capacity is the preset threshold X, the processor is further configured to:

generate a cache policy of the active coordinator node according to the status information corresponding to each processing node in the multiple processing nodes, wherein the cache policy of the active coordinator node comprises a policy for uploading clean page data by each processing node in the multiple processing nodes to the active coordinator node; and

instruct each processing node to upload subsequently generated clean page data to the active coordinator node according to the cache policy of the active coordinator node.

12. The active coordinator node according to claim 11 , wherein the processor is further configured to:

calculate, according to the status information corresponding to each processing node, a proportion of dirty page data generated by each processing node in a current unit of time; and

generate the cache policy of the active coordinator node according to the proportion of the dirty page data generated by each processing node in the current unit of time.

13. A database cluster, comprising:

a plurality of processing nodes;

an active coordinator node; and

a high-speed network channel coupling the active coordinator node with the plurality of processing nodes,

wherein the active coordinator node is configured to:

obtain status information corresponding to each processing node;

determine, according to the status information corresponding to each processing node, when the active coordinator node has an idle resource whose capacity is a preset threshold X;

instruct each processing node to upload subsequently generated clean page data to the active coordinator node; or

determine, according to the status information corresponding to each processing node in the multiple processing nodes, when each processing node in the multiple processing nodes is to upload dirty page data whose data volume is less than the preset threshold X within a preset time period, and, instruct each processing node to upload subsequently generated clean page data to the active coordinator node, wherein the status information is used to indicate an operating load status of the processing node, and wherein each processing node is configured to:

receive an instruction sent by the active coordinator node; and

upload the generated clean page data to the active coordinator node when any one of the processing nodes generates clean page data.

14. The database cluster according to claim 13 , wherein the active coordinator node is further configured to:

generate a cache policy of the active coordinator node according to the status information corresponding to each processing node; and

instruct each processing node to upload the subsequently generated clean page data to the active coordinator node according to the cache policy of the active coordinator node, and

wherein each processing node is further configured to:

receive the instruction sent by the active coordinator node; and

upload, when any one of the processing nodes generates clean page data, the generated clean page data to the active coordinator node according to the cache policy of the active coordinator node.

15. The database cluster according to claim 13 , wherein the database cluster further comprises a standby coordinator node, wherein in the standby coordinator node is configured to back up data for the active coordinator node so that content on the standby coordinator node is the same as content on the active coordinator node.

16. A resource coordination method for a database cluster, wherein the database cluster comprises a plurality of processing nodes and an active coordinator node, the method comprising:

obtaining status information corresponding to each processing node, wherein the status information is used to indicate an operating load status of the processing node; and

instructing, when the active coordinator node has the idle resource whose capacity is the preset threshold X, each processing node to upload subsequently generated clean page data to the active coordinator node; and

instructing, when each processing node in the multiple processing nodes is to upload the dirty page data whose data volume is less than the preset threshold X within the preset time period, each processing node to upload subsequently generated clean page data to the active coordinator node.

17. The method according to claim 16 , wherein after instructing each processing node to upload subsequently generated clean page data to the active coordinator node, the method further comprises:

monitoring the idle resource of the active coordinator node in real time; and

instructing, when the capacity of the idle resource of the active coordinator node is less than a preset threshold Z, each processing node not to upload the generated clean page data to the active coordinator node any more, wherein Z is less than X.

18. The method according to claim 17 , wherein after instructing each processing node not to upload the generated clean page data to the active coordinator node any more, the method further comprises removing, when the active coordinator node receives newly generated dirty page data, the clean page data cached on the active coordinator node.

19. The method according to claim 17 , wherein after instructing each processing node not to upload the generated clean page data to the active coordinator node any more, wherein when the active coordinator node receives newly generated dirty page data, and wherein when a data volume of the newly generated dirty page data is greater than a data volume of the clean page data cached on the active coordinator node, the method further comprises:

removing the clean page data cached on the active coordinator node and

storing the newly generated dirty page data in a storage device of the database cluster.

20. The method according to claim 16 , wherein after instructing each processing node to upload dirty page data, the method further comprises generating a cache policy of the active coordinator node according to the status information corresponding to each processing node, wherein the cache policy of the active coordinator node comprises a policy for uploading clean page data by each processing node to the active coordinator node, and wherein instructing each processing node to upload subsequently generated clean page data to the active coordinator node comprises instructing each processing node to upload the subsequently generated clean page data to the active coordinator node according to the cache policy of the active coordinator node.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 25, 2017
From: XIAO, YULEI; YE, TAO
To: HUAWEI TECHNOLOGIES CO., LTD.
Reel/Frame 043094/0101 →
Priority Claims (1)
CN 2015 1 0003943 · Jan 4, 2015 · national
Continuity (2)
Continuation PCTCN2016070052 · Jan 4, 2016
Related Publication 20170308567A1 · Oct 26, 2017
Cited By (1)
US 12,495,100