AWS Compute Optimizer
Machine learning over your CloudWatch utilisation history plus the resource's own configuration, turned into one verdict per resource: under-provisioned, over-provisioned or optimized, with a concrete instance type to move to. Free, opt-in, and the answer to almost every "right-size this fleet" question.
Machine learning chạy trên lịch sử utilisation trong CloudWatch cộng với cấu hình của chính tài nguyên, cho ra một kết luận cho mỗi tài nguyên: under-provisioned, over-provisioned hay optimized, kèm loại instance cụ thể nên chuyển sang. Miễn phí, phải bật, và là câu trả lời cho gần như mọi câu hỏi kiểu "right-size cả fleet này".
Reach for it / not the right toolKhi nào dùng / khi nào không
Reach for Compute OptimizerChọn Compute Optimizer
- "Right-size the fleet with least operational effort" — turn it on, read the findings, act."Right-size cả fleet với ít công vận hành nhất" — bật lên, đọc kết luận, làm theo.
- You need recommendations for more than EC2 — EBS volumes, Lambda memory, Fargate task sizing.Cần khuyến nghị cho nhiều hơn EC2 — EBS volume, memory của Lambda, kích thước task Fargate.
- Performance complaints where you suspect the instance is simply too small — this names the finding under-provisioned.Có phàn nàn về hiệu năng và bạn nghi instance đơn giản là quá nhỏ — nó gọi thẳng tình trạng đó là under-provisioned.
- You want the raw data: export every recommendation to S3 and query it with Athena for a chargeback report.Muốn dữ liệu thô: xuất mọi khuyến nghị ra S3 rồi query bằng Athena để làm báo cáo chargeback.
Not the right toolKhông phải chỗ dùng
- Buying commitments — Savings Plans and RI coverage/utilisation live in Cost Explorer, not here. Right-size first, then commit.Mua cam kết — Savings Plans và độ phủ/sử dụng RI nằm ở Cost Explorer, không phải ở đây. Right-size trước, rồi mới cam kết.
- Actually applying the change. It recommends; it never resizes anything. Rollout is your job (or SSM Automation / an ASG launch template update).Thực sự áp dụng thay đổi. Nó chỉ khuyến nghị, không bao giờ tự đổi size. Triển khai là việc của bạn (hoặc SSM Automation / cập nhật launch template của ASG).
- Anything with no utilisation history — brand-new or rarely-run resources get "no recommendation" until enough data accumulates.Thứ gì chưa có lịch sử utilisation — tài nguyên mới toanh hoặc ít chạy sẽ nhận "no recommendation" cho tới khi đủ dữ liệu.
- Broad account hygiene — idle load balancers, unassociated EIPs, low-utilisation checks in general are Trusted Advisor territory.Vệ sinh account nói chung — load balancer nhàn rỗi, EIP không gắn vào đâu, các check utilisation thấp nói chung là địa hạt của Trusted Advisor.
Memory is the blind spotMemory là điểm mù
Compute Optimizer only ever sees what CloudWatch holds. The hypervisor hands over CPU, network and disk for free — it cannot see inside the guest OS, so RAM only exists if the CloudWatch agent puts it there. Compute Optimizer chỉ thấy được những gì CloudWatch có. Hypervisor cung cấp sẵn CPU, network và disk — nó không nhìn được vào bên trong guest OS, nên RAM chỉ tồn tại nếu CloudWatch agent đẩy lên.
Same service, two different qualities of answer. Without the agent it is guessing at RAM, so a memory-bound app looks idle on CPU and gets recommended down — the recommendation that breaks production.
Cùng một service, nhưng chất lượng câu trả lời khác hẳn. Không có agent thì nó đoán mò về RAM, nên một app nghẽn memory trông như rảnh CPU và bị khuyên giảm size xuống — đúng loại khuyến nghị làm sập production.
What it looks atNó nhìn vào những gì
Remember the original four — EC2, ASGs, EBS, Lambda — and remember that Fargate services and RDS were added later. Each one gets its own kind of recommendation, not just "smaller instance". Nhớ bộ bốn ban đầu — EC2, ASG, EBS, Lambda — và nhớ rằng service trên Fargate và RDS được thêm vào sau. Mỗi loại có kiểu khuyến nghị riêng, không chỉ là "instance nhỏ hơn".
Compute Optimizer vs Cost Explorer vs Trusted AdvisorCompute Optimizer, Cost Explorer và Trusted Advisor
All three will hand you a "you're wasting money on EC2" list, which is exactly why the exam pits them against each other. The separator is scope and what it optimises for. Cả ba đều đưa ra danh sách "bạn đang phí tiền cho EC2", và đó chính là lý do đề thi cho chúng đối đầu nhau. Điểm phân biệt là phạm vi và tối ưu cho cái gì.
| Compute Optimizer | Cost Explorer right-sizingRight-sizing của Cost Explorer | Trusted Advisor | |
|---|---|---|---|
| ResourcesTài nguyên | EC2, ASGs, EBS, Lambda, Fargate services, RDSEC2, ASG, EBS, Lambda, service Fargate, RDS | EC2 onlyChỉ EC2 | a broad sweep of services, shallow per servicequét rộng nhiều service, nhưng nông ở từng service |
| Optimises forTối ưu cho | cost and performance — will recommend sizing upchi phí và hiệu năng — sẵn sàng khuyên tăng size | cost — framed as estimated monthly savingschi phí — trình bày dưới dạng tiết kiệm hàng tháng ước tính | cost, plus security, fault tolerance, limits, performancechi phí, cộng bảo mật, chịu lỗi, hạn mức, hiệu năng |
| MethodCách làm | ML over utilisation history + configurationML trên lịch sử utilisation + cấu hình | utilisation joined to your billing datautilisation ghép với dữ liệu billing của bạn | fixed threshold checks — "idle instance", "low utilisation"check theo ngưỡng cố định — "instance nhàn rỗi", "utilisation thấp" |
| Cost to useChi phí sử dụng | free, opt-inmiễn phí, phải opt-in | free with Cost Explorermiễn phí cùng Cost Explorer | full cost checks need Business/Enterprise Supportbộ check chi phí đầy đủ cần Business/Enterprise Support |
| Reach for it whenDùng khi | "right-size the fleet, don't hurt performance""right-size cả fleet, đừng làm hỏng hiệu năng" | "how much would downsizing EC2 actually save?""giảm size EC2 thì thực sự tiết kiệm bao nhiêu?" | "find obviously idle or wasted resources, org-wide""tìm tài nguyên rõ ràng là nhàn rỗi hoặc lãng phí, toàn org" |
Things that catch you outNhững chỗ dễ vấp
- Nothing happens until you opt in. An empty dashboard is almost always "never enabled", not "everything is optimized". From an Organizations management account you can opt in for all member accounts at once — do that, then wait. Không bật thì không có gì xảy ra. Dashboard trống gần như luôn có nghĩa là "chưa từng bật", chứ không phải "mọi thứ đều tối ưu". Từ management account của Organizations có thể bật cho tất cả member account một lượt — làm vậy, rồi chờ.
- It needs history. Results are not instant after opt-in, and a resource with too little utilisation data gets no recommendation rather than a bad one. Longer lookback windows are available but they are a paid option. Nó cần lịch sử. Bật xong không có kết quả ngay, và tài nguyên quá ít dữ liệu utilisation sẽ không có khuyến nghị chứ không phải khuyến nghị sai. Có tuỳ chọn nhìn lại xa hơn nhưng phải trả phí.
- It never changes anything. Findings are advice. Acting on them means an instance stop/start or replacement, a launch template revision, or a new Lambda memory setting — with the downtime and testing that implies. Nó không bao giờ tự thay đổi gì. Findings chỉ là lời khuyên. Làm theo nghĩa là stop/start hoặc thay instance, sửa launch template, hoặc đổi memory của Lambda — kèm downtime và việc test đi cùng.
- A right-sizing move can strand a commitment. Downsizing instances covered by Reserved Instances or a Compute Savings Plan can leave you paying for coverage you no longer use. Check coverage in Cost Explorer before a mass resize. Right-size có thể làm kẹt cam kết đã mua. Giảm size những instance đang được Reserved Instance hoặc Compute Savings Plan phủ có thể khiến bạn trả tiền cho phần phủ không còn dùng. Kiểm tra độ phủ trong Cost Explorer trước khi resize hàng loạt.
- Bursty and seasonal workloads read as over-provisioned. A month-end batch box looks idle for 27 days. Read the performance risk score and the projected utilisation graphs before trusting the headline. Workload dạng burst hoặc theo mùa sẽ bị đọc thành over-provisioned. Máy chạy batch cuối tháng trông rảnh suốt 27 ngày. Hãy đọc điểm performance risk và biểu đồ utilisation dự kiến trước khi tin vào kết luận ngoài bìa.
Exam reflexesPhản xạ khi thi
| The question says…Đề nói… | AnswerTrả lời |
|---|---|
| "Recommendations must consider memory utilisation""Khuyến nghị phải xét tới memory utilisation" | Install the CloudWatch agent — the only source of RAM dataCài CloudWatch agent — nguồn duy nhất có dữ liệu RAM |
| "Right-size EC2, EBS and Lambda with least effort""Right-size EC2, EBS và Lambda với ít công nhất" | Compute Optimizer — Cost Explorer covers EC2 onlyCompute Optimizer — Cost Explorer chỉ lo EC2 |
| "Users report the app is slow; is the instance too small?""Người dùng kêu app chậm; instance có quá nhỏ không?" | Compute Optimizer finding under-provisioned — it optimises performance tooFinding under-provisioned của Compute Optimizer — nó cũng tối ưu hiệu năng |
| "Feed the recommendations into our own reporting pipeline""Đưa khuyến nghị vào pipeline báo cáo của chúng tôi" | Export to S3, then Athena / QuickSight over the exportXuất ra S3, rồi Athena / QuickSight đọc file xuất đó |
| "Find idle instances and unused load balancers account-wide""Tìm instance nhàn rỗi và load balancer không dùng trên toàn account" | Trusted Advisor — threshold checks, not ML sizingTrusted Advisor — check theo ngưỡng, không phải ML sizing |
| "Dashboard is empty across the organization""Dashboard trống trơn trên toàn organization" | Never opted in — enable from the management account, then wait for dataChưa opt in — bật từ management account, rồi chờ dữ liệu |