CN105912436A - Method and device for predicting system computing resource based on exponential smoothing prediction - Google Patents
Method and device for predicting system computing resource based on exponential smoothing prediction Download PDFInfo
- Publication number
- CN105912436A CN105912436A CN201510595120.5A CN201510595120A CN105912436A CN 105912436 A CN105912436 A CN 105912436A CN 201510595120 A CN201510595120 A CN 201510595120A CN 105912436 A CN105912436 A CN 105912436A
- Authority
- CN
- China
- Prior art keywords
- time period
- computation
- data
- monitoring
- value
- 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.)
- Pending
Links
Abstract
Embodiments of the invention provide a method and a device for predicting system computing resources based on exponential smoothing prediction. The method comprises: a central server continuously receiving a plurality of pieces of monitoring data in a first time period before a current moment, each piece of the monitoring data being data obtained to monitor system computing resources of the server in each monitoring cycle; the central server establishing a computing resource prediction model according to the smoothing values of a single exponent and a quadratic exponent of the plurality of pieces of monitoring data received in the first time period; according to the model, predicting the application amount of system computing resource of the server at a certain moment in a second time period after the current moment, and showing a prediction result. Through collection and prediction of the monitoring data, the method helps a scheduling system to avoid a congestion peak, so as to reduce probability of overtime or failure of a task. The method and the device have great help for using computing resources rationally and ensuring stability of data calculation.
Description
Technical field
The present embodiments relate to distributed computing technology field, particularly relate to a kind of based on exponential smoothing
The calculating resource prediction method of prediction and system.
Background technology
In big data dispatch system, run hundreds and thousands of tasks every day, often in some moment
Appearance server CPU or internal memory load higher thus affect the execution of calculating task.Current monitor
System can obtain the near real-time service condition of resource by statistics, but in a practical situation, not only
Being only the resource service condition at " upper a moment ", the possible occupied situation of " lower a moment " resource is often
More meaningful to dispatching patcher.Big data calculate task and typically require the operation long period, it is also desirable to disappear
Consume substantial amounts of calculating resource, if dispatching patcher can predict cluster " lower a moment " before job run
Resource whether disclosure satisfy that its run needs, thus decide whether operation, then can avoid undoubtedly
Occur causing, owing to calculating inadequate resource, the situation that operation is failed.
By collection and the prediction of monitoring data, it is possible to help dispatching patcher to avoid the peak that blocks up, thus
The probability that minimizing task is overtime or failed.Resource is calculated for Appropriate application, it is ensured that data calculate
Stability has very great help.
Summary of the invention
The embodiment of the present invention provides a kind of system resources in computation Forecasting Methodology based on Smoothing Prediction and dress
Put, in order to solve in prior art due to calculate inadequate resource and cause the situation that operation is failed.
The embodiment of the present invention provides a kind of system resources in computation Forecasting Methodology based on Smoothing Prediction, bag
Include:
Central server persistently receives multiple monitoring data in the first time period before current time,
Each monitoring data be in each monitoring cycle system resources in computation situation to server be monitored and
The data obtained, specifically include the use of system resources in computation within each monitoring cycle of described server
Amount, described first time period includes multiple described monitoring cycle;
Described central server is according to the one of the plurality of monitoring data received in described first time period
Secondary exponential smoothing value and double smoothing value, set up and calculate resources model;
According to described calculating resources model, it was predicted that certain a period of time in the second time period after current time
Carve the usage amount of the system resources in computation of described server, and the result of described prediction is shown.
The embodiment of the present invention provides a kind of system resources in computation prediction means based on Smoothing Prediction, bag
Include:
Data reception module, central server persistently receives in the first time period before current time
Multiple monitoring data, each monitoring data are each monitoring cycle interior system resources in computation to server
The data that situation is monitored and obtains, specifically including described server is within each monitoring cycle
Statistics calculates the usage amount of resource, and described first time period includes multiple described monitoring cycle;
Data processing module, described central server is described many according to receive in described first time period
The single exponential smoothing value of individual monitoring data and double smoothing value, set up and calculate resources model;;
Prediction module, according to described calculating resources model, it was predicted that the second time after current time
The usage amount of the system resources in computation of server described in a certain moment in section;
Display module, is shown the result of described prediction.
The system resources in computation Forecasting Methodology based on Smoothing Prediction of embodiment of the present invention offer and device,
By the time series algorithm of data mining and monitoring data are combined, it was predicted that the meter of cluster server
Calculate resource behaviour in service, it is possible to help dispatching patcher to avoid the peak that blocks up, thus decrease task time-out or
The probability that person is failed, has the biggest lifting in terms of Appropriate application calculates resource and ensures data stability.
Accompanying drawing explanation
In order to be illustrated more clearly that the embodiment of the present invention or technical scheme of the prior art, below will be to reality
Execute the required accompanying drawing used in example or description of the prior art to be briefly described, it should be apparent that under,
Accompanying drawing during face describes is some embodiments of the present invention, for those of ordinary skill in the art,
On the premise of not paying creative work, it is also possible to obtain other accompanying drawing according to these accompanying drawings.
Fig. 1 is the techniqueflow chart of the embodiment of the present invention one;
Fig. 2 is the techniqueflow chart of the embodiment of the present invention two;
Fig. 3 is the techniqueflow chart of the embodiment of the present invention three;
Fig. 4 is the techniqueflow chart of the embodiment of the present invention four;
Fig. 5 is the apparatus structure schematic diagram of the embodiment of the present invention five;
Fig. 6 is the prediction curve schematic diagram of application example of the present invention.
Detailed description of the invention
For making the purpose of the embodiment of the present invention, technical scheme and advantage clearer, below in conjunction with this
Accompanying drawing in bright embodiment, is clearly and completely described the technical scheme in the embodiment of the present invention,
Obviously, described embodiment is a part of embodiment of the present invention rather than whole embodiments.Based on
Embodiment in the present invention, those of ordinary skill in the art are obtained under not making creative work premise
The every other embodiment obtained, broadly falls into the scope of protection of the invention.
Embodiment one
Fig. 1 is the techniqueflow chart of the embodiment of the present invention one, and in conjunction with Fig. 1, the embodiment of the present invention is mainly wrapped
Include the steps:
Step 101: central server persistently receives multiple in the first time period before current time
Monitoring data;
Each monitoring data are that each monitoring cycle interior system resources in computation situation to server is supervised
The data controlled and obtain, specifically include described server system resources in computation within each monitoring cycle
Usage amount, described first time period includes multiple described monitoring cycle;
In the embodiment of the present invention, locator detector the most can be installed on the server needing monitoring
Thus realize using the situation of system resources in computation to be monitored server, certain present invention is not limited to
The mode of locator.
Time series in data mining is excavated the data referred to from existing time series and is found out statistics rule
Rule, the data handled by time series excavation all can be labeled with time tag, and these data have reacted a certain
Things variable condition over time or degree, according to the variation tendency of data, can be by historical data
Go to speculate following data.
Therefore, in the embodiment of the present invention, central server is held in the first time period before current time
Multiple monitoring data that continuous pick-up probe sends, as historical data, look for from these historical datas
Statistics returns rule can realize the data variation trend in the second time period after current time.
Described in the embodiment of the present invention, system resources in computation includes: central processing unit (CPU), internal memory,
The system datas such as disk, transmission control protocol (TCP) connection.
Step 102: described central server is according to the plurality of prison received in described first time period
The single exponential smoothing value of control data and double smoothing value, set up and calculate resources model;
The embodiment of the present invention use Secondary Exponential Smoothing Method set up the forecast model of data, art technology
Personnel know, and Secondary Exponential Smoothing Method is the method that single exponential smoothing value is made exponential smoothing again.
It can not be predicted individually, it is necessary to coordinates with Single Exponential Smoothing, sets up the mathematical model of prediction,
Then mathematical model is used to determine predictive value.
Step 103: according to described calculating resources model, it was predicted that the second time after current time
The usage amount of the system resources in computation of server described in a certain moment in section, and the result of described prediction is entered
Row is shown.
Embodiment two
Fig. 2 is the techniqueflow chart of the embodiment of the present invention one, and in conjunction with Fig. 2, the embodiment of the present invention is further
Can be refined as the steps:
Step 201: install detector on every server needing monitoring, monitor described server meter
Calculating the usage amount of resource, wherein said detector is to monitor periodic duty;
The composition of server includes processor, hard disk, internal memory, system bus etc., and therefore the present invention implements
In example, the usage amount monitoring described server calculating resource mainly includes CPU, internal memory, disk, TCP
Connect nearly 40 kinds of system datas such as number.
Step 202: the monitoring data of described usage amount are sent back central server by described detector;
In the embodiment of the present invention, the monitoring cycle arranging detector is one minute, the most described detector every point
Clock run once, each server in cluster by call central server provide REST API, with
Detection data are sent back central server by HTTP mode, and the monitoring cycle of certain embodiment of the present invention is not
It is only limitted to one minute once.
Step 203: described central server receives the described monitoring data of described detector transmission and with system
The described monitoring data received are added up by the meter cycle;
In the embodiment of the present invention, described central server receives described detector by the way of Rest API
The various monitoring data sended over, in order to prevent Single Point of Faliure, described central server build mode
Have employed the scheme of LVS+Nginx two-shipper load balancing cluster.Data base have employed MongoDB tri-
Machine cluster, it is ensured that data storage high-performance and without Single Point of Faliure.Central server has powerful handling up
Ability, query rate QPS per second (Query Per Seconds) reaches for 20,000/second.
The Rest API used in the embodiment of the present invention is the internet, applications API design of a set of comparative maturity
Theory, it provides unified resource access interface, simplifies the integrated cost between application.
Server in cluster generally up to 300 multiple servers, every station server is all substantial amounts of in generation
Monitoring data.The whole cluster being made up of hundreds of station server is taken as a superserver, the present invention
Using every 5 minutes CPU to cluster in embodiment, the data such as internal memory are added up.By one hour
Being divided into 12 subregions, the previous 5 minutes subregions every time taking current time calculate.This
The monitoring data that individual server is sent by sample at times are added up, it is possible to make whole statistic processes real-time
Property strengthen, the data volume that secondly central server disposably processes substantially reduces, and therefore the speed of service is faster,
The most also provide the foundation for realizing real-time early warning.Certainly, the described statistics week of the embodiment of the present invention
Phase is not limited in five minutes, it is also possible to rule of thumb or the performance of central server is configured.
Step 204: described central server is according to the described monitoring data in described first time period, meter
Calculate single exponential smoothing value corresponding to described monitoring data and the double smoothing value in each detection moment;
Described double smoothing is a kind of Time Series Forecasting Methods, and its major function is exactly from a sequence
Data in row (Sequence) find out statistical law, obtain a certain things variable condition over time
Or degree, according to the variation tendency of data, can go to speculate following number by history and current data
According to.
A kind of Time Series Analysis Forecasting method that exponential smoothing grows up on the basis of moving average method.
It uses average weighted method actual value and smooth value to be combined, and builds sequence prediction mould by smooth value
Type, it is achieved forecast function.Wherein, the formula of single exponential smoothing prediction is as follows:
St (1)=α × yt+(1-α)×(St-1) formula 1
Wherein, ytT monitoring data actual value, in embodiments of the present invention centered by server system
The t system resources in computation usage amount that meter obtains, StIt it is t system resources in computation usage amount
Smooth value, St-1It is the smooth value of t-1 moment system resources in computation usage amount, α smoothing constant, its
Span is [0,1].
Formula 1 utilizes smooth value and the t system resources in computation of t-1 moment system resources in computation usage amount
The actual value of usage amount calculates the smooth value of t system resources in computation usage amount;α is smoothing factor,
Its value is closer to 1, then remote time data is the least for the impact of system resources in computation usage amount result of calculation;
Its value closer to 0, then affects the biggest.
Single exponential smoothing prediction is suitable for and does not has trend and seasonal sequence.If data sequence is deposited
In certain trend, then needing the basis at an exponential forecasting to smooth, concrete formula is as follows again:
St (1)=α × yt+(1-α)×(St-1)(1)
St (2)=α × St (1)+(1-α)×(St-1)(2)Formula 2
In formula 2, α is smoothing constant, and span is [0,1];T is the t detection moment, and t takes
It is worth in described first time period last prison before first monitoring mechanical periodicity to current time
The control cycle;ytIt is the monitoring data in the t detection moment;St (1)It is to monitor number described in the t detection moment
According to single exponential smoothing value;St (2)It it is the double smoothing value monitoring data described in the t detection moment.
Institute
State the multiple S in the very first timet (2)The seasonal effect in time series variation tendency of composition can represent described monitoring
The described variation tendency of data, such that it is able to set up forecast model according to described variation tendency to carry out described
The prediction of described system resources in computation usage amount in two time periods.
Step 205: described central server is according to the plurality of prison received in described first time period
The single exponential smoothing value of control data and double smoothing value, set up and calculate resources model;
Input actual value and the factor alpha of a seasonal effect in time series system resources in computation usage amount, just can lead to
Cross above-mentioned formula 1 and formula 2 calculates the S in each momentt (1)Value and St (2)Value, and then dope t+m
The predictive value of the system resources in computation usage amount in moment.Predictor formula is as follows:
Ft+m=st+m×bt
st=2St (1)–St (2)
bt=(α/1-α) × (St (1)-St (2)) formula 3
In formula 3, wherein, t is last the detection moment in described first time period, and t+m is institute
State the m-th moment in the second time period, Ft+mFor system resources in computation usage amount described in the m-th moment
Predictive value, stAnd btFor model parameter, wherein, St (1)It is system-computed money described in the t detection moment
The single exponential smoothing value of source usage amount, St (2)It is that system resources in computation described in the t detection moment uses
The double smoothing value of amount, α is smoothing constant, and the span of α is [0,1].
Wherein, the value of smoothing factor α is between [0,1], and the principle that concrete value selects is to make predictive value
And mean square error and average absolute percent error between actual value are minimum.It should be noted that in reality
During prediction, it is necessary to consider the feature of time series data itself: if time series has irregular fluctuating
Change, but long-term trend are close to a stability constant, and α value is typically small;If time series has fast
Speed significantly dynamic trend, then α should take higher value;If time series variation is slow, also should select relatively
Little value.
Step 206: according to described calculating resources model to the second time after described current time
In section, described in a certain moment, the usage amount of system resources in computation is predicted.
Embodiment three
Fig. 3 is the schematic diagram that embodiment of the present invention Short-term Forecasting Model is set up, and in conjunction with Fig. 3, the present invention is real
Execute example and farther include following steps:
Step 301: described first time period is set as X hour before current time, at every need
Detector is installed on server to be monitored, monitors described server system and calculate the usage amount of resource, its
Middle X belongs to the first scope;
In the embodiment of the present invention, following example can be lifted: described detector is installed on a certain server to not
In coming 15 minutes, the occupancy volume of CPU is predicted, and described first time period can be set as 1 hour
(X=1), the described monitoring cycle is set to 1 minute, then within the described very first time, described in genuinely convinced
Business device will receive 60 the CPU usage amount data values sent from described a certain server.
It should be noted that described first scope is determined by experience, the embodiment of the present invention does not limit
The upper lower limit value of described first scope.If desired described second time period predicted is longer, the most correspondingly will
Described first time period arranges longer therewith, to ensure that the variation tendency of history monitoring data can be just
Really following monitoring data trend is made correct judgement.
Step 302: the monitoring data of described usage amount are sent back central server by described detector;
Accept the example of previous step, in the embodiment of the present invention, detector operation per minute can be set once,
Each server in cluster, will in HTTP mode by calling the REST API that central server provides
Detection data send back central server, and the monitoring cycle of certain embodiment of the present invention is not limited in one point
Clock is once.
Step 303: described central server receives the described monitoring data of described detector transmission and with system
The described monitoring data received are added up by the meter cycle;
Accept the example of previous step, the embodiment of the present invention uses and makes every 5 minutes CPU to cluster
Consumption is added up.One hour is divided into 12 subregions, takes previous the 5 of current time every time
Minute subregion calculates.The monitoring data sent individual server the most at times are added up, energy
Enough making whole statistic processes real-time strengthen, the data volume that secondly central server disposably processes is notable
Reducing, therefore the speed of service is faster, the most also provides the foundation for realizing real-time early warning.Certainly,
The described measurement period of the embodiment of the present invention is not limited in five minutes, it is also possible to rule of thumb or center
The performance of server is configured.
Step 304: described central server is according to the described monitoring data in described first time period, meter
Calculate single exponential smoothing value corresponding to described monitoring data and the double smoothing value in each detection moment;
Accepting the example of previous step, described second time period is 15 minutes, utilizes formula 1 and formula 2
Calculate St (1)And St (2), in i.e. calculating previous hour of current time, each minute CPU usage amount is once
Exponential smoothing value and double smoothing value, there are 60 time dependent St (1)Value and 60 with
The S of time changet (2)Value.
Step 305: described central server is according to one of the described monitoring data in described first time period
Secondary exponential smoothing value and double smoothing value, set up and calculate resources model, to described current time
In the second time period afterwards, the usage amount of described system resources in computation is predicted.
According to formula 3, taking m=1, the predictive value of first minute in described second time period is Ft+m=F61、
Taking m=2, the predictive value of second minute in described second time period is Ft+m=F62, take m=15, described
The predictive value of the 15th minute in the second time period is Ft+m=F75.I.e. can get currently by above calculating
The prediction data of CPU usage amount in after time 15 minutes, if usage amount is sufficient, then scheduler task is just
Often run;If inadequate, change scheduler task direction, avoid calculating resource and block up peak.
In the embodiment of the present invention, to system resources in computation usage amount, whether abundance is rule of thumb to judge
, meanwhile, abundance is a relative concept, and the embodiment of the present invention is not to " the most sufficient "
Carrying out restriction numerically.Such as, in cluster, the surplus of a certain server disk is the 50% of total capacity,
If ensuing scheduling calculating task has only to take the 10% of disk total capacity, then adjust for this
For degree calculating task, the disk surplus of this server is sufficient, and the calculating of scheduler task is normally entered
OK;If next calculating task to disk demand is total capacity 51%, then can know significantly
The surplus of this disk has been not enough to next scheduler task and has calculated, if enforcing, then may
Occur causing, owing to calculating inadequate resource, the situation that scheduler task is failed.
Embodiment four
Fig. 4 is the schematic diagram that embodiment of the present invention long-term prediction model is set up, and in conjunction with Fig. 4, the present invention is real
Execute example and farther include following steps:
Step 401: described first time period is set as Y days before current time, at every needs
Detector is installed on the server of monitoring, monitors described server system and calculate the usage amount of resource, wherein
Y belongs to the second scope;
In the embodiment of the present invention, following example can be lifted: described detector is installed on a certain server to not
In coming 7 days, whether the usage amount of cluster CPU can reach 100% and be predicted, can the most described first
Time period is set as 30 days (Y=30), is set in the described monitoring cycle 1 minute, then described first
In time, described central server makes receiving 43200 CPU sent from described a certain server
Usage data value.
It should be noted that described second scope is determined by experience, the embodiment of the present invention does not limit
The upper lower limit value of described second scope.
Step 402: the monitoring data of described usage amount are sent back central server by described detector;
Accept the example of previous step, in the embodiment of the present invention, detector operation per minute can be set once,
Each server in cluster, will in HTTP mode by calling the REST API that central server provides
Detection data send back central server, and the monitoring cycle of certain embodiment of the present invention is not limited in one point
Clock is once.
Step 403: described central server receives the described monitoring data of described detector transmission and with system
The described monitoring data received are added up by the meter cycle;
Accept the example of previous step, the embodiment of the present invention uses and makes every 5 minutes CPU to cluster
Consumption is added up.One hour is divided into 12 subregions, takes previous the 5 of current time every time
Minute subregion calculates.The monitoring data sent individual server the most at times are added up, energy
Enough making whole statistic processes real-time strengthen, the data volume that secondly central server disposably processes is notable
Reducing, therefore the speed of service is faster, the most also provides the foundation for realizing real-time early warning.Certainly,
The described measurement period of the embodiment of the present invention is not limited in five minutes, it is also possible to rule of thumb or center
The performance of server is configured.
Step 404: described central server is according to the described monitoring data in described first time period, meter
Calculate single exponential smoothing value corresponding to described monitoring data and the double smoothing value in each detection moment;
Accepting the example of previous step, described second time period is 7 days, utilizes formula 1 and formula 2 to count
Calculate St (1)And St (2), i.e. calculate an index of each minute CPU usage amount in first 30 days of current time
Smooth value and double smoothing value, there are 43200 time dependent St (1)It is worth and 43200
Time dependent St (2)Value.
Step 405: described central server is according to one of the described monitoring data in described first time period
Secondary exponential smoothing value and double smoothing value, set up and calculate resources model, to described current time
In the second time period afterwards, the usage amount of described system resources in computation is predicted.
According to formula 3, taking m=1440, the predictive value of first day in described second time period is
Ft+m=F44640, take m=2880, the predictive value of second day in described second time period is Ft+m=F46080、
Taking m=10080, the predictive value of the 7th day in described second time period is Ft+m=F53280.By above meter
Calculate CPU usage amount in 7 days after i.e. can get current time with or without reach 100% probability, if having,
The most in advance dispatching patcher is carried out early warning.
The embodiment of the present invention carries out visual presentation to the early warning of described system resources in computation usage amount,
Thus dispatching patcher operation maintenance personnel according to described early warning, the calculating resource of cluster can be made more reasonable
Planning.
Embodiment five
It is the device schematic diagram of the embodiment of the present invention two shown in Fig. 5, in conjunction with Fig. 5, the embodiment of the present invention one
Plant system resources in computation prediction means based on Smoothing Prediction, including such as lower module: data reception
Block 501, data processing module 502, prediction module 503, display module 504.
Described data reception module 501, its function is, central server before current time first
Persistently receiving multiple monitoring data in time period, each monitoring data are that each monitoring cycle is interior to clothes
The data that the system resources in computation situation of business device is monitored and obtains, specifically include described server often
Using the usage amount of system resources in computation in one monitoring cycle, described first time period includes multiple described
The monitoring cycle;
Described data processing module 502, its function is, when described central server is according to described first
Between the single exponential smoothing value of the plurality of monitoring data that receives in section and double smoothing value, build
Vertical calculating resources model;
Described prediction module 503, its function is, according to described calculating resources model, it was predicted that current
The usage amount of the system resources in computation of server described in a certain moment in the second time period after moment;
Display module 504, is shown the result of described prediction.
Described data processing module 502 is further used for, and described data processing module is further used for, and adopts
Described single exponential smoothing value and double smoothing value is calculated by equation below:
St (1)=α × yt+(1-α)×(St-1)(1)
St (2)=α × St (1)+(1-α)×(St-1)(2)
Wherein, α is smoothing constant, and t is the t detection moment, and the value of t is in described first time period
Interior last monitoring cycle before first monitoring mechanical periodicity to current time;ytIt it is t
The monitoring data in detection moment;St (1)It is to monitor data single exponential smoothing value described in the t detection moment;
St (2)It it is the double smoothing value monitoring data described in the t detection moment.
Described prediction module 503, is further used for: described prediction module, is further used for: uses and calculates
Resources model:
Ft+m=st+m×bt
st=2St (1)–St (2)
bt=(α/1-α) × (St (1)-St (2))
Wherein, α is smoothing constant, and t is last the detection moment in described first time period, t+m
It is the m-th moment in described second time period, Ft+mMake for system resources in computation described in the m-th moment
The predictive value of consumption, stAnd btFor model parameter;Wherein, St (1)It it is the described monitoring in the t detection moment
The single exponential smoothing value of data;St (2)It is that the secondary index monitoring data described in the t detection moment is put down
Sliding value.
Application scenarios example
As shown in Figure 6, the present embodiment is the application scenarios example of the embodiment of the present invention, passes through application scenarios
Under to double smoothing prediction calculating so that the technical scheme of the embodiment of the present invention is the clearest.
In the embodiment of the present invention, it is assumed that described first time period is set to 1 hour, the described monitoring cycle
It is ten minutes, takes the monitoring data of previous ten minutes of current time in predicting described second time period
Calculating resource usage amount.Concrete operations are as follows, it is assumed that the CPU that described central server receives calculates
Resources occupation amount is as follows: y1=0.24, y2=0.27, y3=0.25, y4=0.28, y5=0.26, y6=0.27,
y7=0.26, y8=0.28, y9=0.30, y10=0.33, the changing value of this sequence has the most significantly change
Changing tendency, sliding factor alpha=0.8 of therefore making even is predicted.
According to double smoothing predictor formula, the time series in future time section is predicted, as
Under:
St (1)=α × yt+(1-α)×(St-1)(1)
St (2)=α × St (1)+(1-α)×(St-1)(2)
During initialization, make S0 (2)=S0 (1)=y1=0.24.
S1, calculates the exponential smoothing value in the first moment, during t=1, y1=0.24:
S1 (1)=α × y1+(1-α)×(S0)(1)
S1 (2)=α × S1 (1)+(1-α)×(S0)(2)
Substitute into concrete numerical value as follows:
S1 (1)=0.8*0.24+0.2*0.24=0.24
S1 (2))=0.8*0.24+0.2*0.24=0.24
S2, calculates the exponential smoothing value in the second moment, during t=2, y2=0.27:
S2 (1)=α × y2+(1-α)×(S1)(1)
S2 (2)=α × S2 (1)+(1-α)×(S1)(2)
Substitute into concrete numerical value as follows:
S2 (1)=0.8*0.27+0.2*0.24=0.264
S2 (2))=0.8*0.264+0.2*0.24=0.2592
S3, calculates the exponential smoothing value in the 3rd moment, during t=3, y3=0.25:
S3 (1)=α × y3+(1-α)×(S2)(1)
S3 (2)=α × S3 (1)+(1-α)×(S2)(2)
Substitute into concrete numerical value as follows:
S3 (1)=0.8*0.25+0.2*0.264=0.2528
S3 (2)=0.8*0.2528+0.2*0.2592=0.25408
S4, calculates the exponential smoothing value in the 4th moment, during t=4, y4=0.28:
S4 (1)=α × y4t+(1-α)×(S3)(1)
S4 (2)=α × S4 (1)+(1-α)×(S3)(2)
Substitute into concrete numerical value as follows:
S4 (1)=0.8*0.28+0.2*0.2528=0.27456
S4 (2))=0.8*0.27456+0.2*0.25408=0.270464
S5, calculates the exponential smoothing value in the 5th moment, during t=5, y3=0.26:
S5 (1)=α × y5+(1-α)×(S4)(1)
S5 (2)=α × S5 (1)+(1-α)×(S4)(2)
Substitute into concrete numerical value as follows:
S5 (1)=0.8*0.26+0.2*0.27456=0.262912
S5 (2))=0.8*0.262912+0.2*0.270464=0.2644224
S6, calculates the exponential smoothing value in the 6th moment, during t=6, y3=0.27:
S6 (1)=α × y6+(1-α)×(S5)(1)
S6 (2)=α × S6 (1)+(1-α)×(S5)(2)
Substitute into concrete numerical value as follows:
S3 (1)=0.8*0.27+0.2*0.262912=0.2685824
S3 (2))=0.8*0.2685824+0.2*0.2644224=0.2677504
S7, calculates the exponential smoothing value in the 7th moment, during t=7, y7=0.26:
S7 (1)=α × y7+(1-α)×(S6)(1)
S7 (2)=α × S7 (1)+(1-α)×(S6)(2)
Substitute into concrete numerical value as follows:
S3 (1)=0.8*0.26+0.2*0.2685824=0.26171648
S3 (2))=0.8*0.26171648+0.2*0.2677504=0.262923264
S8, calculates the exponential smoothing value in the 8th moment, during t=8, y3=0.28:
S8 (1)=α × y8+(1-α)×(S7)(1)
S8 (2)=α × S8 (1)+(1-α)×(S7)(2)
Substitute into concrete numerical value as follows:
S3 (1)=0.8*0.28+0.2*0.26171648=0.276343296
S3 (2))=0.8*0.276343296+0.2*0.276343296=0.276343296
S9, calculates the exponential smoothing value in the 9th moment, during t=9, y9=0.30:
S9 (1)=α × y9+(1-α)×(S8)(1)
S9 (2)=α × S9 (1)+(1-α)×(S8)(2)
Substitute into concrete numerical value as follows:
S9 (1)=0.8*0.30+0.2*0.276343296=0.2952686592
S9 (2))=0.8*0.2952686592+0.2*0.276343296=0.29148358656
S10, calculates the exponential smoothing value in the tenth moment, during t=10, y3=0.33:
S10 (1)=α × y10+(1-α)×(S9)(1)
S10 (2)=α × S10 (1)+(1-α)×(S9)(2)
Substitute into concrete numerical value as follows:
S10 (1)=0.8*0.33+0.2*0.2952686592=0.32305373184
S10 (2))=0.8*0.32305373184+0.2*0.29148358656=0.316739702784
After obtaining the smooth value of express time sequence variation trend, can be to the following t+m moment
Value is predicted, it was predicted that formula is as follows:
Ft+m=st+m×bt
st=2St (1)–St (2)
bt=(α/1-α) × (St (1)-St (2))
Work as t=10, during m=1, the value in the 11st moment be predicted:
S10=2S10 (1)–S10 (2)=2*0.32305373184-0.316739702784=0.3294
b10=(α/1-α) * (S10 (1)–S10 (2))=0.02526
F11=Ft+m=s10+m×b10=0.3294+0.02526=0.35466
As m=2, the value in the 12nd moment is predicted:
F12=Ft+m=s10+2×b10=0.3294+2*0.02526=0.37992
As m=3, the value in the 13rd moment is predicted:
F13=Ft+m=s10+3×b10=0.3294+3*0.02526=0.40518
As m=4, the value in the 14th moment is predicted:
F14=Ft+m=s10+4×b10=0.3294+4*0.02526=0.43044
As shown in Figure 6, from the 1st moment to the 10th moment, the predictive value of double smoothing and reality
Actual value is basically identical, and trend moves towards identical, therefore to the 11st, 12,13, the prediction knot in 14 moment
The calculating resource that the trend of fruit and prediction also was able to highlight in certain time period after the 10th moment is walked
To trend.
Device embodiment described above is only schematically, wherein said illustrates as separating component
Unit can be or may not be physically separate, the parts shown as unit can be or
Person may not be physical location, i.e. may be located at a place, or can also be distributed to multiple network
On unit.Some or all of module therein can be selected according to the actual needs to realize the present embodiment
The purpose of scheme.Those of ordinary skill in the art are not in the case of paying performing creative labour, the most permissible
Understand and implement.
Through the above description of the embodiments, those skilled in the art is it can be understood that arrive each reality
The mode of executing can add the mode of required general hardware platform by software and realize, naturally it is also possible to by firmly
Part.Based on such understanding, the portion that prior art is contributed by technique scheme the most in other words
Dividing and can embody with the form of software product, this computer software product can be stored in computer can
Read in storage medium, such as ROM/RAM, magnetic disc, CD etc., including some instructions with so that one
Computer equipment (can be personal computer, server, or the network equipment etc.) performs each to be implemented
The method described in some part of example or embodiment.
Last it is noted that above example is only in order to illustrate technical scheme, rather than to it
Limit;Although the present invention being described in detail with reference to previous embodiment, the ordinary skill of this area
Personnel it is understood that the technical scheme described in foregoing embodiments still can be modified by it, or
Person carries out equivalent to wherein portion of techniques feature;And these amendments or replacement, do not make corresponding skill
The essence of art scheme departs from the spirit and scope of various embodiments of the present invention technical scheme.
Claims (10)
1. a system resources in computation Forecasting Methodology based on Smoothing Prediction, it is characterised in that
Central server persistently receives multiple monitoring data in the first time period before current time,
Each monitoring data be in each monitoring cycle system resources in computation situation to server be monitored and
The data obtained, specifically include the use of system resources in computation within each monitoring cycle of described server
Amount, described first time period includes multiple described monitoring cycle;
Described central server is according to the one of the plurality of monitoring data received in described first time period
Secondary exponential smoothing value and double smoothing value, set up and calculate resources model;
According to described calculating resources model, it was predicted that certain a period of time in the second time period after current time
Carve the usage amount of the system resources in computation of described server, and the result of described prediction is shown.
Method the most according to claim 1, it is characterised in that described system resources in computation is at least wrapped
Include:
Center Processing Unit Utilization, memory headroom, disk space, transmission control protocol connect quantity.
Method the most according to claim 1, it is characterised in that described calculating resources model,
Particularly as follows:
Ft+m=st+m×bt;
st=2St (1)–St (2);
bt=(α/1-α) × (St (1)-St (2));
Wherein, Ft+mFor the predictive value of system resources in computation usage amount described in the m-th moment, α is smooth
Constant, t is last the detection moment in described first time period, in t+m is described second time period
The m-th moment, stAnd btFor model parameter;Wherein, St (1)It it is the described monitoring in the t detection moment
The single exponential smoothing value of data;St (2)It is that the secondary index monitoring data described in the t detection moment is put down
Sliding value.
Method the most according to claim 3, it is characterised in that described single exponential smoothing value and two
Secondary exponential smoothing value is calculated by equation below:
St (1)=α × yt+(1-α)×(St-1)(1)
St (2)=α × St (1)+(1-α)×(St-1)(2)
Wherein, α is smoothing constant, and t is the t detection moment, and the value of t is in described first time period
Interior last monitoring cycle before first monitoring mechanical periodicity to current time;ytIt it is t
The monitoring data in detection moment;St (1)It it is the single exponential smoothing value monitoring data described in the t detection moment;
St (2)It it is the double smoothing value monitoring data described in the t detection moment.
Method described in any one in 1-4 the most as requested, it is characterised in that described central server
According to described calculating resources model, it was predicted that a certain moment institute in the second time period after current time
State the usage amount of the system resources in computation of server, farther include:
Described first time period is set as X hour before current time, obtains interior monitoring in X hour
The variation tendency of data, thus the described system resources in computation usage amount in predicting described second time period is also
Judging that described system resources in computation usage amount is the most sufficient, if sufficient, then scheduler task is properly functioning;If
Inadequate, change scheduler task direction, avoid calculating resource and block up peak, wherein, X belongs to the first model
Enclose.
6. according to the method described in any one in claim 1-4, it is characterised in that genuinely convinced in described
Business device is according to described calculating resources model, it was predicted that described clothes in the second time period after current time
The usage amount of the system resources in computation of business device, further comprises:
Described first time period is set as Y days, the variation tendency of the monitoring data in obtaining Y days, from
And described system resources in computation usage amount in predicting described second time period judge that described system-computed provides
Whether source usage amount has the probability reaching 100%, if having, the most in advance dispatching patcher is carried out early warning,
Wherein, Y belongs to the second scope.
7. a system resources in computation prediction means based on Smoothing Prediction, it is characterised in that include
Such as lower module:
Data reception module, central server persistently receives in the first time period before current time
Multiple monitoring data, each monitoring data are each monitoring cycle interior system resources in computation to server
The data that situation is monitored and obtains, specifically including described server is within each monitoring cycle
Statistics calculates the usage amount of resource, and described first time period includes multiple described monitoring cycle;
Data processing module, described central server is described many according to receive in described first time period
The single exponential smoothing value of individual monitoring data and double smoothing value, set up and calculate resources model;
Prediction module, according to described calculating resources model, it was predicted that the second time after current time
The usage amount of the system resources in computation of server described in a certain moment in section;
Display module, is shown the result of described prediction.
8. according to the device described in claim 7, it is characterised in that described calculating resources model, tool
Body is:
Ft+m=st+m×bt
st=2St (1)–St (2)
bt=(α/1-α) × (St (1)-St (2))
Wherein, Ft+mFor the predictive value of system resources in computation usage amount described in the m-th moment, α is smooth
Constant, t is last the detection moment in described first time period, in t+m is described second time period
The m-th moment, stAnd btFor model parameter;Wherein, St (1)It it is the described prison in the t detection moment
The single exponential smoothing value of control data;St (2)It it is the secondary index monitoring data described in the t detection moment
Smooth value.
9. according to the device described in claim 8, it is characterised in that described data processing module is used further
In, the employing equation below described single exponential smoothing value of calculating and double smoothing value:
St (1)=α × yt+(1-α)×(St-1)(1)
St (2)=α × St (1)+(1-α)×(St-1)(2)
Wherein, α is smoothing constant, and t is the t detection moment, and the value of t is in described first time period
Interior last monitoring cycle before first monitoring mechanical periodicity to current time;ytIt it is t
The monitoring data in detection moment;St (1)It is to monitor data single exponential smoothing value described in the t detection moment;
St (2)It it is the double smoothing value monitoring data described in the t detection moment.
Device described in any one in 7-9 the most as requested, it is characterised in that described device, enters
One step is used for:
Described first time period is set as X hour before current time, obtains interior monitoring in X hour
The variation tendency of data, thus the described system resources in computation usage amount in predicting described second time period is also
Judging that described system resources in computation usage amount is the most sufficient, if sufficient, then scheduler task is properly functioning;If
Inadequate, change scheduler task direction, avoid calculating resource and block up peak, wherein, X belongs to the first model
Enclose;Or,
Described first time period is set as Y days before current time, the monitoring data in obtaining Y days
Variation tendency, thus described system resources in computation usage amount in predicting described second time period judging
Whether described system resources in computation usage amount has the probability reaching 100%, if having, the most in advance to scheduling system
System carries out early warning, and wherein, Y belongs to the second scope.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510595120.5A CN105912436A (en) | 2015-09-17 | 2015-09-17 | Method and device for predicting system computing resource based on exponential smoothing prediction |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510595120.5A CN105912436A (en) | 2015-09-17 | 2015-09-17 | Method and device for predicting system computing resource based on exponential smoothing prediction |
Publications (1)
Publication Number | Publication Date |
---|---|
CN105912436A true CN105912436A (en) | 2016-08-31 |
Family
ID=56743951
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510595120.5A Pending CN105912436A (en) | 2015-09-17 | 2015-09-17 | Method and device for predicting system computing resource based on exponential smoothing prediction |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105912436A (en) |
Cited By (13)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106411947A (en) * | 2016-11-24 | 2017-02-15 | 广州华多网络科技有限公司 | Real-time threshold adaptive flow early warning method and device thereof |
CN107368372A (en) * | 2017-07-25 | 2017-11-21 | 郑州云海信息技术有限公司 | A kind of resource exhibition method and device based on sea of clouds OS platforms |
CN108509325A (en) * | 2018-03-07 | 2018-09-07 | 北京三快在线科技有限公司 | System time-out time is dynamically determined method and apparatus |
CN109783323A (en) * | 2018-11-27 | 2019-05-21 | 宝付网络科技(上海)有限公司 | The prediction technique of residual storage capacity pot life |
CN110109800A (en) * | 2019-04-10 | 2019-08-09 | 网宿科技股份有限公司 | A kind of management method and device of server cluster system |
CN110928649A (en) * | 2018-09-19 | 2020-03-27 | 北京国双科技有限公司 | Resource scheduling method and device |
CN111190790A (en) * | 2019-12-17 | 2020-05-22 | 西安交通大学 | Cloud computing cluster monitoring method and system based on peak prediction |
CN111223561A (en) * | 2020-01-13 | 2020-06-02 | 南京巨鲨显示科技有限公司 | Medical image equipment sharing method and system based on quadratic exponential smoothing method |
CN112035324A (en) * | 2020-09-03 | 2020-12-04 | 中国银行股份有限公司 | Batch job execution condition monitoring method and device |
CN113673787A (en) * | 2021-09-10 | 2021-11-19 | 中国舰船研究设计中心 | Unmanned cluster multi-domain detection data track association and prediction method |
CN114860552A (en) * | 2022-07-11 | 2022-08-05 | 北京首信科技股份有限公司 | Performance monitoring method, server, client, electronic equipment and storage medium thereof |
CN117291291A (en) * | 2023-08-12 | 2023-12-26 | 江苏信实环境工程有限公司 | Insect condition intelligent monitoring system and method based on Internet of things |
CN117331705A (en) * | 2023-12-01 | 2024-01-02 | 深圳品阔信息技术有限公司 | Data prediction analysis method and system based on big data |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6067412A (en) * | 1995-08-17 | 2000-05-23 | Microsoft Corporation | Automatic bottleneck detection by means of workload reconstruction from performance measurements |
US20040148152A1 (en) * | 2003-01-17 | 2004-07-29 | Nec Corporation | System performance prediction mechanism and method based on software component performance measurements |
CN103903069A (en) * | 2014-04-15 | 2014-07-02 | 广东电网公司信息中心 | Storage capacity predication method and storage capacity predication system |
CN104407925A (en) * | 2014-12-10 | 2015-03-11 | 中国电信集团系统集成有限责任公司 | Dynamic resource distribution method |
CN104461821A (en) * | 2014-11-03 | 2015-03-25 | 浪潮(北京)电子信息产业有限公司 | Virtual machine monitoring and warning method and system |
CN104735786A (en) * | 2013-12-18 | 2015-06-24 | 中兴通讯股份有限公司 | Resource scheduling method and device |
-
2015
- 2015-09-17 CN CN201510595120.5A patent/CN105912436A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6067412A (en) * | 1995-08-17 | 2000-05-23 | Microsoft Corporation | Automatic bottleneck detection by means of workload reconstruction from performance measurements |
US20040148152A1 (en) * | 2003-01-17 | 2004-07-29 | Nec Corporation | System performance prediction mechanism and method based on software component performance measurements |
CN104735786A (en) * | 2013-12-18 | 2015-06-24 | 中兴通讯股份有限公司 | Resource scheduling method and device |
CN103903069A (en) * | 2014-04-15 | 2014-07-02 | 广东电网公司信息中心 | Storage capacity predication method and storage capacity predication system |
CN104461821A (en) * | 2014-11-03 | 2015-03-25 | 浪潮(北京)电子信息产业有限公司 | Virtual machine monitoring and warning method and system |
CN104407925A (en) * | 2014-12-10 | 2015-03-11 | 中国电信集团系统集成有限责任公司 | Dynamic resource distribution method |
Cited By (19)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106411947B (en) * | 2016-11-24 | 2019-07-09 | 广州华多网络科技有限公司 | A kind of real time threshold adaptive flow method for early warning and device |
CN106411947A (en) * | 2016-11-24 | 2017-02-15 | 广州华多网络科技有限公司 | Real-time threshold adaptive flow early warning method and device thereof |
CN107368372A (en) * | 2017-07-25 | 2017-11-21 | 郑州云海信息技术有限公司 | A kind of resource exhibition method and device based on sea of clouds OS platforms |
CN107368372B (en) * | 2017-07-25 | 2021-02-23 | 苏州浪潮智能科技有限公司 | Resource display method and device based on cloud sea OS platform |
CN108509325B (en) * | 2018-03-07 | 2021-01-15 | 北京三快在线科技有限公司 | Method and device for dynamically determining system timeout time |
CN108509325A (en) * | 2018-03-07 | 2018-09-07 | 北京三快在线科技有限公司 | System time-out time is dynamically determined method and apparatus |
CN110928649A (en) * | 2018-09-19 | 2020-03-27 | 北京国双科技有限公司 | Resource scheduling method and device |
CN109783323A (en) * | 2018-11-27 | 2019-05-21 | 宝付网络科技(上海)有限公司 | The prediction technique of residual storage capacity pot life |
CN110109800A (en) * | 2019-04-10 | 2019-08-09 | 网宿科技股份有限公司 | A kind of management method and device of server cluster system |
CN111190790A (en) * | 2019-12-17 | 2020-05-22 | 西安交通大学 | Cloud computing cluster monitoring method and system based on peak prediction |
CN111223561A (en) * | 2020-01-13 | 2020-06-02 | 南京巨鲨显示科技有限公司 | Medical image equipment sharing method and system based on quadratic exponential smoothing method |
CN112035324A (en) * | 2020-09-03 | 2020-12-04 | 中国银行股份有限公司 | Batch job execution condition monitoring method and device |
CN113673787A (en) * | 2021-09-10 | 2021-11-19 | 中国舰船研究设计中心 | Unmanned cluster multi-domain detection data track association and prediction method |
CN113673787B (en) * | 2021-09-10 | 2023-09-26 | 中国舰船研究设计中心 | Unmanned cluster multi-domain detection data track association and prediction method |
CN114860552A (en) * | 2022-07-11 | 2022-08-05 | 北京首信科技股份有限公司 | Performance monitoring method, server, client, electronic equipment and storage medium thereof |
CN117291291A (en) * | 2023-08-12 | 2023-12-26 | 江苏信实环境工程有限公司 | Insect condition intelligent monitoring system and method based on Internet of things |
CN117291291B (en) * | 2023-08-12 | 2024-04-23 | 江苏信实环境工程有限公司 | Insect condition intelligent monitoring system and method based on Internet of things |
CN117331705A (en) * | 2023-12-01 | 2024-01-02 | 深圳品阔信息技术有限公司 | Data prediction analysis method and system based on big data |
CN117331705B (en) * | 2023-12-01 | 2024-03-29 | 深圳品阔信息技术有限公司 | Data prediction analysis method and system based on big data |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105912436A (en) | Method and device for predicting system computing resource based on exponential smoothing prediction | |
Jiang et al. | Optimal cloud resource auto-scaling for web applications | |
CN103036974B (en) | Cloud computing resource scheduling method based on hidden Markov model and system | |
EP3494624B1 (en) | Distributed resource electrical demand forecasting system and method | |
CN102882745B (en) | A kind of method and apparatus for monitoring business server | |
CN108038040A (en) | Computer cluster performance indicator detection method, electronic equipment and storage medium | |
CN106899660A (en) | Cloud data center energy-saving distribution implementation method based on trundle gray forecast model | |
Yi et al. | Toward efficient compute-intensive job allocation for green data centers: A deep reinforcement learning approach | |
Bi et al. | SLA-based optimisation of virtualised resource for multi-tier web applications in cloud data centres | |
CN103685347B (en) | Method and device for allocating network resources | |
Li et al. | Efficient resource scaling based on load fluctuation in edge-cloud computing environment | |
CN109271257A (en) | A kind of method and apparatus of virtual machine (vm) migration deployment | |
CN109947558A (en) | Host resource utilization rate calculation method and resource regulating method | |
CN108770017A (en) | A kind of radio resource method for dynamically balancing and system, computer program | |
CN115543577B (en) | Covariate-based Kubernetes resource scheduling optimization method, storage medium and device | |
CN111752710B (en) | Data center PUE dynamic optimization method, system and equipment and readable storage medium | |
CN115860383A (en) | Power distribution network scheduling method and device, electronic equipment and storage medium | |
CN116307546A (en) | Task intelligent decision system based on robot community | |
Radovanovic et al. | Power modeling for effective datacenter planning and compute management | |
CN108132840A (en) | Resource regulating method and device in a kind of distributed system | |
CN111565216A (en) | Back-end load balancing method, device, system and storage medium | |
CN105045667A (en) | Resource pool management method for vCPU scheduling of virtual machines | |
US10931107B2 (en) | System and method for management of an electricity distribution grid | |
CN103442087A (en) | Web service system access volume control device and method based on response time trend analysis | |
CN116937645A (en) | Charging station cluster regulation potential evaluation method, device, equipment and medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WD01 | Invention patent application deemed withdrawn after publication | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20160831 |