CN106354585B - The dispositions method and device of the more data fragmentation backups of data-base cluster - Google Patents
The dispositions method and device of the more data fragmentation backups of data-base cluster Download PDFInfo
- Publication number
- CN106354585B CN106354585B CN201610777563.0A CN201610777563A CN106354585B CN 106354585 B CN106354585 B CN 106354585B CN 201610777563 A CN201610777563 A CN 201610777563A CN 106354585 B CN106354585 B CN 106354585B
- Authority
- CN
- China
- Prior art keywords
- node
- data
- group
- reliability
- fragment
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1415—Saving, restoring, recovering or retrying at system level
Abstract
The present invention provides the dispositions method and device of a kind of more data fragmentation backups of data-base cluster, which comprises obtains the number of nodes in data-base cluster;Obtain the corresponding data fragmentation quantity of each node in data-base cluster;According to default rule configuration backup fragment;The reliability of the configuration backup fragment is calculated, chooses Optimal reliability as dispositions method.The deployment way of a variety of backup fragments is configured by scheduled rule, and choose the wherein highest configuration mode of reliability to carry out Optimal reliability deployment as deployment way, and big degree ensures the reliability of cluster.
Description
Technical field
The invention belongs to data-base cluster fields, more particularly, to a kind of deployment of the more data fragmentation backups of data-base cluster
Method and device.
Background technique
Data-base cluster constitutes a virtual centralized database and patrols using at least two or more database servers
It collects image and provides transparent data service to client as single database system.In database analysis application, data
Library cluster occupies main status, for the reliability for guaranteeing cluster, mostly uses backup fragment to back up data, each main fragment
Corresponding portion backup fragment, main fragment and backup fragment be not in the same back end.And it is multiple in a data node deployment
The data-base cluster of data fragmentation has a clear superiority in terms of scalability, but how its Backup Data fragment is distributed, and will affect
The reliability of entire cluster.
Summary of the invention
The embodiment of the invention provides the dispositions methods and device of a kind of more data fragmentation backups of data-base cluster, to solve
The technical issues of deployment will solve Backup Data fragment.
On the one hand, the embodiment of the invention provides a kind of dispositions methods of the more data fragmentation backups of data-base cluster, comprising:
Obtain the number of nodes in data-base cluster;
Obtain the corresponding data fragmentation quantity of each node in data-base cluster;
According to default rule configuration backup fragment;
The reliability of the configuration backup fragment is calculated, chooses Optimal reliability as dispositions method.
Further, the default rule, comprising:
The backup fragment of p data fragmentation of first node is successively placed in the p node that next node starts;Or
Person
The backup fragment of p data fragmentation of first node is all placed in next node;Or
If number of nodes m is the integral multiple and m > p+1 of p+1, back end is grouped as n group, every group has p+1 node,
The backup fragment of p data fragmentation of each node is successively placed in other p node of this group;Or
If m is the integral multiple and m > p of p.Back end is divided into n group, every group has p node, p data of each node
The backup fragment of fragment is successively placed in next group of p node;Or
If m is 2 integral multiple, back end is divided into m/2 group, every group of 2 nodes mutually deposit p backup fragment.
Further, the reliability for calculating the configuration backup fragment, comprising:
According to the reliability of configuration backup fragment described in the probability calculation of any two node failure.
On the other hand, the deployment device of the more data fragmentation backups of the data-base cluster, comprising:
Node acquiring unit, for obtaining the number of nodes in data-base cluster;
Data fragmentation number obtainment unit, for obtaining the corresponding data fragmentation quantity of each node in data-base cluster;
Configuration unit, for according to default rule configuration backup fragment;
Computing unit chooses Optimal reliability as dispositions method for calculating the reliability of the configuration backup fragment.
Further, the default rule, comprising:
The backup fragment of p data fragmentation of first node is successively placed in the p node that next node starts;Or
Person
The backup fragment of p data fragmentation of first node is all placed in next node;Or
If number of nodes m is the integral multiple and m > p+1 of p+1, back end is grouped as n group, every group has p+1 node,
The backup fragment of p data fragmentation of each node is successively placed in other p node of this group;Or
If m is the integral multiple and m > p of p.Back end is divided into n group, every group has p node, p data of each node
The backup fragment of fragment is successively placed in next group of p node;Or
If m is 2 integral multiple, back end is divided into m/2 group, every group of 2 nodes mutually deposit p backup fragment.
Further, the computing unit is used for:
According to the reliability of configuration backup fragment described in the probability calculation of any two node failure.
The dispositions method and device of the more data fragmentation backups of data-base cluster provided in an embodiment of the present invention, by scheduled
Rule configures the deployment way of a variety of backup fragments, and wherein the highest configuration mode of reliability, can as deployment way for selection
Optimal reliability deployment is carried out, and big degree ensures the reliability of cluster.
Detailed description of the invention
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below will be in embodiment or description of the prior art
Required attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is only some realities of the invention
Example is applied, it for those of ordinary skill in the art, without any creative labor, can also be attached according to these
Figure obtains other attached drawings.
Fig. 1 is the process signal of the dispositions method for the more data fragmentation backups of data-base cluster that the embodiment of the present invention one provides
Figure;
Fig. 2 is the structural representation of the deployment device of the more data fragmentation backups of data-base cluster provided by Embodiment 2 of the present invention
Figure.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation description, it is clear that described embodiments are some of the embodiments of the present invention, instead of all the embodiments.Based on this hair
Embodiment in bright, every other implementation obtained by those of ordinary skill in the art without making creative efforts
Example, shall fall within the protection scope of the present invention.
Embodiment one
Fig. 1 is the process signal of the dispositions method for the more data fragmentation backups of data-base cluster that the embodiment of the present invention one provides
Figure, the present embodiment are applicable to the case where data-base cluster is disposed backup fragment, and this method can be by data base set
The deployment device of group's more data fragmentations backup executes, which can be realized by software/hardware mode, and can be integrated in database
In group system.
Referring to Fig. 1, the dispositions method of the more data fragmentation backups of data-base cluster, comprising:
S110 obtains the number of nodes in data-base cluster.
The data-base cluster refers to the cluster being made of multiple database nodes, and the node in data-base cluster is known as collecting
Group node, clustered node are the carrier of data fragmentation and backup fragment, can determine data according to the management node of data-base cluster
Number of nodes in the cluster of library.
S120 obtains the corresponding data fragmentation quantity of each node in data-base cluster.
Data fragmentation refers to and stores 1 part of data fragmentation relative to each clustered node, and more data fragmentations are in each clustered node
Store more parts of data fragmentations.
S130, according to default rule configuration backup fragment.
The more data fragmentation backups of data-base cluster, there is following 5 kinds of configuration strategies:
Assuming that cluster has m node, there are p main fragments on each node.
Configuration strategy 1: back end is not grouped, and the backup fragment of p data fragmentation of first node is successively placed on down
In the p node that one node starts.
Configuration strategy 2: back end is not grouped, and the backup fragment of p data fragmentation of first node is all placed on down
On one node.
Configuration strategy 3: if m is the integral multiple and m > p+1 of p+1, back end is grouped as n group, every group has p+1 section
Point, the backup fragment of p data fragmentation of each node are successively placed in other p node of this group.
Configuration strategy 4: if m is the integral multiple and m > p of p.Back end is divided into n group, every group has p node, each
The backup fragment of p data fragmentation of node is successively placed in next group of p node.
Configuration strategy 5: if m is 2 integral multiple, back end is divided into m/2 group, it is a standby mutually to deposit p for every group of 2 nodes
Part fragment.
S140 calculates the reliability of the configuration backup fragment, chooses Optimal reliability as dispositions method.
Illustratively, the reliability of the configuration backup fragment according to the probability calculation of any two node failure.It presses
According to five kinds of strategies that S130 is provided, then it is as follows to calculate separately reliability:
1 reliability of configuration strategy: all nodes in cluster, the combination of any two node failure haveAnd in cluster
The combination of any two node failure while hiting data fragment and backup fragment has m × p, then cluster reliable probability
2 reliability of configuration strategy: all nodes in cluster, the combination of any two node failure haveAnd in cluster
The combination of any two node failure while hiting data fragment and backup fragment has m.Then cluster reliable probability
3 reliability of configuration strategy: all nodes in cluster, the combination of any two node failure haveAnd each group
The combination that interior any two node failure hits active and standby fragment simultaneously hasA group of shared m/ (p+1).Then cluster reliability
Probability is
4 reliability of configuration strategy: all nodes in cluster, the combination of any two node failure haveAnd adjacent two
The combination that a group of any two node failure hits active and standby fragment simultaneously has p × p, shares m/p adjacent sets.Then cluster reliability
Probability
5 reliability of configuration strategy: all nodes in cluster, the combination of any two node failure haveAnd appoint in organizing
It anticipates two node failures while the combination of hitting active and standby fragment has 1, share m/2 group.Then cluster reliable probability
Such as: the data-base cluster with 30 nodes, each node requirements have 5 master data fragments.Backup fragment portion
Administration tool interior can generate 5 kinds of different dispositions methods and and calculate reliability:
30 nodes (m=30) are not grouped, are disposed according to deployment way 1, according to the present invention in formula can count
Calculate the reliability P1=10/29 of this deployment way
30 nodes (m=30) are not grouped, are disposed according to deployment way 2, according to the present invention in formula can count
Calculate the reliability P2=27/29 of this deployment way
30 nodes (m=30) are grouped, 30/ (5+1) can divide exactly, be disposed according to deployment way 3.According to this hair
Bright middle formula can calculate the reliability P3=24/29 of this deployment way
30 nodes (m=30) are grouped, 30/5 can divide exactly, and be disposed according to deployment way 4.According to the present invention
Formula can calculate the reliability P4=10/29. of this deployment way
30 nodes (m=30) are grouped, 30/2 can divide exactly, and be disposed according to deployment way 5.According to the present invention
Formula can calculate the reliability P5=28/29 of this deployment way
It can thus be seen that each node requirements have 5 master datas point for the data-base cluster with 30 nodes
Piece, the 5th kind of preparation method is optimal, and fifth method is selected to be configured.
The dispositions method and device of the more data fragmentation backups of data-base cluster provided in this embodiment, pass through scheduled rule
The deployment way of a variety of backup fragments is configured, and choose the wherein highest configuration mode of reliability to carry out as deployment way
Optimal reliability deployment, and big degree ensures the reliability of cluster.
Embodiment two
Fig. 2 is the structural representation of the deployment device of the more data fragmentation backups of data-base cluster provided by Embodiment 2 of the present invention
Figure, as shown in Fig. 2, described device includes:
Node acquiring unit 210, for obtaining the number of nodes in data-base cluster;
Data fragmentation number obtainment unit 220, for obtaining the corresponding data fragmentation number of each node in data-base cluster
Amount;
Configuration unit 230, for according to default rule configuration backup fragment;
Computing unit 240 chooses Optimal reliability and is used as deployment side for calculating the reliability of the configuration backup fragment
Method.
Further, the default rule, comprising:
The backup fragment of p data fragmentation of first node is successively placed in the p node that next node starts;Or
Person
The backup fragment of p data fragmentation of first node is all placed in next node;Or
If number of nodes m is the integral multiple and m > p+1 of p+1, back end is grouped as n group, every group has p+1 node,
The backup fragment of p data fragmentation of each node is successively placed in other p node of this group;Or
If m is the integral multiple and m > p of p.Back end is divided into n group, every group has p node, p data of each node
The backup fragment of fragment is successively placed in next group of p node;Or
If m is 2 integral multiple, back end is divided into m/2 group, every group of 2 nodes mutually deposit p backup fragment.
Further, the computing unit is used for:
According to the reliability of configuration backup fragment described in the probability calculation of any two node failure.
The dispositions method and device of the more data fragmentation backups of data-base cluster provided in an embodiment of the present invention, by scheduled
Rule configures the deployment way of a variety of backup fragments, and wherein the highest configuration mode of reliability, can as deployment way for selection
Optimal reliability deployment is carried out, and big degree ensures the reliability of cluster.
Those of ordinary skill in the art will appreciate that: realize that all or part of the steps of above-mentioned each method embodiment can lead to
The relevant hardware of program instruction is crossed to complete.Program above-mentioned can be stored in a computer readable storage medium.The journey
When being executed, execution includes the steps that above-mentioned each method embodiment to sequence;And storage medium above-mentioned include: ROM, RAM, magnetic disk or
The various media that can store program code such as person's CD.
Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention., rather than its limitations;To the greatest extent
Pipe present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that: its according to
So be possible to modify the technical solutions described in the foregoing embodiments, or to some or all of the technical features into
Row equivalent replacement;And these are modified or replaceed, various embodiments of the present invention technology that it does not separate the essence of the corresponding technical solution
The range of scheme.
Claims (4)
1. a kind of dispositions method of the more data fragmentation backups of data-base cluster characterized by comprising
Obtain the number of nodes in data-base cluster;
Obtain the corresponding data fragmentation quantity of each node in data-base cluster;
According to default rule configuration backup fragment;
The reliability of the configuration backup fragment is calculated, chooses Optimal reliability as dispositions method;
The default rule, comprising:
The backup fragment of p data fragmentation of first node is successively placed in the p node that next node starts;Or
The backup fragment of p data fragmentation of first node is all placed in next node;Or
If number of nodes m is the integral multiple and m > p+1 of p+1, back end is grouped as n group, every group has p+1 node, each
The backup fragment of p data fragmentation of node is successively placed in other p node of this group;Or
If m is the integral multiple and m > p of p, back end is divided into n group, every group has p node, p data fragmentation of each node
Backup fragment be successively placed in next group of p node;Or
If m is 2 integral multiple, back end is divided into m/2 group, every group of 2 nodes mutually deposit p backup fragment.
2. the method according to claim 1, wherein the reliability for calculating the configuration backup fragment, packet
It includes:
According to the reliability of configuration backup fragment described in the probability calculation of any two node failure.
3. a kind of deployment device of the more data fragmentation backups of data-base cluster characterized by comprising
Node acquiring unit, for obtaining the number of nodes in data-base cluster;
Data fragmentation number obtainment unit, for obtaining the corresponding data fragmentation quantity of each node in data-base cluster;
Configuration unit, for according to default rule configuration backup fragment;
Computing unit chooses Optimal reliability as dispositions method for calculating the reliability of the configuration backup fragment;
The default rule, comprising:
The backup fragment of p data fragmentation of first node is successively placed in the p node that next node starts;Or
The backup fragment of p data fragmentation of first node is all placed in next node;Or
If number of nodes m is the integral multiple and m > p+1 of p+1, back end is grouped as n group, every group has p+1 node, each
The backup fragment of p data fragmentation of node is successively placed in other p node of this group;Or
If m is the integral multiple and m > p of p, back end is divided into n group, every group has p node, p data fragmentation of each node
Backup fragment be successively placed in next group of p node;Or
If m is 2 integral multiple, back end is divided into m/2 group, every group of 2 nodes mutually deposit p backup fragment.
4. device according to claim 3, which is characterized in that the computing unit is used for:
According to the reliability of configuration backup fragment described in the probability calculation of any two node failure.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610777563.0A CN106354585B (en) | 2016-08-31 | 2016-08-31 | The dispositions method and device of the more data fragmentation backups of data-base cluster |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610777563.0A CN106354585B (en) | 2016-08-31 | 2016-08-31 | The dispositions method and device of the more data fragmentation backups of data-base cluster |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106354585A CN106354585A (en) | 2017-01-25 |
CN106354585B true CN106354585B (en) | 2019-04-30 |
Family
ID=57856916
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610777563.0A Active CN106354585B (en) | 2016-08-31 | 2016-08-31 | The dispositions method and device of the more data fragmentation backups of data-base cluster |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106354585B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107544848B (en) * | 2017-08-30 | 2019-10-25 | 深圳云天励飞技术有限公司 | Cluster expansion method, apparatus, electronic equipment and storage medium |
CN109656911B (en) * | 2018-12-11 | 2023-08-01 | 江苏瑞中数据股份有限公司 | Distributed parallel processing database system and data processing method thereof |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105426427A (en) * | 2015-11-04 | 2016-03-23 | 国家计算机网络与信息安全管理中心 | MPP database cluster replica realization method based on RAID 0 storage |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10489412B2 (en) * | 2012-03-29 | 2019-11-26 | Hitachi Vantara Corporation | Highly available search index with storage node addition and removal |
-
2016
- 2016-08-31 CN CN201610777563.0A patent/CN106354585B/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105426427A (en) * | 2015-11-04 | 2016-03-23 | 国家计算机网络与信息安全管理中心 | MPP database cluster replica realization method based on RAID 0 storage |
Non-Patent Citations (1)
Title |
---|
Research on The Improvement of MongoDB Auto-Sharding in Cloud Environment;Yimeng Liu etal.;《IEEE》;20120906;第852-853页 |
Also Published As
Publication number | Publication date |
---|---|
CN106354585A (en) | 2017-01-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9348641B2 (en) | System and method for performing a transaction in a massively parallel processing database | |
CN104731896B (en) | A kind of data processing method and system | |
CN105871603B (en) | A kind of the real time streaming data processing fail recovery and method of data grids based on memory | |
US20150161016A1 (en) | Method and system of self-managing nodes of a distributed database cluster with a consensus algorithm | |
US10152500B2 (en) | Read mostly instances | |
CN106126407A (en) | A kind of performance monitoring Operation Optimization Systerm for distributed memory system and method | |
EP2713555B1 (en) | Data configuration method and device, and rollback method and device for data configuration | |
CN109840251B (en) | Big data aggregation query method | |
CN103399894A (en) | Distributed transaction processing method on basis of shared storage pool | |
CN105956481A (en) | Data processing method and device | |
CN106354585B (en) | The dispositions method and device of the more data fragmentation backups of data-base cluster | |
CN105518641A (en) | Method, device, and system for peer-to-peer data replication and method, device, and system for master node switching | |
CN108984744A (en) | A kind of non-master chain block self-propagation method | |
Chen et al. | Analyzing dynamic voting using petri nets | |
US20100262871A1 (en) | Method for implementing highly available data parallel operations on a computational grid | |
KR20100004605A (en) | Method for selecting node in network system and system thereof | |
CN105357042A (en) | High-availability cluster system, master node and slave node | |
Wang et al. | Exploring the design tradeoffs for extreme-scale high-performance computing system software | |
CN107818106B (en) | Big data offline calculation data quality verification method and device | |
CN106446289A (en) | Information inquiry method and device based on Pinpoint | |
CN112491592B (en) | Storage resource grouping method, system, terminal and storage medium | |
CN109359205A (en) | A kind of remote sensing image cutting method and equipment based on geographical grid | |
CN108491294A (en) | A kind of database backup method, apparatus and system | |
Srinivasa et al. | Fault-tolerant middleware for grid computing | |
CN113761052A (en) | Database synchronization method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |