CN106126339B - Resource adjusting method and device - Google Patents
Resource adjusting method and device Download PDFInfo
- Publication number
- CN106126339B CN106126339B CN201610454298.2A CN201610454298A CN106126339B CN 106126339 B CN106126339 B CN 106126339B CN 201610454298 A CN201610454298 A CN 201610454298A CN 106126339 B CN106126339 B CN 106126339B
- Authority
- CN
- China
- Prior art keywords
- resource
- portfolio
- business
- business demand
- resource unit
- 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
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5027—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)
Abstract
The present invention provides a kind of resource adjusting method and device, applied to server, the resource of server is divided into multiple resource units, this method comprises: obtaining current first portfolio of the running business at each time point, traffic peak is determined in each first portfolio;According to the specified portfolio of traffic peak and resource unit, the number of resource units of business demand is determined;According to the number of resource units of business demand, the allocated resource of business is adjusted.The present invention passes through portfolio of the detection business under each time point, resource adjustment is carried out according to portfolio in time, so that resource adjusts process as user is changed using the variation of portfolio caused by business, therefore it can timely find that business uses slack problem, and this is solved the problems, such as in time, simultaneously because carrying out manual operation without operation maintenance personnel, cost of labor is thereby reduced.
Description
Technical field
The present invention relates to resource regulating method more particularly to a kind of resource adjusting methods and device.
Background technique
With the growth of the ability of server storage and processing data, the application field of server is more and more wider, using clothes
The task that device executes of being engaged in is more and more, and a server usually can meet the needs of being performed simultaneously multinomial business.The industry
Business is such as can be demand (telecommunication) service, downloading service.
Fluency when to guarantee that the every business of operation on the same server executes, need to be according to the business of every business
Amount, for the certain resource of every traffic assignments, which includes central processing unit (Central Processing Unit, abbreviation
CPU), memory etc..In actual use, in order to guarantee the fluency of service operation, the method that resource redundancy configuration can be used, but
It will lead to the wasting of resources.Therefore, usually changed by operation maintenance personnel according to portfolio, the regular or feelings low in service operation fluency
Under condition, the resource allocation of server is adjusted.
But since operation maintenance personnel is only capable of just passively being serviced periodically or when the fluency of service operation reduces
The adjustment of device resource;However operation maintenance personnel need to take considerable time when carrying out resource adjustment and carry out case study and formulate to solve
Scheme cannot solve a problem promptly, therefore there is a problem of that labor intensive, timeliness are poor.
Summary of the invention
The present invention provides a kind of resource adjusting method and device, exists for solving existing resource method of adjustment and expends people
The poor problem of power, timeliness.
In a first aspect, the present invention provides a kind of resource adjusting method, it is applied to server, the resource of the server is drawn
It is divided into multiple resource units, comprising:
Current first portfolio of the running business at each time point is obtained, is determined most in each first portfolio
High traffic;
According to the specified portfolio of the traffic peak and resource unit, the resource unit number of the business demand is determined
Amount;
According to the number of resource units of the business demand, the allocated resource of the business is adjusted.
Resource adjusting method as described above, the specified portfolio according to the traffic peak and resource unit,
Determine the number of resource units of the business demand, comprising:
Division processing is carried out to the specified portfolio of the traffic peak and the resource unit, obtains multiple value;
According to the multiple value, the number of resource units of the business demand is determined.
Resource adjusting method as described above, the specified portfolio according to the traffic peak and resource unit,
Determine the number of resource units of the business demand, comprising:
According to the traffic peak, the number of resource units of the business demand is determined in the business demand table of comparisons;
Wherein, the corresponding number of resource units of the first portfolio of difference is stored in the business demand table of comparisons.
Resource adjusting method as described above, the specified portfolio according to the traffic peak and resource unit,
Before the number of resource units for determining the business demand, further includes:
Repeatedly obtain second business of the business when the utilization rate of first resource unit reaches default utilization rate in test
Amount, the first resource unit is any resource unit for distributing to the business in the test;
According to each second portfolio, the specified portfolio of any resource unit is determined.
Resource adjusting method as described above, it is described according to each second portfolio, determine any resource unit
Specified portfolio, comprising:
Average value processing is carried out to each second portfolio, obtains portfolio mean value;
In each second portfolio, the determining third business for being less than preset value with the difference of the portfolio mean value
Amount;
Average value processing is carried out to each third portfolio, determines the specified portfolio of any resource unit.
Resource adjusting method as described above, the number of resource units according to the business demand, to the business
Allocated resource be adjusted, comprising:
Judge whether the number of resource units of the business demand is equal to allocated number of resource units;
If it is not, being then adjusted to allocated number of resource units, so that distributing to the resource unit number of the business
Amount reaches the number of resource units of the business demand.
On the other hand, the present invention provides a kind of resource adjustment device, is applied to server, the resource of the server is drawn
It is divided into multiple resource units, comprising:
Traffic peak obtains module, for obtaining current first portfolio of the running business at each time point,
Traffic peak is determined in each first portfolio;
Resource requirement obtains module and determines institute for the specified portfolio according to the traffic peak and resource unit
State the number of resource units of business demand;
Resource adjusts module, for the number of resource units according to the business demand, to the allocated of the business
Resource is adjusted.
Resource as described above adjusts device, and the resource requirement obtains module and is specifically used for:
Division processing is carried out to the specified portfolio of the traffic peak and the resource unit, obtains multiple value;
According to the multiple value, the number of resource units of the business demand is determined.
Resource as described above adjusts device, and the resource requirement obtains module and is specifically used for:
According to the traffic peak, the number of resource units of the business demand is determined in the business demand table of comparisons;
Wherein, the corresponding number of resource units of the first portfolio of difference is stored in the business demand table of comparisons.
Resource as described above adjusts device, further includes the specified portfolio acquisition module of resource unit, is used for:
Repeatedly obtain second business of the business when the utilization rate of first resource unit reaches default utilization rate in test
Amount, the first resource unit is any resource unit for distributing to the business in the test;
According to each second portfolio, the specified portfolio of any resource unit is determined.
Resource adjusting method and device provided by the invention, obtain the portfolio of the business under multiple time points first,
Traffic peak is determined in multiple portfolios, further according to the specified portfolio of traffic peak and resource unit, determines that business needs
The number of resource units wanted, finally carries out resource adjustment according to the number of resource units that business needs, and the present invention passes through detection industry
Portfolio of the business under each time point, carries out resource adjustment according to portfolio in time, so that resource adjusts process as user makes
Changed with the variation of portfolio caused by business, resource adjustment process follows hard on the adjustment of portfolio, therefore can be timely
Discovery business use slack problem, and solve the problems, such as this in time, simultaneously because carry out manual operation without operation maintenance personnel,
Thereby reduce cost of labor.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is this hair
Bright some embodiments for those of ordinary skill in the art without any creative labor, can be with
It obtains other drawings based on these drawings.
Fig. 1 is a kind of flow diagram for resource adjusting method that the embodiment of the present invention one provides;
Fig. 2 is a kind of flow diagram of resource adjusting method provided by Embodiment 2 of the present invention;
Fig. 3 is a kind of flow diagram for resource adjusting method that the embodiment of the present invention three provides;
Fig. 4 is a kind of flow diagram for resource adjusting method that the embodiment of the present invention four provides;
Fig. 5 is a kind of structural schematic diagram for resource adjustment device that the embodiment of the present invention five provides;
Fig. 6 is a kind of structural schematic diagram for resource adjustment device that the embodiment of the present invention six provides;
Fig. 7 is a kind of structural schematic diagram for resource adjustment device that the embodiment of the present invention seven provides.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention
In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is
A part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art
Every other embodiment obtained without creative efforts, shall fall within the protection scope of the present invention.
With the development of internet technology, more and more incorporated businesses start to commence business on network, to pass through net
Network provides service for user.Illustratively, the business that the service providers such as incorporated business provide on network can be under video
The business such as load, video on demand, resources sharing, access website.Specifically, when user passes through network access server, user can be with
Carry out the business such as video download, video on demand, resources sharing, access website.Since user runs the industry of carrying on the server
Business has randomness, therefore different time point numbers of users is different, and then causes the portfolio of the business different, which needs
The resource for occupying server is also different.When access user is more, portfolio is larger, and server needs more to the traffic assignments
Resource, i.e. CPU and memory, to guarantee that the business smooth can run, when access user it is less when, portfolio is smaller, services
Device needs the resource less to the traffic assignments, in the case where guaranteeing that the business smooth can be run, saves server resource.
Therefore, the resource that business need to be distributed to server is adjusted in real time.And adjustresources are responsible for by operation maintenance personnel, on the one hand deposit
The problem of lagging, another aspect cost of labor is also higher.
To solve the above problems, the present invention provides a kind of resource adjusting method, be applied in server, on server just
Automatically, timely adjust in the resource of the business of operation, to guarantee the fluency of service operation, and saves cost of labor.
Resource adjusting method provided by the invention is described in detail using specific embodiment below.
Fig. 1 is a kind of flow diagram for resource adjusting method that the embodiment of the present invention one provides, the execution master of this method
Body is that resource adjusts device, which can be can integrate in the server by software or hardware realization, the device, can also be
Server.Which is not limited by the present invention.As shown in Figure 1, this method comprises:
Step 101 obtains current first portfolio of the running business at each time point, in each first portfolio really
Determine traffic peak;
Step 102, according to the specified portfolio of traffic peak and resource unit, determine the resource unit number of business demand
Amount;
Step 103, the number of resource units according to business demand are adjusted the allocated resource of business.
Illustratively, when carrying out resource adjustment to running business using method as described above, at current time
The resource that the business can be called is allocated resource.Illustratively, allocated resource can be initial resource, can also be with
The resource that last time before being current time uses resource adjusting method as described above to obtain.Wherein, initial resource can be with
It is by server according to the server total resources having and the total quantity of the business of carrying, the resource determined for each business;
It can also be the default resource of user's input;Server be can also be according to the history resource usage record of business, for business point
The resource matched.
After business brings into operation, the quantity in the user of a time point access business is indicated using the first portfolio.
Since the first portfolio may change, if executing business using allocated resource always, there may be due to access
The wasting of resources caused by user is reduced, or due to the case where inadequate resource, needing basis caused by accessing user's increase
First portfolio is adjusted allocated resource.Specifically, carrying out resource management for convenience of the resource to server, usually
All by server call resource, are evenly dividing as multiple resource units, when needing to increase or decrease resource, corresponding increasing
Add deduct the number of resource unit that few business can be called.
Specifically, in a step 101, current running business is obtained the of various time points whithin a period of time
One portfolio, illustratively, each time point can within this time uniform intervals, can also integrated distribution within this time
Front half section.First portfolio is at a time point, and multiple users access the portfolio of business generation.When getting each time
After corresponding first portfolio of point, by comparing traffic peak is obtained in all first portfolios, that is, this time is determined
Interior, how many most user access the business.Illustratively, it can use at least one time point.
Illustratively, by taking business is video on demand as an example, before obtaining the first portfolio, setting resource is adjusted first
Interval time is adjusted, and the interval time at time point within the adjustment interval time of resource adjustment, between each time point.So
Afterwards, within one section of resource adjustment interval time, according to preset time point interval time, periodic monitoring user behavior obtains program request
The quantity of user selects the maximum program request number of users of numerical value in the quantity of all the points broadcasting user, adjusts as this section of resource
The quantity of the point broadcasting user of interval time.Optionally, program request number of users can also be obtained in the quantity of multiple broadcasting users
Average value optionally can also be according to the quantity of the point broadcasting user at each time point and each time point, when predicting following any
Between put point broadcasting user quantity, and then using prediction point broadcasting user quantity carry out resource adjustment.
In a step 102, according to the traffic peak obtained in the specified portfolio and step 101 of resource unit, come
Determine the number of resource units of business demand, wherein the specified portfolio of resource unit is, for a resource unit, in resource
The utilization rate of unit reaches specified portfolio when saturation state, when portfolio is not up to specified portfolio, resource unit
Utilization rate is not up to saturated, when portfolio is more than specified portfolio, finishing service that resource unit can not be smooth.
It illustratively, can be with specific reference to the size relation between traffic peak and the specified portfolio of resource unit, really
It has been set to and has guaranteed smooth completion traffic peak, number of resource units required for business.For example, when traffic peak is less than
When specified portfolio, illustrate only to need a resource unit i.e. smooth operation of guaranteed service.When traffic peak is greater than specified
When portfolio, then multiple resource units are needed to guarantee the smooth operation of business, specific combinable fold values determine required money
Source unit quantity.
It illustratively, can also be according to the table of comparisons of preset traffic peak and required number of resource units, according to not
Same traffic peak determines the quantity of the resource unit needed.
Illustratively, when the specified portfolio of resource unit is 2000, by taking business is VOD service as an example, at certain
When the traffic peak determined in one period is 5000, by comparing 5000 and 2000, it can be seen that before guaranteeing fluency
It puts, each resource unit is only capable of sharing 2000 portfolios, at least needs 3 resource units to guarantee VOD service
Fluency.
Specifically, in step 103, according to the number of resource units of the business demand got in step 102, to business
Allocated resource be adjusted.
Specifically, the allocated number of resource units of business can be determined according to the allocated resource of business, then will
Number of resource units Y needed for the allocated number of resource units X and business of business is compared.For example, when X is less than Y,
Illustrate that allocated number of resource units is less, then should increase resource unit, to guarantee the smooth operation of business;When X is greater than Y
When, illustrate that allocated number of resource units is more, then resource unit should be reduced, to avoid waste of resource;When X is equal to Y, then
Without carrying out resource adjustment.
Resource adjusting method provided by the invention obtains the portfolio of the business under multiple time points first, in multiple industry
Traffic peak is determined in business amount, further according to the specified portfolio of traffic peak and resource unit, determines the money that business needs
Source unit quantity finally carries out resource adjustment according to the number of resource units that business needs, and the present invention is by detection business each
Portfolio under time point carries out resource adjustment according to portfolio in time, so that resource adjusts process as user uses business
Caused by portfolio variation and change, resource adjustment process follows hard on the adjustment of portfolio, therefore can timely find
Business uses slack problem, and solves the problems, such as this in time, simultaneously because carrying out manual operation without operation maintenance personnel, and then drops
Low cost of labor.
Particularly, when portfolio is slowly increased with the time, operation maintenance personnel or user can not have found that business uses in time
Fluency go wrong, resource adjustment cannot be carried out immediately when problem is more slight, serious fluency can only occurring
When problem, just passively solve the problems, such as.But resource adjusting method provided by the invention, the only adjustment by being adjusted according to resource
Interval time, which is repeated several times, to be executed, and can be found the increase of portfolio in time and be carried out the adjustment of resource.
Further, on the basis of embodiment shown in Fig. 1, for the allocated resource to business in step 103
It being adjusted, is described in detail, Fig. 2 is a kind of flow diagram of resource adjusting method provided by Embodiment 2 of the present invention,
As shown in Figure 2, comprising:
Step 201 obtains current first portfolio of the running business at each time point, in each first portfolio really
Determine traffic peak;
Step 202, according to the specified portfolio of traffic peak and resource unit, determine the resource unit number of business demand
Amount;
Step 203 judges whether the number of resource units of business demand is equal to allocated number of resource units;If it is not,
Then follow the steps 204;If so, terminating without adjustment;
Step 204 is adjusted allocated number of resource units, so that the number of resource units for distributing to business reaches
To the number of resource units of business demand.
Specifically, step 201 and step 202 in embodiment illustrated in fig. 1 step 101 and step 102 it is identical, the present invention
It repeats no more.
Specifically, judging the number of resource units of business demand and the allocated resource of business when carrying out resource adjustment
Whether element number is equal, if equal, it is smaller to illustrate that portfolio changes, without carrying out resource adjustment, if unequal,
Illustrate changing greatly for portfolio generation, resource adjustment need to be carried out.Illustratively, server can be distributed to the resource list of business
First quantity is modified, so that the number of resource units phase of the modified number of resource units for distributing to business and business demand
Together.
It optionally, can also be in the number of resource units for getting business demand, by the number of resource units of business demand
The allocated number of resource units of business is subtracted, number differences are obtained.The money that business is is distributed to according to number differences adjustment
Source unit quantity.When number differences are positive, then it represents that the number of resource units of business demand resource unit more allocated than business
Quantity is more, and more numbers is number differences.Such as when number differences be 1, indicate that currently allocated number of resource units compares industry
The number of resource units of business demand is 1 few, therefore increases by 1 resource unit for business.When number differences are negative, then it represents that business needs
The number of resource units asked number of resource units more allocated than business is few.
Illustratively, in any of the above-described embodiment, the adjustment interval time that can be adjusted according to resource, resource tune is repeated
It is had suffered journey, what current time modified distributes to the number of resource units of business, the adjustment interval of as next resource adjustment
Allocated number of resource units in time.
Shorter when the adjustment interval time of resource adjustment, then resource adjustment is more timely, more can guarantee that user uses business
Fluency, optionally, time point can be evenly distributed on resource adjustment adjustment interval time in, can also integrated distribution in resource tune
The front of whole adjustment interval time.
Optionally, the stock number of each resource unit can also be different, and be business reorganization resource when each resource unit difference
When, it can first determine that and need increased stock number, then to determine the number for needing increased all kinds of resource units.
Optionally, on the basis of Fig. 1 or embodiment illustrated in fig. 2, before carrying out resource adjustment, resource unit need to be determined
Specified portfolio, to facilitate when carrying out resource adjustment as the appropriate number of resource unit of traffic assignments.Below using specific
The determination of the specified portfolio of resource unit is described in detail in embodiment.Fig. 3 is one kind that the embodiment of the present invention three provides
The flow diagram of resource adjusting method, as shown in figure 3, this method comprises:
Step 301 repeatedly obtains business in test when the utilization rate of first resource unit reaches default utilization rate
Second portfolio, first resource unit are any resource unit for business of distributing to;
Step 302, according to each second portfolio, determine the specified portfolio of any resource unit.
Specifically, before carrying out resource adjustment the volume of resource unit need to be obtained according to above-mentioned steps 301 and step 302
Determine portfolio.
Illustratively, in step 301, a first resource unit is determined in the server, only by the first resource list
Member executes the business in test, by measuring to the first resource unit, to obtain the specified business of any resource unit
Amount.For first resource unit, the portfolio of business is gradually increased, reaches default utilization rate in the resource utilization of first resource
When, record second portfolio at current time.Specifically, resource can be completed by using resource unit utilization rate statistic device
The real-time statistics of unit utilization rate.Above-mentioned steps are performed a plurality of times, obtain multiple second portfolios.Illustratively, the second portfolio
The corresponding portfolio of business to test the business corresponding portfolio of business at runtime, when the first portfolio is actual motion.
Illustratively, default utilization rate can be 100%.
Specifically, in step 302, according to each second portfolio, determining the specified portfolio of first resource unit.Example
Property, each second portfolio can be averaged, the specified portfolio as first resource unit.
It is exemplary, in conjunction with Fig. 3, the method for obtaining specified portfolio is described in detail.Fig. 4 is the embodiment of the present invention four
A kind of flow diagram of the resource adjusting method provided;As shown in figure 4, this method comprises:
Step 401 repeatedly obtains business in test when the utilization rate of first resource unit reaches default utilization rate
Second portfolio, first resource unit are any resource unit for business of distributing to;
Step 402 carries out average value processing to each second portfolio, obtains portfolio mean value;
Step 403, in each second portfolio, the determining third business for being less than preset value with the difference of portfolio mean value
Amount;
Step 404 carries out average value processing to each third portfolio, determines the specified portfolio of any resource unit.
Specifically, step 401 is identical as the step 301 in embodiment illustrated in fig. 3, the present invention is repeated no more.
Specifically, first place can be filtered to each second portfolio after getting multiple second portfolios in step 401
Reason, to filter out because of operation error, measurement error caused by inaccurate measurement data, to improve the measurement essence of specified portfolio
Degree.
Specifically, average value processing first can be carried out to each second portfolio, portfolio mean value is obtained, then in all second industry
In business amount, by each second portfolio compared with the progress of portfolio mean value is worst, the determining difference with portfolio mean value is less than default
The third portfolio of value.I.e. in each second portfolio, filters out and differ lesser second portfolio conduct with portfolio mean value
Third portfolio will differ biggish second portfolio and filter out.
Then, average value processing then to each third portfolio is carried out, using the mean value of obtained third portfolio as any money
The specified portfolio of source unit.
Optionally, also filtration treatment can be performed a plurality of times after obtaining third portfolio, to improve the standard of specified portfolio
True property.
Further, based on any of the above embodiments, for the resource list of the determination business demand in step 102
First quantity, the present invention provide following feasible calculation method:
A kind of feasible computational algorithm:
Division processing is carried out to the specified portfolio of traffic peak and resource unit, obtains multiple value;According to multiple value,
Determine the number of resource units of business demand.
Specifically, division processing is carried out to the specified portfolio B of A and resource unit after getting traffic peak A,
Obtain multiple value n, i.e. A=nB.Then, the number of resource units that business demand is determined according to n, when n is integer, n, that is, rigid
It is well the number of resource units of business demand.When n is decimal, the integer part resource unit of n is only relied on, can not achieve
The smooth operation of business.Therefore need to round up to n, N is obtained, N is then the number of resource units of business demand.
Illustratively, when business be VOD service when, when A be 5000 when, when B be 2000,5000 be 2000 2.5
Times.Total specified portfolio of two resource units is 4000, still less than 5000, is unable to satisfy current portfolio, three resources
Total specified portfolio of unit is 6000, is greater than 5000, can satisfy current portfolio.
Another feasible calculation method:
According to traffic peak, the number of resource units of business demand is determined in the business demand table of comparisons;Wherein, business
The corresponding number of resource units of the first portfolio of difference is stored in the demand table of comparisons.
Specifically, when acquiring traffic peak A, it can be according to the business demand table of comparisons stored in server, really
Determine the number of resource units N of business demand, wherein the corresponding money of the first portfolio A of difference is stored in the business demand table of comparisons
Source unit quantity N.
Illustratively, a kind of possible business demand table of comparisons is as shown in the table:
Illustratively, when A is 2500, the number of resource units N for the business demand that can be directly looked into according to upper table is 2.Work as A
It is each resource unit of traffic assignments 4 when greater than 6000, with limitation when portfolio is excessive, hence it is evident that when abnormal, the industry will not be given
Business distributes excessive resource, in order to avoid influence the operation of other business on server.Illustratively, it can be transported according in server
The total resources of capable business and server set the total resources quantity of units that each business can be called.Specifically, the acquisition methods of the table
It can refer to a kind of feasible calculation method.By the way that the above-mentioned table of comparisons to be stored directly in server, can will acquire business is needed
The process for the number of resource units asked is reduced to comparison procedure by division process, greatly reduces calculating process.
Optionally, above-mentioned resource adjusting method applies also for the adjustment for the resource that each business occupies its each subservice.
For example, VOD service further comprises that video plays and video download online, it can be according to the sub- industry of current each subservice
Business amount is online broadcasting and downloading dynamic allocation of resources.
Another aspect of the present invention provides a kind of resource adjustment device, to execute resource adjustment side provided by the above embodiment
Method, technical characteristic having the same and technical effect, the present invention repeat no more.The device can be applied to server, can also be with
For server, wherein the resource of server is divided into multiple resource units.
Fig. 5 is a kind of structural schematic diagram for resource adjustment device that the embodiment of the present invention five provides, as shown in figure 5, the dress
It sets and includes:
Traffic peak obtains module 501, for obtaining current first portfolio of the running business at each time point,
Traffic peak is determined in each first portfolio;
Resource requirement obtains module 502 and determines business for the specified portfolio according to traffic peak and resource unit
The number of resource units of demand;
Resource adjusts module 503, for the number of resource units according to business demand, to the allocated resource of business into
Row adjustment.
Optionally, resource requirement obtains module 502 and is specifically used for:
Division processing is carried out to the specified portfolio of traffic peak and resource unit, obtains multiple value;According to multiple value,
Determine the number of resource units of business demand.
Optionally, resource requirement obtains module 502 and is specifically used for:
According to traffic peak, the number of resource units of business demand is determined in the business demand table of comparisons;Wherein, business
The corresponding number of resource units of the first portfolio of difference is stored in the demand table of comparisons.
Optionally, on the basis of embodiment shown in Fig. 5, Fig. 6 is a kind of resource adjustment that the embodiment of the present invention six provides
The structural schematic diagram of device is used for as shown in fig. 6, the specified portfolio that the device further includes resource unit obtains module 504:
Repeatedly obtain second business of the business when the utilization rate of first resource unit reaches default utilization rate in test
Amount, first resource unit are any resource unit for distributing to the business in test;According to each second portfolio, any money is determined
The specified portfolio of source unit.
Optionally, the specified portfolio of resource unit obtains module 504 and is specifically used for:
Repeatedly obtain second business of the business when the utilization rate of first resource unit reaches default utilization rate in test
Amount, first resource unit are any resource unit for distributing to the business in test;
Average value processing is carried out to each second portfolio, obtains portfolio mean value;
In each second portfolio, the determining third portfolio for being less than preset value with the difference of portfolio mean value;
Average value processing is carried out to each third portfolio, determines the specified portfolio of any resource unit.
Optionally, on the basis of Fig. 5 or embodiment illustrated in fig. 6, Fig. 7 is a kind of resource that the embodiment of the present invention seven provides
The structural schematic diagram of device is adjusted, as shown in fig. 7, resource adjustment module 503 specifically includes:
Judging unit 5031, for judging whether the number of resource units of business demand is equal to allocated resource unit number
Amount;
Adjustment unit 5032, for being adjusted to allocated number of resource units, so that distributing to when unequal
The number of resource units of business reaches the number of resource units of business demand.
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 (7)
1. a kind of resource adjusting method, which is characterized in that be applied to server, the resource of the server is divided into multiple moneys
Source unit, comprising:
Current first portfolio of the running business at each time point is obtained, most great cause is determined in each first portfolio
Business amount;
According to the specified portfolio of the traffic peak and resource unit, the number of resource units of the business demand is determined;
According to the number of resource units of the business demand, the allocated resource of the business is adjusted;
The specified portfolio according to the traffic peak and resource unit, determines the resource unit number of the business demand
Before amount, further includes:
Repeatedly obtain second portfolio of the business when the utilization rate of first resource unit reaches default utilization rate in test, institute
Stating first resource unit is any resource unit for distributing to the business in the test;
According to each second portfolio, the specified portfolio of any resource unit is determined;
It is described according to each second portfolio, determine the specified portfolio of any resource unit, comprising:
Average value processing is carried out to each second portfolio, obtains portfolio mean value;
In each second portfolio, the determining third portfolio for being less than preset value with the difference of the portfolio mean value;
Average value processing is carried out to each third portfolio, determines the specified portfolio of any resource unit.
2. the method according to claim 1, wherein the volume according to the traffic peak and resource unit
Determine portfolio, determine the number of resource units of the business demand, comprising:
Division processing is carried out to the specified portfolio of the traffic peak and the resource unit, obtains multiple value;
According to the multiple value, the number of resource units of the business demand is determined.
3. the method according to claim 1, wherein the volume according to the traffic peak and resource unit
Determine portfolio, determine the number of resource units of the business demand, comprising:
According to the traffic peak, the number of resource units of the business demand is determined in the business demand table of comparisons;Wherein,
The corresponding number of resource units of the first portfolio of difference is stored in the business demand table of comparisons.
4. method according to any one of claims 1 to 3, which is characterized in that the resource according to the business demand
Element number is adjusted the allocated resource of the business, comprising:
Judge whether the number of resource units of the business demand is equal to allocated number of resource units;
If it is not, being then adjusted to allocated number of resource units, so that the number of resource units for distributing to the business reaches
To the number of resource units of the business demand.
5. a kind of resource adjusts device, which is characterized in that be applied to server, the resource of the server is divided into multiple moneys
Source unit, comprising:
Traffic peak obtains module, for obtaining current first portfolio of the running business at each time point, in each institute
It states and determines traffic peak in the first portfolio;
Resource requirement obtains module and determines the industry for the specified portfolio according to the traffic peak and resource unit
The number of resource units of business demand;
Resource adjusts module, for the number of resource units according to the business demand, to the allocated resource of the business
It is adjusted;
The specified portfolio of resource unit obtains module, is used for:
Second portfolio of the business when the utilization rate of first resource unit reaches default utilization rate in test is repeatedly obtained, the
One resource unit is any resource unit for distributing to the business in test;
Average value processing is carried out to each second portfolio, obtains portfolio mean value;
In each second portfolio, the determining third portfolio for being less than preset value with the difference of portfolio mean value;
Average value processing is carried out to each third portfolio, determines the specified portfolio of any resource unit.
6. device according to claim 5, which is characterized in that the resource requirement obtains module and is specifically used for:
Division processing is carried out to the specified portfolio of the traffic peak and the resource unit, obtains multiple value;
According to the multiple value, the number of resource units of the business demand is determined.
7. device according to claim 5, which is characterized in that the resource requirement obtains module and is specifically used for:
According to the traffic peak, the number of resource units of the business demand is determined in the business demand table of comparisons;Wherein,
The corresponding number of resource units of the first portfolio of difference is stored in the business demand table of comparisons.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610454298.2A CN106126339B (en) | 2016-06-21 | 2016-06-21 | Resource adjusting method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610454298.2A CN106126339B (en) | 2016-06-21 | 2016-06-21 | Resource adjusting method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106126339A CN106126339A (en) | 2016-11-16 |
CN106126339B true CN106126339B (en) | 2019-07-30 |
Family
ID=57471348
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610454298.2A Active CN106126339B (en) | 2016-06-21 | 2016-06-21 | Resource adjusting method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106126339B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107844376A (en) * | 2017-11-21 | 2018-03-27 | 北京星河星云信息技术有限公司 | Resource allocation method, computing system, medium and the server of computing system |
CN111352639A (en) * | 2019-12-16 | 2020-06-30 | 深圳市智微智能软件开发有限公司 | After-sale system upgrading method and system |
CN111666130A (en) * | 2020-06-03 | 2020-09-15 | 百度在线网络技术(北京)有限公司 | Container balanced deployment method and device, electronic equipment and storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103442257A (en) * | 2013-08-15 | 2013-12-11 | 青岛海信传媒网络技术有限公司 | Method, device and system for achieving flow resource management |
CN103490956A (en) * | 2013-09-22 | 2014-01-01 | 杭州华为数字技术有限公司 | Self-adaptive energy-saving control method, device and system based on traffic predication |
CN105592465A (en) * | 2014-10-21 | 2016-05-18 | 杭州华为数字技术有限公司 | Wireless resource allocation method and wireless network controller |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070180451A1 (en) * | 2005-12-30 | 2007-08-02 | Ryan Michael J | System and method for meta-scheduling |
US20160055035A1 (en) * | 2014-08-14 | 2016-02-25 | Raytheon Company | Multiple simultaneous request resource management |
-
2016
- 2016-06-21 CN CN201610454298.2A patent/CN106126339B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103442257A (en) * | 2013-08-15 | 2013-12-11 | 青岛海信传媒网络技术有限公司 | Method, device and system for achieving flow resource management |
CN103490956A (en) * | 2013-09-22 | 2014-01-01 | 杭州华为数字技术有限公司 | Self-adaptive energy-saving control method, device and system based on traffic predication |
CN105592465A (en) * | 2014-10-21 | 2016-05-18 | 杭州华为数字技术有限公司 | Wireless resource allocation method and wireless network controller |
Also Published As
Publication number | Publication date |
---|---|
CN106126339A (en) | 2016-11-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106453125B (en) | A kind of remote service calling SiteServer LBS based on real time load rate | |
CN107329837B (en) | Load balancing method and unit and distributed NewSQL database system | |
Rao et al. | QoS guarantees and service differentiation for dynamic cloud applications | |
CN107291546A (en) | A kind of resource regulating method and device | |
Zhang et al. | Online resource scheduling under concave pricing for cloud computing | |
US20090055835A1 (en) | System and Method for Managing License Capacity in a Telecommunication Network | |
CN106126339B (en) | Resource adjusting method and device | |
CN107291545A (en) | The method for scheduling task and equipment of multi-user in computing cluster | |
WO2019135963A1 (en) | A system and method for scheduling workload based on a credit-based mechanism | |
US11496413B2 (en) | Allocating cloud computing resources in a cloud computing environment based on user predictability | |
CN111143143B (en) | Performance test method and device | |
US7225223B1 (en) | Method and system for scaling of resource allocation subject to maximum limits | |
CN107483351A (en) | A kind of current-limiting method and device | |
US11360999B2 (en) | Computer-implemented method for managing inventory allocations | |
CN111045808B (en) | Distributed network task scheduling method and device | |
CN111985851B (en) | Bank outlet resource scheduling method and device | |
CN106534302A (en) | Multi-task demand service combination method and system | |
US20150146521A1 (en) | Dynamic resource pooling and trading mechanism in network virtualization | |
Meskar et al. | Fair multi-resource allocation in mobile edge computing with multiple access points | |
US10812278B2 (en) | Dynamic workload capping | |
CN107370783B (en) | Scheduling method and device for cloud computing cluster resources | |
CN103297511A (en) | Client/ server scheduling method and system under highly dynamic environment | |
CN108228346A (en) | service system and its control method | |
CN106302241A (en) | Online message array dispatching method and device | |
CN114726860A (en) | Load balancing system and load balancing method for streaming media transmission |
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 |