Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
adot-collectorを本番環境に導入してみた
Search
clouddev-code
September 26, 2023
780
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
adot-collectorを本番環境に導入してみた
clouddev-code
September 26, 2023
More Decks by clouddev-code
See All by clouddev-code
Regional_NAT_Gatewayについて_basicとの違い_試した内容スケールアウト_インについて_IPv6_dual_networkでの使い分けなど.pdf
cloudevcode
1
920
Grafana_LokiをECS_Fargateで構築する観点公開版.pdf
cloudevcode
0
49
ADK_for_Java.pdf
cloudevcode
1
100
initContainerをECSで実現したい.pdf
cloudevcode
0
40
VPC_Lattice検討したが_採用しなかった話.pptx.pptx.pdf
cloudevcode
0
32
Presentation_-_コンテナイメージ高速化技術.pptx.pdf
cloudevcode
0
40
GitHub_Copilot_AgentでするMCP_Streamable_HTTPまで.pdf
cloudevcode
0
120
EKS_Auto_Mode_Deep_Live.pdf
cloudevcode
0
61
re_invent_2024アップデートで実現可能なアーキテクチャを考える.pdf
cloudevcode
1
320
Featured
See All Featured
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
320
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
62
44k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
800
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
550
First, design no harm
axbom
PRO
2
1.2k
How Software Deployment tools have changed in the past 20 years
geshan
0
34k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
610
VelocityConf: Rendering Performance Case Studies
addyosmani
333
25k
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.3k
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
340
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
28
3.6k
Transcript
adot-collectorを本番環境に導入してみた
About us Soushi Hiruta コンテナを活用したマイクロサービス基盤設計、構築 SPA、BackendAPI基盤設計、構築 AWS CDK歴 1.5年ほど
CodeCatalystのDev Environmentsでpythonがaliasバージョン固定されている CodeCatalystのDev Environmentsでpyenvで別のバージョンいれても。。。 CodeCatalystのDev EnvironmentsはAmazonLinux2 /etc/profile.d/python3_default.sh
Agenda • 可観測性 • マイクロサービスでの可観測性の課題 • 収集方法 • 構成図 •
変更前 • 変更前の課題 • AWS Distro for OpenTelemetry Collector • 構成図 • 本番環境に適用して発生した課題 • まとめ
可観測 • マイクロサービス的システムでは分散システムになって、メトリクス だけは不十分 AWS Distro for OpenTelemetryを試してみた https://zenn.dev/kobayashi_m42/articles/try-aws-distro-for-opentelemetry
可観測
解決策
収集方法 • Cloudwatch Agent • AWS Distro for Open Telemetry
( ADOT )
全体構成図 CloudwatchAgent
CloudwatchAgent • ヒストグラムに対応していない、jvm metricsなどコンテナ単位で収 集しているので、長期的な傾向がみずらい • Cloudwatch logs、カスタムメトリクスの課金 •
AWS Distro for Open Telemetry
構成図 •
コンフィグ https://github.com/aws-observability/aws-otel-collector/blob/main/config/ecs/ecs-amp-prometheus.yaml メトリクス取得間隔、取得先の設定 左の例だと20s間隔で取得
コンフィグ https://github.com/aws-observability/aws-otel-collector/blob/main/config/ecs/ecs-amp-prometheus.yaml AMP Amazon Managed Prometheusの エンドポイントを設定
コンフィグ https://github.com/aws-observability/aws-otel-collector/blob/main/config/ecs/ecs-amp-prometheus.yaml Containerinsightsで取得できるcpu、メモ リも取得できる
コンフィグ https://github.com/aws-observability/aws-otel-collector/blob/main/config/ecs/ecs-amp-prometheus.yaml 受信(receivers)、処理(processors)、 exporterの設定を行う
AMPメトリクスのグラフ化 https://docs.aws.amazon.com/prometheus/latest/userguide/AMP-onboard-query-standalone-grafana.html Amazon managed for Grafanaなど利用する。 AWS Signature Version 4
(SigV4) authenticationに対応したGrafanaである必要あり
問題ないようにみえたが。。。 •
• メモリ使用量が右肩上がり。。。
Memory Limiter Processor https://github.com/open-telemetry/opentelemetry-collector/tree/main/processor/memorylimiterproce ssor#memory-limiter-processor
Memory Limiter Processor https://github.com/open-telemetry/opentelemetry-collector/tree/main/processor/memorylimiterproce ssor#memory-limiter-processor
Memory Limiter Processor https://github.com/open-telemetry/opentelemetry-collector/tree/main/processor/memorylimiterproce ssor#memory-limiter-processor processorsに、memory_limiterをいれ る
まとめ • • ADOT sidecarを利用することでenvoy metrics、jvm metricsなど をAmazon managed for
prometheusにエクスポートできる • sidecarのメモリ制限は必須
紹介したリファレンス • • オブザーバビリティ・エンジニアリング https://www.oreilly.co.jp/books/9784814400126/ • WS Distro
for OpenTelemetryを試してみた https://zenn.dev/kobayashi_m42/articles/try-aws-distro-for-opentelemetry • https://github.com/aws-observability/aws-otel-collector • https://github.com/open-telemetry/opentelemetry-collector/tree/main/processor/memorylimite rprocessor#memory-limiter-processor •