Twitter 上看到朋友提到 t3
系列的機器有保留七天的 CPU credit:
t3 的機器可以保留七天的 CPU 點數,這設計滿有趣
— adaam (@adaam) April 26, 2021
在「CPU credits and baseline utilization for burstable performance instances」這邊有提到,t3
/t3a
/t4g
的設計都是讓你可以塞 24h 小時的量:

這邊講的七天是這段:
CPU credits on a running instance do not expire.
For T2, the CPU credit balance does not persist between instance stops and starts. If you stop a T2 instance, the instance loses all its accrued credits.
For T3 and T4g, the CPU credit balance persists for seven days after an instance stops and the credits are lost thereafter. If you start the instance within seven days, no credits are lost.
開著的機器的 CPU credit 不會過期,只會到最大上限 (在同一篇文件裡面的表格有提到),t2
的機器關掉後 (stop) CPU credit 就會直接消失,而 t3
/t3a
/t4g
則在關掉後會保留七天。
之前沒注意到文件上的這點。
另外之前在測試自己架設 Sentry 時還測過 t3a.medium
-> r5a.large
-> t3a.medium
這樣換過去又換回來的情況,本來的 CPU credit 是可以繼續用的,看起來 CPU credit 不會因為 family type 改變就不見 (不過不確定這個是不是 undefined behavior...)。