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
CloudWatch&MonitoringTools
Search
youyo
May 21, 2016
Technology
1
250
CloudWatch&MonitoringTools
JAWS-UG函館20160521
youyo
May 21, 2016
Tweet
Share
More Decks by youyo
See All by youyo
家の快適度を計測してみた
youyo
1
180
Get started AWS CDK
youyo
0
91
Tried to create a deployment pipeline of AutoML Vision.
youyo
0
58
API GatewayのWebSocket対応について
youyo
0
690
GCRと脆弱性検査
youyo
0
180
goodbye-ec2
youyo
0
570
それでも僕はzabbixと生きていく
youyo
1
450
About AWS Lambda and kintone
youyo
1
240
TerraformとWerckerとAWS Organizationsで始めるステージング・開発環境構築 / terraform-wercker-aws-organizations
youyo
1
34k
Other Decks in Technology
See All in Technology
社内で最大の技術的負債のリファクタリングに取り組んだお話し
kidooonn
1
550
Can We Measure Developer Productivity?
ewolff
1
150
Platform Engineering for Software Developers and Architects
syntasso
1
520
Amazon CloudWatch Network Monitor のススメ
yuki_ink
1
200
信頼性に挑む中で拡張できる・得られる1人のスキルセットとは?
ken5scal
2
530
OCI Security サービス 概要
oracle4engineer
PRO
0
6.5k
【Startup CTO of the Year 2024 / Audience Award】アセンド取締役CTO 丹羽健
niwatakeru
0
990
適材適所の技術選定 〜GraphQL・REST API・tRPC〜 / Optimal Technology Selection
kakehashi
1
170
Amplify Gen2 Deep Dive / バックエンドの型をいかにしてフロントエンドへ伝えるか #TSKaigi #TSKaigiKansai #AWSAmplifyJP
tacck
PRO
0
380
TypeScript、上達の瞬間
sadnessojisan
46
13k
【令和最新版】AWS Direct Connectと愉快なGWたちのおさらい
minorun365
PRO
5
750
Engineer Career Talk
lycorp_recruit_jp
0
160
Featured
See All Featured
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
26
2.1k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
26
1.4k
A Modern Web Designer's Workflow
chriscoyier
693
190k
The Invisible Side of Design
smashingmag
298
50k
Reflections from 52 weeks, 52 projects
jeffersonlam
346
20k
GitHub's CSS Performance
jonrohan
1030
460k
A better future with KSS
kneath
238
17k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
364
24k
How GitHub (no longer) Works
holman
310
140k
Making the Leap to Tech Lead
cromwellryan
133
8.9k
Transcript
CloudWatchͱϞχλϦϯάπʔϧ
Έͳ͞Μ
ࢹͯ͠·͔͢ʁ
CloudWatchόϦόϦͬͯΔͥʂ
ผͷϞχλϦϯάπʔϧ Έ߹Θͤ·͘Γͩͥʂ
ͱ͍͏ํɺ
ͷ͓͔ΒಘΒΕΔͷͳ͍͔͠Ε·ͤΜ...
ͦ͏͡Όͳ͍ํɺ
গ͠Ͱ͓ʹཱͯΕ͍Ͱ͢ɻ
ࠓ͢͜ͱ
"͢͜ͱ" » CloudWatch » CloudWatch-Logs » CloudWatch-Events » ͪΐͬͱ͚ͩZabbix(ϞχλϦϯάπʔϧ) »
cloudwatchͱZabbixͱͦͷଞAWSͷαʔϏεͷ࿈ ܞ
"͢͜ͱ" » ͜Μͳͱ͖Ͳ͏͢Δʁ » OSͷ෦ใΛऔಘ͍ͨ͠(ϓϩηεͱ͔) » RDSͷࢹΛ͍ͨ͠ » cloudwatchͷσʔλΛ2िؒҎ্อଘ͍ͨ͠ »
ϝϯςφϯεΠϕϯτΛݕ͍ͨ͠ » ϩάͷࢹΛ͍ͨ͠ » URLࢹ͍ͨ͠
"͞ͳ͍͜ͱ" » ͦͷଞAWSͷαʔϏεͷৄࡉͳઆ໌
"ࣗݾհ" » ੴᖒਓ (@youyo_) » גࣜձࣾϔϓλΰϯ ࡾຊࣾ/ઋࣄॴ » ੨ݝ߂લࢢग़ ٶݝઋࢢࡏॅ
ϦϞʔτϫʔΫͯ͠·͢ » JAWS-UG੨ 6/25Γ·͢ʂ
CloudWatch
"CloudWatch" » AWSͷ֤छαʔϏεͷϦιʔεΛऔಘͰ͖Δ » Ϧιʔεʹରͯ͠ΞϥʔϜΞΫγϣϯΛઃఆͰ͖Δ » ֤छαʔϏεͷϦιʔεΛՄࢹԽ(άϥϑԽ)Ͱ͖Δ
"CloudWatch" » AWSͷ֤छαʔϏεͷϦιʔεΛऔಘͰ͖Δ » EC2RDSͷΠϯελϯεͷঢ়ଶࢹCPU༻ ͱ͔ » S3ͷΦϒδΣΫτͱ͔ » ELBͷϨΠςϯγͱ͔ਖ਼ৗ/ҟৗϗετͱ͔
"CloudWatch" » CloudWatchͰऔಘͰ͖ΔσʔλΛ͏গ͠ࡉ͔͘ݟ ͍ͯ͘ͱ » CPU༻(CPUUtilization)ͱ͍͏߲ = Metrics » EC2ͱ͍͏αʔϏε
= Namespace » MetricsΛಛఆͷͰΧςΰϥΠζ͢Δͷ = Dimension ͜ͷ̏ͭΛࢦఆ͢Δ͜ͱͰతͷσʔλ͕ݟΕΔ Ωʔϫʔυ: Metrics,Namespace,Dimension
"Metrics?,Namespace?,Dimension?" » Metrics » ࣌ܥྻͰදͨ͠σʔλϙΠϯτҰࣜ » ͜Ε͚ͩݴΘΕͯԿͷ͜ͱ͔ͬ͞ͺΓΘ͔Βͳ ͍...? » ͱΓ͋͑ͣछྨͱͯ͜͠͏͍͏ͷ͕͋Δ
» CPUUtilization » FreeableMemory
"Metrics?,Namespace?,Dimension?" » Metrics
"Metrics?,Namespace?,Dimension?" » Namespace » MetricsΛ·ͱΊͨͷ » ௨ৗAWSͷαʔϏεͷ͜ͱ » AWS/EC2 »
AWS/RDS
"Metrics?,Namespace?,Dimension?" » Metrics + Namespace
"Metrics?,Namespace?,Dimension?" » Dimension » MetricsΛಛఆͷͰΧςΰϥΠζ͢Δͷ » InstanceID » DBInstanceIdentifier
"Metrics?,Namespace?,Dimension?" » Metrics + Namespace + Dimension
"Metrics?,Namespace?,Dimension?" » ಛఆͷ࣌ؒ hh:mm ͷRDS[foo]ͷCPU༻ͷσʔ λ͜͜
"Metrics?,Namespace?,Dimension?" » ϚωδϝϯτίϯιʔϧͰݟΔͱ
"Metrics?,Namespace?,Dimension?" » ඪ४ϝτϦΫεʁ
"CloudWatch" » ϝτϦΫεʹ2छྨ͋Δ » ඪ४ϝτϦΫε » ΧελϜϝτϦΫε
"CloudWatch" » ඪ४ϝτϦΫε » AWSͰ༻ҙͯ͘͠ΕͯΔͷ » CPUUtilization » DiskWriteBytes »
StatusCheckFailed_Instance » ͨ͘͞Μ͋Δ
"CloudWatch" » ΧελϜϝτϦΫε » ඪ४ϝτϦΫεҎ֎ͷಠࣗʹઃఆ͢ΔϝτϦΫε » APIܦ༝ͰఆٛՄೳ $ aws cloudwatch
put-metric-data \ --namespace "MyService" \ --metric-name "ProcessCount" \ --dimensions InstanceId=i-xxxxxxxx \ --value 15
"CloudWatch" » ΧελϜϝτϦΫε
"CloudWatch" » ΧελϜϝτϦΫε » σʔλαΠζʹ੍ݶ͕͋Δ » HTTP GET8KB » HTTP
POST40KB » 1ͭͷPutMetricsDataϦΫΤετʹ20σʔλ· Ͱ » APIίʔϧʹ੍ݶ͋Γ
"CloudWatch" » CloudWatchͰݟΕΔใ౷ܭใ » ϝτϦΫεσʔλΛࢦఆͨ͠ظؒͰूܭͨ͠ͷ » CPUUtilizationͷ5ؒ͝ͱͷฏۉΛදࣔ͠ ͯΔ
"CloudWatch" » CloudWatchͰݟΕΔใ౷ܭใ » ϝτϦΫεσʔλΛࢦఆͨ͠ظؒͰूܭͨ͠ͷ » EC2ͰجຊϞχλϦϯάͰ5ִؒ » ৄࡉϞχλϦϯά(༗ঈ)Ͱ1ִؒ »
ͦΕҎ֎ͷϝτϦΫεϝτϦΫεຖʹσʔλͷߋ ৽ִ͕ܾؒΊΒΕͯΔ » σʔλͷอଘظؒ2िؒ
"CloudWatch" » AWSͷ֤छαʔϏεͷϦιʔεʹର͢ΔΞϥʔϜΛઃ ఆͰ͖Δ » EC2RDSͷΠϯελϯεͷঢ়ଶࢹCPU༻ ͱ͔ » S3ͷΦϒδΣΫτͱ͔ »
ELBͷϨΠςϯγͱ͔ਖ਼ৗ/ҟৗϗετͱ͔
"CloudWatch" » Ϧιʔεʹରͯ͠ΞϥʔϜΞΫγϣϯΛઃఆͰ͖Δ » ݅Λઃఆͯ͠ɺͦΕΛຬͨͨ͠ΒΞΫγϣϯΛ࣮ ߦͰ͖Δ » CPUUtilization͕5ؒ70%Ҏ্Λهͨ͠ Β »
EC2Πϯελϯεͷεςʔλε͕failedʹͳͬ ͨΒ » ͖ͳΑ͏ʹઃఆͰ͖Δ
"CloudWatch" » EC2 Auto Recovery » γεςϜεςʔλε͕failedͳͬͨΒࣗಈͰ࠶ى ಈ͞ΕΔ
"CloudWatch" » Ϧιʔεʹରͯ͠ΞϥʔϜΞΫγϣϯΛઃఆͰ͖Δ » ΞΫγϣϯNotification(SNSɺEmail)ɺ EC2 ActionAutoScaling ActionͳͲ४උ ͞Ε͍ͯΔ »
ͱΓ͋͑ͣSNSʹ͓͚ͯͦ͠ͷޙAWS Lambda ͬͯͲ͏ͱͰͰ͖Δ
"CloudWatch" » ֤छαʔϏεͷϦιʔεΛՄࢹԽ(άϥϑԽ)Ͱ͖Δ » ࣗ༝ʹϝτϦΫεΛΈ߹ΘͤͨμογϡϘʔυ͕ ࡞ΕΔ
"CloudWatch" » ֤छαʔϏεͷϦιʔεΛՄࢹԽ(άϥϑԽ)Ͱ͖Δ » ࣗ༝ʹϝτϦΫεΛΈ߹ΘͤͨμογϡϘʔυ͕ ࡞ΕΔ » Create Dashboard =>
Add widget » WidgetʹMetrics graphͱText widgetͷ 2छྨ͋Δ » Text widgetʹmarkdownܗࣜͷจষΛ࡞ΕΔ
CloudWatch-Logs
"CloudWatch-Logs" » AWSͷͦͷଞαʔϏε͕ग़ྗ͢Δϩάͷूઌ » CloudWatch Logs AgentΛ͏͜ͱͰEC2Πϯε λϯε෦ͷϩάͷूՄೳ » CloudWatch
Logs Metrics Filter Ͱϩά͔Β ಛఆจࣈྻͷϑΟϧλϦϯά͕Մೳ » ϑΟϧλϦϯά݁ՌΛड͚औΔΧελϜϝτϦΫε Λ࡞͠ɺCloudWatchͷΞϥʔϜػೳͱΈ߹ ΘͤͯΞΫγϣϯΛ࣮ߦՄೳ
"CloudWatch-Logs" » AWSͷͦͷଞαʔϏε͕ग़ྗ͢Δϩάͷूઌ » AWS LambdaVPC Flow LogsͳͲ » ٯʹݴ͏ͱɺAWSͷͦͷଞαʔϏε͕
CloudWatch-LogsͷpermissionٻΊͯ͘Δͷ ͰڐՄͯ͋͛͠ͳ͍ͱ͍͚ͳ͍
"CloudWatch-Logs" » CloudWatch Logs AgentΛ͏͜ͱͰEC2Πϯε λϯε෦ͷϩάͷूՄೳ » CloudWatch-Logsʹॻ͖ࠐΉͷͰpermission ઃఆ͕ඞཁ »
EC2 Role͔CloudWatch Logs AgentΠϯ ετʔϧޙͷΞΫηεΩʔઃఆ » AmazonLinuxͩͱΠϯετʔϧ؆୯ $ sudo yum install awslogs
"CloudWatch-Logs" » CloudWatch Logs Agent ҙ » సૹͰ͖ΔϩάϝοηʔδαΠζ » Agent͕1ճʹϓογϡͰ͖ΔαΠζ࠷େ
32KB » ͦΕΛ͑Δͱtruncate(Γ٧ΊΒΕΔ) » ରԠ͍ͯ͠Δϩάϩʔςʔγϣϯ » rename-recreatecopy-truncateͳͲ
"CloudWatch-Logs" » VPC Flow Logs
"CloudWatch-Logs" » CloudWatch Logs Metrics Filter Ͱϩά͔Β ಛఆจࣈྻͷϑΟϧλϦϯά͕Մೳ » ϑΟϧλϦϯά݁ՌΛड͚औΔΧελϜϝτϦΫε
Λ࡞͠ɺCloudWatchͷΞϥʔϜػೳͱΈ߹ ΘͤͯΞΫγϣϯΛ࣮ߦՄೳ
"CloudWatch-Logs" » Logs͔ΒϑΟϧλʔΛ࡞͍ͨ͠LogGroupΛબ͠ ͯCreateMetricsFilter
"CloudWatch-Logs" » ύλʔϯΛ࡞ͯ͠Assign Metrics
"CloudWatch-Logs" » MetricsͷৄࡉΛೖྗͯ͠CreateFilter͢Δ
"CloudWatch-Logs" » ϑΟϧλʔʹϚονͨ࣌͠ʹΧελϜϝτϦΫεσ ʔλ͕ૹΒΕΔΑ͏ʹͳΔ
"CloudWatch-Logs" » ར༻ྫ » CloudTrailͱ࿈ܞ͠ɺϚωδϝϯτίϯιʔϧ ͷૢ࡞ϩάΛCloudWatch-LogsʹૹΔ » rootΞΧϯτͰͷϩάΠϯɺ࿈ଓͨ͠ϩάΠ ϯࣦഊͳͲΛݕ͢ΔϑΟϧλʔΛ࡞ »
ͦΕΒʹϚονͨ͠ΒΧελϜϝτϦΫε͕ߋ৽͞ ΕͯΞϥʔϜൃੜ » ͓͖ͳΞΫγϣϯͰ௨
CloudWatch-Events
"CloudWatch-Events" » AWSϦιʔεͷมߋ(Πϕϯτ)Λݕͯ͠ɺετϦʔ Ϝୡ(ΞΫγϣϯΛى͜͢͜ͱ)͕Ͱ͖ΔαʔϏε » Πϕϯτ: EC2 instance state change
notification, AWS API Call, Auto Scaling, Schedule » ΞΫγϣϯ: AWS LambdaɺAmazon Kinesis StreamɺAmazon SNS, Bullet-inλʔήοτ » ϙʔϦϯάͰͷঢ়ଶࢹ͔Βͷղ์ » EventDrivenArchitectureͷத৺ʹͳΔͷ͔ͳʁ
"CloudWatch-Events" » EC2 instance state change notification » ಛఆɺ·͍ͨͣΕ͔ͷΠϯελϯεͷঢ়ଶʹมԽ ͕͋ͬͨΒετϦʔϜ
» runningʹͳͬͨΒɺͱ͔ɺrunningҎ֎ʹ ͳͬͨΒɺͳͲ » ঢ়ଶ͕stoppedʹͳͬͨΒrebootɺͱ͔ઃఆͰ ͖ͪΌ͏
"CloudWatch-Events" » AWS API Call, Auto Scalingಉ༷ » ΠϕϯτʹԠͯ͡ετϦʔϜ »
AWS API Call: RDSͷDeleteDBInstance͕ ݺΕͨΒͱ͔ » Auto Scaling: EC2 Launch Successfulͩ ͬͨΒͱ͔ » ࠓϝδϟʔͳαʔϏεʹ͔͠ରԠͯ͠ͳ͍͚Ͳࠓޙ ରԠαʔϏεΛ૿͢༧ఆ ͬͯawsͷϒϩάʹॻ͍ͯͨͷͰ૿͍͑ͯ͘ͱࢥ͏
"CloudWatch-Events" » Schedule » ཁcron » ࠷1ִؒͰΞΫγϣϯ࣮ߦ » ͜ΕͱAWS LambdaͰԿͰͰ͖Δͤ͠
✌('ω'✌ )ࡾ✌('ω')✌ࡾ( ✌'ω')✌
"CloudWatch-Events" » ΞΫγϣϯ » Bullet-inλʔήοτ » Create a Snapshot of
an EBS volume » Reboot EC2 instance » Terminate EC2 instance » Stop EC2 instance
"CloudWatch-Events" » ScheduleͱCreate a Snapshot of an EBS volumeΈ߹ΘͤͯຖεφοϓγϣοτࣗಈͰऔ ΕΔ
» ศརɻ͓खܰɻ » ͰSnapshotআʹରԠͯ͠ͳ͍ » আಉ͡Α͏ʹScheduleͰLambdaͰಈ͔ͯ͠ Ε͍͍
"CloudWatch-Events" » CloudWatchͷEvents͔ΒCreate͠ɺ EventSelectorͱTargetsΛઃఆ
"CloudWatch-Events" » NameͱదͳIAMRoleΛઃఆͯྃ͠
Zabbix
"Zabbix" » ossͷ౷߹ࢹιϑτΣΞ » ϑϩϯτΤϯυphp,όοΫΤϯυMySQL/ PostgresQL/SQLiteͱ͔ » ຊମCݴޠ » json-rpcͰapiૢ࡞Ͱ͖Δ
"Zabbix" » ઐ༻ͷZabbixAgentΛ༻ͯ͠OS෦ͷσʔλΛऔ ಘɺZabbixServerʹૹ৴ » ϓϩηεɺcpu/memoryͳͲͷϦιʔεใͳͲ
"Zabbix" » ࣗલͰΠϯελϯεཱͯͯӡ༻͢Δ͜ͱʹͳΔͷͰಛ ʹετϨʔδαΠζσʔλอଘظؒͳͲʹ੍ݶͳ ͍(͓ۚͷڐ͔͗͢Γ) » Ξϥʔτ௨ํ๏ࣗ༝ʹ࡞ΕΔ(alertscripts) » औಘ͢Δσʔλࣗ༝ʹ࡞ΕΔ (UserParameter,externalscripts)
» CloudWatchͷσʔλΛZabbixʹಥͬࠐΉ͜ͱͰσ ʔλอଘظؒ2िؒͷนΛಥഁʂ
"Zabbix" » CloudWatchͷσʔλΛZabbixʹ » APIܦ༝ » Fluentd » ଞʹ͓͖ͳΑ͏ʹ
"Zabbix" » APIܦ༝ » aws-sdk » aws-cli » UserParameter͔ΒεΫϦϓτΛݺͼग़ͯ͠σʔ λऔಘ͢Δύλʔϯ
» externalscriptsΛ࣮ߦͯ͠σʔλऔಘ͢Δύ λʔϯ
"Zabbix" » Fluentd » fluent-plugin-zabbix » fluent-plugin-cloudwatch » fluent-plugin-cloudwatchͰσʔλΛऔಘ͠ ͯfluent-plugin-zabbixͰZabbixʹૹΔ
"Zabbix" » RDS for MySQLͷσʔλ
"Zabbix" » RDS for MySQLͷσʔλ
"Zabbix" » σʔλΛZabbixʹ·ͱΊΔϝϦοτ » σʔλͷҰݩԽ » ௨ํ๏ҰݩԽ » σʔλอଘظؒͳͲͷ༷ࣗ༝ʹܾΊΒΕΔ »
ϝϯςφϯεͳͲࣗͰίϯτϩʔϧͰ͖Δ
"Zabbix" » Zabbixʹ·ͱΊΔσϝϦοτ » (Πϯελϯε͕ඞཁͳ)͓͕͔͔ۚΔ » CloudWatchͱࣗલZabbixɺͲ͕ͬͪݎ࿚͔ʁ » Πϯελϯεͷӡ༻େมͳͷͰʁ
"Zabbix" » Ͳ͏͍͏ํͰࢹ͍͔ͯ͘͠Α͘ߟ͑Δඞཁ͕͋Δ » ࠷ۙMackerelྲྀߦͬͯΔ͠AWSΠϯςάϨʔγϣ ϯग़ͨ͠ɺMonitoring as a Service͏ͷશ વ͋Γɻ
» ͦͦCloudWatch͕ͦΕͩ͠ɺCloudWatchʹ· ͱΊΔͷҰͭͷղ » ສ͕ҰCloudWatchʹোى͜ΔͱɺͦΕΛࣗͰ ίϯτϩʔϧͰ͖ͳ͍ɻࢹαʔϏεΛఏڙ͢Δฐࣾ ͱͯ͠NG
͜Μͳͱ͖Ͳ͏͢Δʁ
"͜Μͳͱ͖Ͳ͏͢Δʁ" » OSͷ෦ใΛऔಘ͍ͨ͠(ϓϩηεͱ͔) » RDSͷࢹΛ͍ͨ͠ » cloudwatchͷσʔλΛ2िؒҎ্อଘ͍ͨ͠ » ϝϯςφϯεΠϕϯτΛݕ͍ͨ͠ »
ϩάͷࢹΛ͍ͨ͠ » URLࢹ͍ͨ͠
"Warning!" » ฐࣾͰZabbixΛϝΠϯͷࢹγεςϜʹ࠾༻ͯ͠ ͍·͢ » ͦͷ্ͰฐࣾͰ͜͏͍ͯ͠Δɺͱ͍͏͓Ͱ͢ » ͦͷલఏͰ͓͕ਐΉͷͰͦͷྃ͝ঝ͍ͩ͘͞
"OSͷ෦ใΛऔಘ͍ͨ͠(ϓϩηεͱ͔)" » Zabbixͬͯૉʹσʔλऔಘ » proc.num ͱ͍͏ࢹΞΠςϜ͕༻ҙ͞Ε͍ͯΔ » CloudWatchΛ͍͍ͨਓΧελϜϝτϦΫεͰ » OSࣗମͷࢹجຊZabbix
"RDSͷࢹΛ͍ͨ͠" » ZabbixAgentΛRDSͷΑ͏ͳαʔϏεʹΠϯετʔ ϧͰ͖ͳ͍ » CloudWatchͷσʔλΛFluentdͬͯZabbixʹૹ ΓɺZabbixͰϞχλϦϯά » ͪΖΜCloudWatchͷΞϥʔϜػೳͰΞϥʔτ͋͛ Δ΄͏͕γϯϓϧ
"cloudwatchͷσʔλΛ2िؒҎ্อଘ͍ͨ͠" » Zabbixʹ·ͱΊΔ͜ͱͰղܾ » ࠷ۙͩͱDynamoDBʹஷΊ͓ͯ͘ύλʔϯ͋Δ༷ » ͨͩͦ͠ͷσʔλΛͦͷΑ͏ʹ͏ͷ͔ͪΌΜͱߟ ͑ͳ͍ͱ͍͚ͳ͍ » ͰʮͱΓ͓͔͋͑ͣͯ͠ͳ͍ͱޙͰඞཁʹͳΔ
͔͠Εͳ͍͠...ʯ͓͕ۚڐͤશવ͋Γͩͱ ࢥ͏ɻอݥΈ͍ͨͳͷɻ
"ϝϯςφϯεΠϕϯτΛݕ͍ͨ͠" » CloudWatch-Events + AWS Lambda + Slack » ࢦఆͨ͠ΞΧϯτͷશΠϯελϯεͷϝϯςφϯ
εΠϕϯτͷ༗ແΛνΣοΫ͢ΔLambda Function Λ࡞ » ͦΕΛCloudWatch-EventsͷScheduleͰ11ճ ࣮ߦ » ϝϯςφϯεΠϕϯτ͕͋ΕSlackʹ௨͍ͯ͠Δ
"ϝϯςφϯεΠϕϯτΛݕ͍ͨ͠"
"ϝϯςφϯεΠϕϯτΛݕ͍ͨ͠" » ZabbixͰਖ਼ৗʹಈ͍ͯΔ͔ͷࢹΛΓ͍ͨ » ࠓຖSlackʹಈ͍ͯ·͢Αʔ௨͖ͯΔ » ҟৗ͕͋ͬͨͱ͖͚ͩΘ͔Ε͍͍(ΊΜͲͯ͘͘͞ ࣮ͯ͠ͳ͍͚ͩ) » ࠓͷͱ͜ΖEC2ͱRDS͚ͩରԠɻElastiCacheͱ
͔...(ΊΜͲ࣮ͯͯ͘͘͞͠ͳ͍͚ͩ)
"ϩάͷࢹΛ͍ͨ͠" » OSͷϩάZabbixͷϩάࢹͬͯΔ » AWSαʔϏεͷϩάCloudWatch-Logs » ҰݩԽͰ͖ͯͳ͍... » Έத
"URLࢹΛ͍ͨ͠" » ZabbixͷWebࢹ » CloudWatch͋͘·ͰAWSαʔϏεͷϦιʔεΛݟ Δͷ » ͰCloudWatch-Events+AWS LambdaͰ࡞ΕΔ
"ࠓ͜ͷΞΧϯτ͍͘ΒͬͯΔΜͩΖʁ" » ϏϦϯάΞϥʔτ » ༗໊ͩͬͯ͠Δਓ͕΄ͱΜͲͩͱࢥ͏͚Ͳɺ͔ͩΒ ͦ͜ඞͣઃఆͯ͠΄͍͠ » AWSͷར༻ྉCloudWatchͷඪ४ϝτϦΫεͱͯ͠ ఏڙ͞Ε͍ͯΔͨΊɺΞϥʔϜઃఆͯ͠ΞΫγϣϯΛ ىͤ͜Δ
» Zabbixʹ·ͱΊͯτϦΨʔઃఆ͢ΔΑ͠ɻ͓͖ ͳΞΫγϣϯΛɻ
"·ͱΊ" » CloudWatch͔ΒAWSϦιʔεݟΕΔɻΞϥʔϜ+Ξ ΫγϣϯͰࢹͰ͖Δ » CloudWatch-Logsʹ͍ΖΜͳAWSαʔϏεͷϩά ͕ू͞ΕͯΔɻOSͷϩάࢹؚΊͯͲ͜ͰͲ͏ ࢹ͢Δ͔Α͘ߟ͑Δඞཁ͕͋Δ » CloudWatch-EventsΠϕϯτυϦϒϯΞʔΩςΫ
νϟத৺(ʹ͖ͬͱͳΔ) » ແཧʹAWSͰ݁ͤ͞Δඞཁͳ͍ɻͦΕͧΕʹ͋ ͬͨϕετͳબΛʂ
͓·͚
"ͳΜͪΌͬͯAmazon RDS for Aurora" » Amazon RDS for AuroraͰετϨʔδ͕ࣗಈ֦ ு͢Δ
» Amazon RDS for MySQLͰετϨʔδαΠζΛࣗ Ͱઃఆ͢Δ » ετϨʔδͷۭ͖༰ྔ͕গͳ͘ͳͬͨͱ͖ʹΞΫγϣ ϯى͜͢ΞϥʔϜઃఆͰ͖Δ
ϐίʔϯ!
ͦ͜ͰετϨʔδ֦ு ͨ͠Β͍͍Μ͡ΌͶʁ
"ͳΜͪΌͬͯAmazon RDS for Aurora"
"ͳΜͪΌͬͯAmazon RDS for Aurora" » ΠϕϯτυϦϒϯʂ » ฐࣾZabbixͰ͓ࢼ͠த » ࣗಈͰετϨʔδ֦ு͞Ε
ͨΒSlackʹ௨͞ΕΔ (ਤʹࡌͤΕͨ) » ֦ுதύϑΥʔϚϯε ԼͷڪΕ͋Δ͚ͲɺͦΕ͕ উखʹ࣮ߦ͞ΕΔ͜ͱΛڐ ༰Ͱ͖ΔͳΒ͋Γ
͋Γ͕ͱ͏͍͟͝·ͨ͠