Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Amazon Elasticsearch Serviceを利用したAWSのログ活用 /amaz...

Amazon Elasticsearch Serviceを利用したAWSのログ活用 /amazones-aws-integration

Developers.IO 2016 in FUKUOKA

Shinji Fujimoto

October 08, 2016
Tweet

More Decks by Shinji Fujimoto

Other Decks in Technology

Transcript

  1. Elastic Cloud Elastic͕ࣾఏڙ͢ΔElasticsearch as a service • ϝϦοτ • ӡ༻ɺอक

    • ঎༻ϓϥάΠϯ • σϝϦοτ • ίετ͕ଞʹൺ΂ͯߴ͍
  2. • ߏஙͷ؆ུԽ • ϚϧνAZ഑ஔ • Master / Data෼཭ • αΠζࢦఆ

    • ӡ༻ͷ؆ུԽ • ਫฏ/ਨ௚εέʔϧ • ো֐ͷࣗಈݕ஌ • ࣗಈϊʔυަ׵ • ೔࣍εφοϓγϣοτ • CloudWatchʹΑΔϦιʔεϞχλϦϯά AWSͷϚωʔδυαʔϏε Availability Zone 1 Availability Zone 2 Master Master Data Data Index1 Rep1 Index2 Rep2 Snapshot Monitoring
  3. AWSαʔϏεͱͷ࿈ܞ AWS IoT CloudWatch Logs Kinesis Firehose AWS Lambda ηϯαʔσʔλͷ

    ՄࢹԽ ϩάσʔλͷՄࢹԽ ϩάͷશจݕࡧ ετϦʔϜσʔλͷ όοϑΝϦϯά ΤϥʔϋϯυϦϯά ࣗ༝ͳར༻ αϯϓϧίʔυͷఏڙ S3 → Amazon ES DynamoDB → Amazon ES
  4. Ͱ͖ͳ͍͜ͱ • ࣗ༝ͳElasticsearchͷόʔδϣϯબ୒ • VPCରԠ • ϓϥάΠϯͷΠϯετʔϧ • Dynamic Script

    • Ϣʔβʔࣙॻ • ϝϞϦεϫοϓ • Ұ෦ͷElasticsearch API • TCP Transport • Elasticࣾͷαϙʔτ • TileMap
  5. Կ͕஌Γ͔͔ͨͬͨʁ • ϘτϧωοΫՕॴͷಛఆ • LB ? • Web/AP ? •

    DB ? • ϘτϧωοΫॲཧͷಛఆ • ͲͷURLύε ? • ͲͷSQLΫΤϦ ?
  6. ͋Δ೔ͷӡ༻ݱ৔ΛAWSʹஔ͖׵͑ &-# &$ IUUQE 3%4GPS.Z42- ग़ྗઌ 4 'JMF 5BCMFPS'JMF ΞΫηεํ๏

    "84"1* ϑΝΠϧΞΫηε 42-ΫΤϦ PS "84"1* ܗࣜ εϖʔε۠੾Γ ΧελϚΠζՄ ϚϧνϥΠϯ λΠϛϯά ෼ຖPS෼ຖ ϦΞϧλΠϜ ϦΞϧλΠϜ
  7. ͋Δ೔ͷӡ༻ݱ৔ΛAWSʹஔ͖׵͑ &$ &4 &$ &4 $MPVE8BUDI • ϝοηʔδύʔγϯά • χΞϦΞϧλΠϜ

    • ΤϥʔϋϯυϦϯά • όοϑΝϦϯά • ௥Ճίετͳ͠ -PHTUBTIɺ'MVFOUEͷར༻ $MPVE8BUDI-PHTͷར༻ • ϝοηʔδύʔγϯά • χΞϦΞϧλΠϜ • EC2΁ͷ௿ෛՙ • ϩά؂ࢹ
  8. ͋Δ೔ͷӡ༻ݱ৔ΛAWSʹஔ͖׵͑ &$ &4 &4 • ϝοηʔδύʔγϯά • χΞϦΞϧλΠϜ • ΤϥʔϋϯυϦϯά

    • όοϑΝϦϯά -PHTUBTIɺ'MVFOUEͷར༻ "84-BNCEBͷར༻ • ϝοηʔδύʔγϯά • χΞϦΞϧλΠϜ • EC2΁ͷ௿ෛՙ • ௿ίετ &-# 4 &-# 4 -BNCEB
  9. ͋Δ೔ͷӡ༻ݱ৔ΛAWSʹஔ͖׵͑ &$ &4 &4 • ϝοηʔδύʔγϯά • χΞϦΞϧλΠϜ • ΤϥʔϋϯυϦϯά

    • όοϑΝϦϯά -PHTUBTIɺ'MVFOUEͷར༻ "84-BNCEBͷར༻ • ϝοηʔδύʔγϯά • EC2΁ͷ௿ෛՙ • ௿ίετ 3%4 -BNCEB 3%4 $MPVE8BUDI &WFOU
  10. CloudFrontͷϩάՄࢹԽ • ਓؾϖʔδ෼ੳ • Ωϟογϡώοτ෼ੳ • ΞΫηε஍Ҭ෼ੳ • ར༻ऀͷ୺຤/OS෼ੳ •

    ෆਖ਼ΞΫηε෼ੳ ʢࢀߟURLʣ
 http://dev.classmethod.jp/server-side/elasticsearch/cloudfront-log-to-kibana/