Embodiment
For making the purpose, technical solutions and advantages of the present invention clearer, the embodiment of the invention is described in further details below in conjunction with accompanying drawing.The embodiment of the invention is a kind of technology of automatic distribution RAID 6 bandwidth, target bandwidth parameter according to user's input is distributed to user's utilized bandwidth, thereby avoid and to carry out computing with fixed-bandwidth, good quality of service not only is provided, and has made the certain power consumption of hardware saving on the RAID 6.
At this, illustrative examples of the present invention and explanation thereof are used to explain the present invention, but not as a limitation of the invention.
Embodiment one
The embodiment of the invention provides the method for bandwidth in a kind of automatic distribution RAID 6 arithmetic systems, and as shown in Figure 1, described method comprises:
101, receive the target bandwidth parameter of input;
102, determine the utilized bandwidth parameter according to described target bandwidth parameter;
103, according to the buffer memory bandwidth of the buffer unit in described RAID 6 arithmetic systems of described utilized bandwidth parameter configuration and the computing bandwidth of arithmetic element.
Can receive the target bandwidth parameter of user communication device input in the embodiment of the invention step 101, this target bandwidth parameter can be that user communication device wishes to communicate the bandwidth numerical value that expectation reaches with RAID 6 arithmetic systems, the big more explanation user communication device of bandwidth parameter wishes that the speed that communicates with RAID 6 arithmetic systems is fast more, wishes to obtain communication efficiency preferably with this.Step 102 is determined the utilized bandwidth parameter according to the target bandwidth parameter that step 101 receives.Because the total bandwidth in the RAID6 arithmetic system is limited after all, so will determine the utilized bandwidth parameter of described target bandwidth parameter correspondence according to certain condition, could reach reasonable disposition to total bandwidth like this.Such as the utilized bandwidth parameter that can determine user communication device according to conditions such as the priority of user communication device or network conditions, the information that ID carried when wherein conditions such as the priority of user communication device or network condition can be landed according to user communication device etc. is obtained.Step 103 can be according to the buffer memory bandwidth of the buffer unit in definite utilized bandwidth parameter configuration RAID 6 arithmetic systems of step 102 and the computing bandwidth of arithmetic element, because source data is to arrive arithmetic element again through buffer unit, so at every turn in the process that source data is handled, the bandwidth of buffer unit and arithmetic element must be complementary, but because each source data amount difference of handling, so each buffer memory bandwidth that requires is also different with the computing amount of bandwidth, so buffer memory bandwidth in the buffer unit and the computing bandwidth in the arithmetic element must be adjustable, can not all fix as buffer memory bandwidth in the buffer unit of the prior art and the computing bandwidth in the arithmetic element.Such as the adjustable pushup storage of buffer unit available depth, i.e. the CELL FIFO of depth-adjustment (CELL First In First Out), arithmetic element available parallelism multiplier.
So just can distribute the bandwidth in RAID 6 arithmetic systems automatically, thereby also adjusted the utilized bandwidth of user communication device, make user communication device communicate by utilized bandwidth and RAID 6 arithmetic systems, RAID 6 arithmetic systems also can be carried out corresponding computing according to the bandwidth of automatic distribution, thereby for user communication device provides suitable service quality (QoS, Quality of Service).
Need to prove, to before last time source data is handled, the target bandwidth parameter that newly receives input is not deposited in the storer, such as register, when to after last time source data is handled, newly determine the utilized bandwidth parameter according to target bandwidth parameter renegotiation.
According to the bandwidth in RAID 6 arithmetic systems of described utilized bandwidth parameter configuration not necessarily is exactly the target bandwidth of described target bandwidth parameter correspondence, generally have only when the maximum utilized bandwidth in RAID 6 arithmetic systems and be not assigned with the target bandwidth that just can obtain target bandwidth parameter correspondence when finishing, promptly the bandwidth numerical value in RAID 6 arithmetic systems of configuration this moment equals the target bandwidth parameter, perhaps when the priority of user communication device is higher, just can obtain the target bandwidth of target bandwidth parameter correspondence, i.e. utilized bandwidth; If but the priority of certain user communication device is lower, and the maximum utilized bandwidth in RAID 6 arithmetic systems is assigned with and finishes, the utilized bandwidth that this moment, user communication device was assigned with may just be not equal to the target bandwidth, but serve as that the basis be the only utilized bandwidth of the user communication device distribution of lower priority by algorithm (such as priority algorithm) with the target bandwidth parameter, though the user communication device of lower priority can not communicate by target bandwidth and RAID 6 arithmetic systems like this, but also can communicate, obtain good quality of service by a more suitable bandwidth and RAID 6 arithmetic systems.
Like this, different user communication devices just can obtain different bandwidth and RAID 6 arithmetic systems communicate, thereby obtain different service quality.
Need to prove, the target bandwidth parameter can not be greater than the applicable maximum bandwidth of user communication device self of input target bandwidth parameter, even the target bandwidth parameter of input greater than the applicable maximum bandwidth of user self, also can be subjected to user self the restriction of applicable maximum bandwidth.
Present embodiment advantage compared with prior art is, user communication device no longer relies on fixed-bandwidth and RAID 6 arithmetic systems to communicate, can obtain the utilized bandwidth of target bandwidth parameter correspondence according to the target bandwidth parameter of input, rationally obtain utilized bandwidth separately, thereby enjoy service separately.
Embodiment two
The embodiment of the invention also provides the method for bandwidth in a kind of automatic distribution RAID 6 arithmetic systems, this method is behind the target bandwidth parameter that receives input, determine the utilized bandwidth parameter according to described target bandwidth parameter, and according to the buffer memory bandwidth of the buffer unit in described utilized bandwidth parameter configuration RAID 6 arithmetic systems and the computing bandwidth of arithmetic element.As shown in Figure 2, in the method that present embodiment provides, determine that according to described target bandwidth parameter the utilized bandwidth parameter comprises:
201, the maximum bandwidth of judging RAID 6 whether be assigned with finish and the target bandwidth parameter whether smaller or equal to the bandwidth that is not assigned with in the maximum bandwidth, if described maximum bandwidth be not assigned with finish and the target bandwidth parameter smaller or equal to the bandwidth that is not assigned with in the maximum bandwidth, then execution in step 202; If described maximum bandwidth be assigned with finish or the target bandwidth parameter greater than the bandwidth that is not assigned with in the maximum bandwidth, then execution in step 203;
202, determine that the utilized bandwidth parameter is the target bandwidth parameter;
203, determine the priority of the user communication device of the described target bandwidth parameter of input, determine the utilized bandwidth parameter of described target bandwidth parameter correspondence according to described priority.
Determine the utilized bandwidth parameter according to the target bandwidth parameter that receives in the embodiment of the invention; Wherein definite actual bandwidth parameter that uses can be determined according to the priority of the user communication device of importing the target bandwidth parameter and/or the maximum bandwidth distribution condition of RAID 6 arithmetic systems, such as all not distributed when the maximum bandwidth of RAID 6 arithmetic systems and target bandwidth parameter smaller or equal to the bandwidth that is not assigned with in the maximum bandwidth time, general utilized bandwidth parameter just equals the target bandwidth parameter; But when the maximum bandwidth of RAID6 has all been assigned or target bandwidth parameter greater than the bandwidth that is not assigned with in the maximum bandwidth time, will consider to import the priority of the user communication device of target bandwidth parameter, the user communication device that priority is high can obtain the target bandwidth of target bandwidth parameter correspondence, also is the obtainable utilized bandwidth of user communication device.The utilized bandwidth that the user communication device that priority is low obtains is not the target bandwidth of target bandwidth parameter correspondence just, but the utilized bandwidth parameter of the target bandwidth parameter correspondence that the process priority algorithm obtains.As long as determine that the utilized bandwidth parameter just can be according to the buffer memory bandwidth of the buffer unit in described utilized bandwidth parameter configuration RAID 6 arithmetic systems and the computing bandwidth of arithmetic element, thereby acquisition utilized bandwidth.
Behind the target bandwidth parameter that receives the user communication device input, will carry out allocated bandwidth according to described target bandwidth parameter.Because the bandwidth that user communication device and RAID 6 arithmetic systems communicate is limited after all, when communicating, more user communication device and RAID 6 arithmetic systems can not satisfy each user's target bandwidth, so will distribute bandwidth according to the rank of the user communication device of input target bandwidth parameter.But the bandwidth that whether maximum bandwidth that can judge RAID 6 before distributing bandwidth earlier according to step 301 assigns and whether the target bandwidth parameter is not assigned with in smaller or equal to maximum bandwidth, if do not assign and the target bandwidth parameter less this moment smaller or equal to the bandwidth statement that is not assigned with in the maximum bandwidth with the user communication device that RAID 6 arithmetic systems communicate, can satisfy the target bandwidth parameter of these user communication device inputs fully, by distributing the target bandwidth to communicate for they and RAID 6 arithmetic systems, RAID 6 arithmetic systems also can communicate according to different bandwidth that is assigned to and corresponding user communication device simultaneously.
But if the maximum bandwidth in RAID 6 arithmetic systems has assigned or though maximum bandwidth does not assign, but the target bandwidth parameter is greater than the bandwidth that is not assigned with in the maximum bandwidth, illustrate that this moment and the user communication device that communicates of RAID 6 arithmetic systems are more, all user communication devices that can not satisfy input target bandwidth parameter fully obtain the target bandwidth, so will determine the priority of the user communication device of the described target bandwidth parameter of input this moment according to step 303, and determine the utilized bandwidth parameter of target bandwidth parameter correspondence according to described priority; And determine that according to described priority the utilized bandwidth parameter of described target bandwidth parameter correspondence can be is the only utilized bandwidth parameter of the user communication device selection of lower grade by priority algorithm, thereby be that subsequent step is according to described utilized bandwidth parameter configuration utilized bandwidth.Though the user communication device of lower grade can not communicate by target bandwidth and RAID 6 arithmetic systems like this, also can communicate by a more suitable bandwidth and RAID 6 arithmetic systems, obtain good quality of service.
For instance, when the maximum bandwidth in RAID 6 arithmetic systems is 10M, user communication device D wishes to communicate with RAID 6 arithmetic systems, suppose that the target bandwidth parameter that user communication device D is provided with is 2M, inserting the user communication device A of RAID 6 arithmetic systems and the utilized bandwidth of user communication device B acquisition earlier respectively is 3M, the utilized bandwidth that user communication device C obtains is 2M, the RAID6 arithmetic system is after finding have user communication device D to insert, can judge whether current maximum bandwidth 10M assigns and target bandwidth parameter 2M whether smaller or equal to the bandwidth that is not assigned with in the maximum bandwidth, because the utilized bandwidth that user communication device A and user communication device B obtain respectively is 3M, the utilized bandwidth that user communication device C obtains is 2M, be that total bandwidth is assigned as 8M, also have the 2M bandwidth not to be assigned with, and the target bandwidth parameter of user communication device D is 2M, vacant 2M bandwidth can satisfy the target bandwidth of user communication device D fully, so the actual bandwidth parameter of user communication device D is the target bandwidth parameter, the utilized bandwidth of acquisition is 2M.
When having user communication device E to wish to communicate again with RAID 6 arithmetic systems, still can judge earlier whether current maximum bandwidth 10M assigns, suppose that the target bandwidth parameter that user communication device E is provided with is 2M, because the utilized bandwidth that user communication device A and user communication device B obtain respectively is 3M, the utilized bandwidth that user communication device C and user communication device D obtain respectively is 2M, be that total bandwidth is assigned as 10M, there is not bandwidth left, so need to judge the priority of user communication device E this moment, the user profile that obtains when inserting according to user communication device E, as identifying the priority of determining user communication device E according to landing in the user profile, and user communication device A before searching, B, C, the priority that D reports when inserting, determine user communication device A, B, E is same one-level, user communication device C, the priority of D is identical and than user communication device A, B, E is low, so maximum bandwidth is distributed again, because the priority of user communication device E is higher than user communication device C, D, so user communication device E can actual bandwidth parameter be the target bandwidth parameter, the utilized bandwidth of acquisition is 2M.The utilized bandwidth of user communication device A, B is constant, still respectively is 3M.The priority of user communication device C, D is minimum, respectively is 1M.In above-mentioned example, if user communication device A, B, C is same one-level, user communication device D, the priority of E is identical and than user communication device A, B, C is low, so also will distribute again to maximum bandwidth, because the priority of user communication device E is lower than user communication device A, B, C, so user communication device E can actual bandwidth parameter be not the target bandwidth parameter just, can dispose number percent to user communication device D this moment according to priority algorithm, the bandwidth of E is configured, such as disposing number percent according to priority algorithm of the prior art is 50%, then user communication device D, the utilized bandwidth that E obtains is 1M.The utilized bandwidth of user communication device A, B, C is constant.The priority of user communication device D, E is minimum, respectively is 1M.
Like this, different user communication devices just can obtain different bandwidth and RAID 6 arithmetic systems communicate, thereby obtain different service quality.
The advantage of doing like this is, can according to priority the suitable utilized bandwidth parameter of user communication device selection of different stage, thereby more rationally dispose the buffer memory bandwidth of the buffer unit in RAID 6 arithmetic systems and the computing bandwidth of arithmetic element accurately according to the utilized bandwidth parameter, it is the utilized bandwidth of user communication device, make the distribution of bandwidth to adjust flexibly, no longer arrest in each user and all communicate with fixed-bandwidth and RAID 6 arithmetic systems.
In the present embodiment, will be after determining the utilized bandwidth parameter according to the buffer memory bandwidth of the buffer unit in described utilized bandwidth parameter configuration RAID 6 arithmetic systems and the computing bandwidth of arithmetic element according to described target bandwidth parameter, buffer memory bandwidth according to the described buffer unit of described utilized bandwidth parameter configuration can realize by mode as shown in Figure 3, please refer to Fig. 3, this method comprises:
301, the quantity of cache module in the described buffer unit of the corresponding described utilized bandwidth parameter of distribution;
302, adjust the buffer memory framework of described buffer unit according to the quantity of described cache module.
Described buffer memory bandwidth is meant the bandwidth of data buffer in RAID 6 arithmetic systems, also claims the front end data bandwidth according to the transmission direction of source data, so the data of buffer zone promptly can be described as front end data herein.Because the source data that inserts when user communication device and RAID 6 arithmetic systems communicate is the process buffer unit earlier, so will with suitable bandwidth with the source data that enters is flux matched must be according to the utilized bandwidth parameter, the quantity of cache module in the described buffer unit of the corresponding described utilized bandwidth parameter of step 301 distribution, buffer unit in the present embodiment is the adjustable buffer unit of bandwidth, CELL FIFO such as depth-adjustment, described buffer unit all has the data storage capacities cache module by several and forms, such as the cell among the CELL FIFO, the quantity of these cache modules can change accordingly according to the utilized bandwidth parameter, and the quantity of described cache module changes the change that also means buffer memory framework in the buffer unit, finally makes the buffer memory bandwidth change.Such as in the CELL of depth-adjustment FIFO, the utilized bandwidth parameter is 3M, then needs 3 cell to carry out buffer memory to source data; When the utilized bandwidth parameter is 5M, then just need 5 cell to carry out buffer memory to source data; Certainly the maximum bandwidth number in the buffer memory can not become, and promptly cache size can not become, but the change of cell quantity also means the change of each cell storage data capability.So in case change when the quantity of cache module, original buffer memory framework of buffer unit also just changes, be adjusted into new buffer memory framework according to the quantity of new cache module, thereby adapt to new source data amount size.
The buffer memory bandwidth indicates the ability that the RAID6 arithmetic system can process source data volume size, adjust the buffer memory framework according to the corresponding cache module of parameter configuration, thereby reach the purpose of allocating cache bandwidth, improve the dirigibility of RAID6 arithmetic system greatly, when handling small amount of data, can save system power dissipation.
Computing bandwidth according to described utilized bandwidth parameter configuration arithmetic element in the present embodiment can realize that please refer to Fig. 4, this method comprises by mode as shown in Figure 4:
The quantity of 401, distributing the concurrent operation unit of corresponding described utilized bandwidth parameter;
402, adjust the computing framework according to described concurrent operation element number.
Described computing bandwidth is meant the bandwidth according to data operation district in described utilized bandwidth parameter configuration RAID 6 arithmetic systems, also claims the Back end data bandwidth according to the transmission direction of source data, so data herein promptly can be described as Back end data.And the computing bandwidth is configured mainly is to distribute the quantity of the concurrent operation unit of corresponding described utilized bandwidth parameter to realize by step 401, because the concurrent operation unit can carry out concurrent operation to Back end data, the quantity of concurrent operation unit is many more, it is just strong more simultaneously Back end data to be carried out the ability of computing in the set time, makes the computing bandwidth big more.But the change of the quantity of concurrent operation unit means the variation of computing framework, thus also to adjust the computing framework according to described concurrent operation element number according to step 402, thus just can finish operation of data.
Back end data mainly comprises checking data and failure recovery data in the RAID arithmetic system, thus distribute the quantity of the concurrent operation unit of corresponding described utilized bandwidth parameter just distribute corresponding described utilized bandwidth parameter the parallel computation checking data arithmetic element and distribute the parallel fail data of corresponding described utilized bandwidth parameter to recover arithmetic element.
So to the main configuration that just actual checking data computing bandwidth and considered repealed data is recovered the computing bandwidth of the configuration of computing bandwidth.Below this is described respectively.
Different user communications device accesses RAID 6 arithmetic systems communicate mutual data difference, and each source data all will be carried out verification computing acquisition checking data in RAID 6 arithmetic systems, so how many source datas are the utilized bandwidth of different user communication facilities determined to be carried out the verification computing substantially.Source data is carried out the arithmetic element that the verification computing then needs certain parallel computation checking data, so distribute the quantity of arithmetic element of the parallel computation checking data of corresponding described utilized bandwidth parameter, the arithmetic element quantity of parallel computation checking data is many more, it is just strong more Back end data to be carried out the ability of verification computing in unit interval, makes that verification computing bandwidth is big more.After distributing the arithmetic element of parallel computation checking data, adjust the framework of verification computing again according to the quantity of the arithmetic element of parallel computation checking data, thereby prepare for the verification source data.The framework of wherein said verification computing comprises path, flow process and the operation time sequence of verification computing.
Equally, recover computing because how many source datas are the utilized bandwidth of different user communication facilities determine to have at most to be carried out data substantially.Source data is carried out data recovery computing then needs certain parallel fail data to recover arithmetic element, recover the quantity of arithmetic element so distribute the parallel fail data of corresponding described utilized bandwidth parameter, the quantity that parallel fail data is recovered arithmetic element is many more, Back end data being carried out data in unit interval, to recover the ability of computing just strong more, and it is big more to make fail data recover the computing bandwidth.Distribute after parallel fail data recovers arithmetic element, the quantity of recovering arithmetic element according to parallel fail data is adjusted the framework that fail data is recovered computing again, thereby prepares for the recovery computing of source data.The framework of wherein said fail data recovery computing comprises the sequential of path, flow process and the fail data recovery computing of fail data recovery computing.
In the present embodiment, the adjustment by to checking data computing bandwidth and fail data recovery bandwidth finally makes the computing bandwidth identical with the buffer memory bandwidth, thereby has guaranteed that Back end data bandwidth and front end data bandwidth are complementary.The adjustable fifo buffer of buffer unit available depth wherein, i.e. the CELL FIFO of depth-adjustment (CELL First In First Out), arithmetic element available parallelism multiplier.
The advantage of present embodiment is, not only can determine the utilized bandwidth parameter of target bandwidth parameter according to priority, and can be according to utilized bandwidth parameter configuration buffer memory bandwidth and computing bandwidth, and when configuration computing bandwidth, can obtain actual checking data computing bandwidth and obtain considered repealed data recovery computing bandwidth by disposing parallel fail data recovery arithmetic element by the arithmetic element of configuration parallel computation checking data, thereby make that front end data bandwidth and Back end data bandwidth are complementary in the RAID6 arithmetic system, not only more help inserting user communication device and obtain suitable service quality, also brief power consumption necessarily on hardware is promptly used the reasonable configuration bandwidth service of offering the best.
Embodiment three
In order better to realize embodiment one, embodiment two described methods, the embodiment of the invention also provides the device of bandwidth in a kind of automatic distribution RAID 6 arithmetic systems, this device can provide RAID6 service for user communication device, as shown in Figure 5, Fig. 5 is the structured flowchart of device of a kind of automatic distribution RAID 6 bandwidth of the embodiment of the invention, described device comprises receiving element 501, decision package 502 and band width configuration unit 503, wherein:
Receiving element 501 is mainly used in the target bandwidth parameter that receives input;
Decision package 502 is mainly used in according to described target bandwidth parameter and determines the utilized bandwidth parameter;
Allocated bandwidth unit 503 is mainly used in the buffer memory bandwidth of the buffer unit in the described RAID6 arithmetic system of determining according to described decision package of utilized bandwidth parameter configuration and the computing bandwidth of arithmetic element.
In the present embodiment, decision package 502 be mainly used in whether the maximum bandwidth of judging in RAID 6 arithmetic systems assigns and the target bandwidth parameter whether smaller or equal to the bandwidth that is not assigned with in the maximum bandwidth, if do not assign and the target bandwidth parameter smaller or equal to the bandwidth that is not assigned with in the maximum bandwidth, determine that then the utilized bandwidth parameter is the target bandwidth parameter; If assign or the target bandwidth parameter greater than the bandwidth that is not assigned with in the maximum bandwidth, then determine the utilized bandwidth parameter of described target bandwidth parameter correspondence according to the priority of the described target bandwidth parameter side of input.
Wherein, described allocated bandwidth unit 503 can comprise: buffer memory band width configuration module 531 and computing band width configuration module 532,
Buffer memory band width configuration module 531 is mainly used in the quantity of cache module in the described buffer unit that distributes corresponding described utilized bandwidth parameter, and adjusts the buffer memory framework of described buffer unit according to the quantity of described cache module;
Computing band width configuration module 532 is mainly used in the quantity of the concurrent operation unit that distributes corresponding described utilized bandwidth parameter, and adjusts the computing framework according to described concurrent operation element number.
Wherein, when described computing band width configuration module 532 is used to distribute the quantity of concurrent operation unit of corresponding described utilized bandwidth parameter in described computing band width configuration module, can specifically be used to distribute the quantity of arithmetic element of the parallel computation checking data of corresponding described utilized bandwidth parameter, and adjust the computing framework of parallel computation checking data according to the quantity of the arithmetic element of parallel computation checking data; Can also specifically be used to distribute the parallel fail data of corresponding described utilized bandwidth parameter to recover the quantity of arithmetic element, and recover the computing framework of the parallel fail data recovery of quantity adjustment of arithmetic element according to parallel fail data.
The adjustable fifo buffer of buffer unit available depth in the present embodiment, i.e. the CELL FIFO of depth-adjustment (CELL First In First Out), arithmetic element available parallelism multiplier.
The device of bandwidth not only can provide RAID6 service for user communication device in automatic distribution RAID 6 arithmetic systems in the embodiment of the invention, and can be according to buffer memory bandwidth and the computing bandwidth in the utilized bandwidth parameter configuration RAID6 arithmetic system, thereby make the front end data bandwidth of RAID 6 and rear end computing bandwidth be complementary, not only more help inserting user communication device and obtain suitable service quality, and on hardware brief power consumption necessarily, use the reasonable configuration bandwidth service of offering the best.
The method of describing in conjunction with embodiment disclosed herein or the step of algorithm can directly use the software module of hardware, processor execution, and perhaps the combination of the two is implemented.Software module can place the storage medium of any other form known in random access memory (RAM), internal memory, ROM (read-only memory) (ROM), electrically programmable ROM, electrically erasable ROM, register, hard disk, moveable magnetic disc, CD-ROM or the technical field.
Above-described specific embodiment; purpose of the present invention, technical scheme and beneficial effect are further described; institute is understood that; the above only is specific embodiments of the invention; and be not intended to limit the scope of the invention; within the spirit and principles in the present invention all, any modification of being made, be equal to replacement, improvement etc., all should be included within protection scope of the present invention.