

換成 t4g.small 後的一些整理
source link: https://blog.gslin.org/archives/2024/02/08/11643/%e6%8f%9b%e6%88%90-t4g-small-%e5%be%8c%e7%9a%84%e4%b8%80%e4%ba%9b%e6%95%b4%e7%90%86/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

換成 t4g.small 後的一些整理
昨天在這邊提到因為 Amazon EC2 對 t4g.small
提供了 free tier 方案 (到今年年底),blog 主機剛好從 t4g.micro
改成用 t4g.small
,到年底前可以看看有沒有 t5g
或是類似的主機出來:「往上升級或是用 Unlimited mode 撐」。
除了換完後 CPU credit 給的量上升減緩了情況以外,我在檢查時才發現 PHP 的 opcache 的 cache 使用量也超過預設值 128MB 了,改成 192MB 後看起來 CPU usage 也有下降一些:

這點算是先前沒注意到的,上面 PHP 跑兩個 WordPress 以及一個 MediaWiki (都掛了各式各樣的 plugin & extension),還有一個自己寫的小東西,這樣會超過 opcache 的 cache 大小...
現在換到 t4g.small
後總算又開始養的起 CPU credit 了:

另外也補上幾個 CloudWatch Alarms (看起來 free tier 是十個) 監控主機的 CPUCreditBalance
,然後透過 AWS Chatbot 接到自己的 Slack 上,至少之後有狀況的時候會主動通知。
Related
往上升級或是用 Unlimited mode 撐
這個 blog 跑在 Amazon EC2 的 t4g.micro 上面,以往跑起來 baseline 是 10% CPU credit 也還算夠用,但最近的 loading 特別的大,發現是有 bot 在砍站砍的比較兇 (參考「t4g 的 CPU credit 被吃完了」這邊),雖然擋掉後有降不少,但看起來還是比之前高不少:(這邊是一天的平均,拉三個月資料來看) 以往這種一陣一陣的可以靠 CPU credit 頂過去,但因為先前 CPU credit 被 bot 砍完後沒了,就常常撞到底,只好先開 Unlimited mode 擋著了。 另外一方面,當初買的三年 RI 時間也快到了 (居然),這幾天差不多要處理了: Start February 9, 2021, 17:43 (UTC+8:00) Expires February 9, 2024, 17:43…
February 7, 2024In "AWS"
AWS 延長 t4g.small 的 free trial
在 Plurk 上看到朋友貼的「Announcing Amazon EC2 T4g Free Trial Extension」。 t4g.small 的 free trial 延長到明年年底了: The Amazon Elastic Compute Cloud (Amazon EC2) T4g instance Free Trial is extended to December 31, 2024. All new and existing AWS customers can utilize the free trial to automatically deduct up to 750 hours per…
December 24, 2023In "AWS"
在 AWS 上面的 OpenVPN Server 效能
這篇的後續可以參考「Amazon EC2 的網路效能」這篇。 最近在在調整跑在 Amazon EC2 上 OpenVPN server 的效能,要想辦法把 network throughput 拉高,當作在導入 WireGuard 之前的 workaround,但看起來還是頗有用,記錄一下可以調整的部份... 在還沒灌大量流量前是用 t3a.nano (開 Unlimited mode),然後會觀察到的瓶頸是 OpenVPN 的 daemon 吃了 100% CPU loading,最高速度卡在 42MB/sec 左右。 第一個想到的是看看 OpenVPN server 有沒有可以使用多 CPU 的方式,但查了資料發現 OpenVPN server 無法使用 threading 或是 fork 之類的方法善用多顆 CPU,所以就開始想其他方法... 接著看到我們目前用的是 AES-256-CBC 了,網路上很多文章都有提到 AES-128-CBC 會快一些,但我們的 OpenVPN…
August 4, 2021In "AWS"
Author Gea-Suan LinPosted on February 8, 2024February 8, 2024Categories AWS, Cloud, Computer, Hardware, Murmuring, Network, ServiceTags amazon, arm, aws, blog, cloud, cpu, credit, ec2, micro, performance, php, service, small, t4g, wordpress
Leave a Reply
Your email address will not be published. Required fields are marked *
Comment *
Name *
Email *
Website
Notify me of follow-up comments by email.
Notify me of new posts by email.
To respond on your own website, enter the URL of your response which should contain a link to this post's permalink URL. Your response will then appear (possibly after moderation) on this page. Want to update or remove your response? Update or delete your post and re-enter your post's URL again. (Learn More)
Post navigation
Recommend
-
3
Hacker News:非常棒的针对编程的链接聚合网站Programming reddit:同上MSDN:微软相关的官方技术集中地,主要是文档类infoq:企业级应用,关注软件开发领域OSChina:开源技术社区,开源方面做的不错哦cnblo...
-
9
作者:葱爷,首发:葱爷原标题:日本设计的图片排版才是真正值得学习的阅前叨逼叨:这些图片排版技巧值得学习。说到日本的平面设计,我们很容易想到他们的海报设计,有很...
-
12
V2EX › 程序员 用 XMind 整理了 Linux 操作系统,网络, C++, Golang 以及数据库的一些设计,希望大家喜欢。
-
4
2020整理的一些面经连接 Bomb_ · 2020-05-15 14:35:40 · 9054 次点击 · 预计阅读时间不到 1 分钟 · 大约8小时之前 开始浏览 ...
-
23
整理记录一些好用的随机图API - SegmentFault 思否fx67ll.com23 声望1 粉丝你知道吗?程序错误中,80% 是语法错误,16%...
-
11
Linux Kernel 裡的 RNG 從 SHA-1 換成 BLAKE2s 從 Hacker News Daily 上看到的消息,Linux Kernel 裡的
-
16
Golang 的排序演算法將換成 pdqsort,LLVM libc++ 換成 BlockQuicksort 在 Hacker News 首頁上看到的消息,Golang 將會把
-
3
華盛頓郵報怎麼把 Mapbox 換成其他 open source 方案 在 Hacker News 上面看到「
-
12
AWS 延長 t4g.small 的 free trial 在 Plurk 上看到朋友貼的「
-
3
t4g 的 CPU credit 被吃完了 這個站 blog.gslin.org 掛了三個多小時:
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK