
Amazon added new types of instances - t2.micro, t2.small, t2.medium
New instances are cheaper than old ones and introduce the concept of CPU Credit.
CPU Credit is an internal accumulating coin that is 1 minute at 100% load.
Credit is accumulated at a speed depending on the type of server. Also, it depends on the type of server to where its maximum CPU load will go in the absence of credits - baseline. The minimum maximum. Minimum, because in the absence of loans, the maximum load sags not instantly, but gradually over a period of 15 minutes, so that it is possible to compensate for the lack of resources if necessary.
The loan is stored up to 24 hours.
Thus - t2.medium comes at a very good price, with 4GB of memory on board, with the ability to work 24 minutes per hour, or 9.6 hours per day, that is, work full time at maximum load. I consider this a very good suggestion.
Accordingly, the micro instance is able to work 2.4 hours a day at maximum load, and small - 4.8 hours. Check your logs, even this is not enough.
It should also be noted that 9.6 hours is based on the assumption that 1vCPU is loaded at 100 percent or 2vCPU at 50 percent.
(respectively baseline 20% x2 or 40% x1)
2vCPU on medium, both with 100% load can work no more than 4.8 hours a day.
For comparison, the table. it should be borne in mind that t1.micro, m1.small, m1.medium in it are calculated on the basis of an annual prepayment based on a high load, and new instances can be improved at any time, or vice versa.
The prices for the old instances are taken from the ec2 instances marketplace today, most recently these prices were much higher, therefore, in general, the current generation is faster and cheaper if there is no round-the-clock load and there is no need for own instance disks, the new server types only support EBS.
By the way, Amazon is canceling the old server types, such as: t1.micro, m1.small, m1.medium. They can still be taken to the EC2 marketplace, but in general, they are considered obsolete.
It’s no secret that t1 was already with throttling, in fact I suspect that the first letter in the name of the instances came from here, but in its case the information on how the maximum allowable performance will decrease was not disclosed, now everything is clear and even with cloudwatch metrics.
There are separate metrics for the balance of loans and their use. What's in the compartment with the fact that there is no longer any need to make an advance payment (upfront) for servers of this class, it makes it possible to build an automatically scalable configuration that actually follows the long-standing slogan - "Pay only for use."
By the way, the vast majority of servers, access to the body of which I have are invested in the limitations of t2.medium instances, I think I’m not the only one and putting these servers into operation is a very, very good alternative to dancing with a tambourine around light / medium / heavy utilisation.
Actually, it’s not even an alternative, but a clear winner, since for many, the calculation of “take for a year” is often not flexible enough, because it is not known what awaits there. Now it’s much easier to count in this segment.
It remains to wait for at least t3.x2large to appear, for projects where load peaks are frequent, resource-demanding, but short-lived.
Official page: docs.aws.amazon.com/AWSEC2/latest/UserGuide/t2-instances.html
CPU Credit is an internal accumulating coin that is 1 minute at 100% load.
Credit is accumulated at a speed depending on the type of server. Also, it depends on the type of server to where its maximum CPU load will go in the absence of credits - baseline. The minimum maximum. Minimum, because in the absence of loans, the maximum load sags not instantly, but gradually over a period of 15 minutes, so that it is possible to compensate for the lack of resources if necessary.
The loan is stored up to 24 hours.
Instance type | Credits per hour | Baseline | Price per hour | Price per month |
---|---|---|---|---|
t2.micro | 6 | 10% | $ 0.013 | $ 9.50 |
t2.small | 12 | 20% | $ 0.026 | $ 19 |
t2.medium | 24 | 40% | $ 0.052 | $ 38 |
Thus - t2.medium comes at a very good price, with 4GB of memory on board, with the ability to work 24 minutes per hour, or 9.6 hours per day, that is, work full time at maximum load. I consider this a very good suggestion.
Accordingly, the micro instance is able to work 2.4 hours a day at maximum load, and small - 4.8 hours. Check your logs, even this is not enough.
It should also be noted that 9.6 hours is based on the assumption that 1vCPU is loaded at 100 percent or 2vCPU at 50 percent.
(respectively baseline 20% x2 or 40% x1)
2vCPU on medium, both with 100% load can work no more than 4.8 hours a day.
Performance
For comparison, the table. it should be borne in mind that t1.micro, m1.small, m1.medium in it are calculated on the basis of an annual prepayment based on a high load, and new instances can be improved at any time, or vice versa.
Instance type | Effective price per hour | RAM | vCPU |
---|---|---|---|
t1.micro | 0.012 $ | 0.615GB | 1 |
t2.micro | 0.013 $ | 1GB | 1 |
m1.small | 0.024 $ | 1.7GB | 1 |
t2.small | 0.026 $ | 2GB | 1 |
m1.medium | 0.048 $ | 3.75GB | 1 |
t2.medium | 0.052 $ | 4GB | 2 |
The prices for the old instances are taken from the ec2 instances marketplace today, most recently these prices were much higher, therefore, in general, the current generation is faster and cheaper if there is no round-the-clock load and there is no need for own instance disks, the new server types only support EBS.
By the way, Amazon is canceling the old server types, such as: t1.micro, m1.small, m1.medium. They can still be taken to the EC2 marketplace, but in general, they are considered obsolete.
Throttling
It’s no secret that t1 was already with throttling, in fact I suspect that the first letter in the name of the instances came from here, but in its case the information on how the maximum allowable performance will decrease was not disclosed, now everything is clear and even with cloudwatch metrics.
There are separate metrics for the balance of loans and their use. What's in the compartment with the fact that there is no longer any need to make an advance payment (upfront) for servers of this class, it makes it possible to build an automatically scalable configuration that actually follows the long-standing slogan - "Pay only for use."
Profit
By the way, the vast majority of servers, access to the body of which I have are invested in the limitations of t2.medium instances, I think I’m not the only one and putting these servers into operation is a very, very good alternative to dancing with a tambourine around light / medium / heavy utilisation.
Actually, it’s not even an alternative, but a clear winner, since for many, the calculation of “take for a year” is often not flexible enough, because it is not known what awaits there. Now it’s much easier to count in this segment.
It remains to wait for at least t3.x2large to appear, for projects where load peaks are frequent, resource-demanding, but short-lived.
Official page: docs.aws.amazon.com/AWSEC2/latest/UserGuide/t2-instances.html