CDN常用计费方法

95计费法是CDN常用计费方法:

CDN基本上是每月结一次款。每5分钟取一个点,1个小时12个点,1天12*24个点,一个月按30天算12*24*30=8640个点, 从高到低排序,然后把数值最高的%5的点去掉,剩下的最高带宽就是95计费的计费值了。

计费点数是8208个点。

有432个点不用计费,就是异常流量的时间在432*5/60=36个小时,即不超过1.5天的异常大带宽(流量),不影响本月的计费。


第四峰值计费,也就是每天的最大值,然后 30 天从高到低排序,选第四高的那个作为本月的 计费带宽值

平均值计费就是每天的最大值加起来,然后除以当月总天数得到的 平均值作为计费带宽值。


THE 95% RULE

Bandwidth monitoring records sample data points, which reflect how much bandwidth a customer is utilizing in that particular instance. The inbound and outbound traffic level for each service connection is measured every 5 minutes. During the agreed period (normally one month), all the data samples for the inbound and outbound are collected in a database.

To account for the instances in which the customer's traffic bursts over the minimum committed bandwidth, Init7 utilizes a billing method referred to as the "95th Percentile Rule", as defined below. Init7 deals with these cases unbureaucratically, while our employees keep a close eye on our customers' traffic to ensure suitable Committed-Data-Rates (CDR) and cost-effective prices.

The highest 5% of both the inbound and outbound traffic levels are discarded, and the next highest remaining data sample on either the inbound or outbound is the "95th Percentile" value. This number is used as the basis for the calculation of any additional monthly charges. If the 95th percentile number falls below the minimum monthly committed amount, no additional charges will occur.


Calculation Example:

Our customer has committed to 20Mbps per month. Init7 gathers data samples for one month and sorts them from highest to lowest, discarding the top 5%. For the purpose of this example, the 95th percentile for the month was 75Mbps. The company will bill the customer for the additional charges of 75Mbps, minus the previously invoiced 20Mbps of contractually committed bandwidth, or 55Mbps. Only the 55Mbps of "over-use" will be invoiced for.

The following formula is based on a 30-day month:

1 Sample * 12 * 24 * 30 = 5 Min 1 Hour 1 Day 1 Month

8640 maximum total samples/month 5% of 8640 maximum samples/month = 432 samples/month discarded. The highest remaining data sample in the inbound or outbound would be the 95th percentile.

=====================

What the heck is this 95th Percentile number?

The 95th percentile is a widely used mathematical calculation to evaluate the regular and sustained utilization of a network pipe. For example, it is the same calculation BBN/GTE uses to bill the Coop for its metered use of a T3. Many ISPs use it for capacity planning and/or calculating metered use.

Basically the 95th percentile says that 95% of the time, the usage is below this amount. Conversely of course, 5% of the time, usage is above that amount. The 95th percentile is a good number to use for planning so you can ensure you have the needed bandwidth at least 95% of the time.

There are three important factors to a percentile calculation:

Percentile number
A percentile basically says that for that percentage of the time, the data points are below the resulting value. So if we calculate a 50th percentile, 50% of the time the data points are below that resulting value and 50% of the time they are above that value. A 50th percentile is the same as a "median." An average, or "mean," is similar but a weighted result. A 95th percentile says that 95% of the time data points are below that value and 5% of the time they are above that value. 95 is a magic number used in networking because you have to plan for the most-of-the-time case. If networks were planned for mean or average use, they could be unusable (saturated) half the time. On the other hand, 100th percentile is a theoretically impossible goal because given no bottlenecks, the data will use the throughput available.
Data points used
A percentile is calculated on some set of data points. What those data points represent is significant to understanding the meaning of the percentile result. For example, percentile rankings of SAT scores indicate one's relative standing with others who took the test. Network percentiles are based on sampled throughput utilization. The sample rate indicates how accurate or forgiving the percentile is. The more frequent the sample rate, the more accurate and less forgiving the percentile will be. Coop MRTG data samples are collected every 10 minutes. As a count of bits over a 10 minute period, the data sample represents a 10 minute averaged bits per second value. It's averaged because we don't know the highs and lows within that 10 minute period. BBN/GTE uses a 15 minute sample interval. Some use a 5 minute sample interval.
Data set size
The data set size indicates the range of the values. Again using the SAT example, a percentile result has a different meaning if the data set is nationwide or just statewide. In network percentiles, the data set is a period of time over which samples are collected. Usually for any solid planning and trend determination, we need a reasonbly large data set to cover the peaks and valleys of utilization. A month of samples is the typical data set.

The Coop percentile calculation uses a 95th percentile on 10 minute averages (more on this below) over a period of 30 days. The calculation is made on the most recent 30 day period, so the result is a floating window result - not fixed to a calendar month.

So the percentile figure shown on the Coop MRTG graphs tells us that 95% of the time in the most recent 30 days, the bits per second utilization in the 10 minute interval is below the reported 95th percentile value.

How is the number actually calculated?

MRTG is a great program. Its data are automatically reduced over time to larger intervals to keep log files from growing without bound. This means that the 10 minute average numbers get reduced to 30 minute averages and then 2 hour averages after a while in the log file.

In an MRTG data file, the first 600 values are at the run interval (10 minutes at the Coop), the next 600 are reduced to 30 minute intervals, the next 600 are reduced to 2 hour intervals, and the rest are reduced to 24 hour intervals. We use 1360 MRTG data points which are:

  • 600 at 10 minute intervals (6000 minutes)
  • 600 at 30 minute intervals (18000 minutes)
  • 160 at 2 hour intervals (19200 minutes)
  • Total of 43200 minutes or 30 days exactly

In order to preserve the data set as 10 minute samples and not skew the significance of the data to the most recent side of the period, the Coop percentile program repeats the reduced data as necessary to get the correct number of samples. For example, a 30 minute sample is repeated three times to be three equal 10 minute samples. Note that this correction was added 9/26/1998.

The traditional mathematical method for calculating a percentile assumes that your data set is so large that you can't store it all in memory and sort it. It uses "buckets" and calculates an "ogive" and then approximates the result through reverse interpolation. Since our data set is finite and small (relative to memory), we just do it straight forward:

  • collect the data set (two actually: inbound, outbound samples)
  • sort each data set
  • find the index of the 95th percentile element
  • print the larger of the inbound or outbound 95th percentile data element
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值