Introducing Availability Monitoring [訳] | Datadog

Introducing Availability Monitoring [訳]

Author Jay Hotta

Published: 1月 27, 2015

Introducing Availability Monitoring [訳]

Introducing Availability Monitoring (原文)

December 15th, 2014 by Matt Williams

We’ve just released a major extension to Datadog monitors in the Datadog Agent 5.1.0 called Availability Monitoring. Availability Monitoring introduces five new kinds of monitors on top of our existing metric-based ones:

Datadog Agent 5.1.0では、”Availability Monitoring”と呼ばれる新機能が追加されました。Availability Monitoring”では、今までのメトリクスをベースとした監視アラート方法に加えて次の5種類の監視アラート方法を追加しました。(New Monitorタブの左側メニュー項目と同等)

  • Host monitors (ホスト監視)
  • Integration monitors (インテグレーション監視)
  • Network monitors (ネットワーク監視)
  • Process monitors (プロセス監視)
  • Custom monitors (カスタム監視)

Metric-based monitors let you monitor apps and services in a sophisticated way. However, sometimes you just want a simpler monitor to know when a host or a service is up or down. That is exactly what Availability Monitoring lets you do.

メトリクスベースの監視方法を使うと、アプリケーションやサービスを細かいところまで監視し続けることができます。しかし、時にはシンプルな設定の監視アラートでホストやサービスの起動や停止が分ければいいという状況もあると思います。”vailability Monitoring”は、そういう要求に答えるための監視アラート方法なのです。

Monitors---Datadog

Like metric-based monitors, the new monitors are particularly well-suited for large-scale deployments thanks to their use of tags. With tags you can apply a host monitor on all hosts that belong to the same environment, are in the same data center, or run the same AWS AMI. There’s no need to reconfigure anything if your infrastructure is elastic. Datadog monitors keep up with changes in real-time.

これらの新しい監視アラート方法もタグが使えるおかげで、今までのメトリクスベースの監視アラートと同じように、大規模なデプロイメントとも相性が非常に良いです。タグを使うことにより、同じ環境(例:同じデーターセンター, 同じマシンイメージを使って起動したインスタンス, その他)に帰属する全てのホストに、1つのホスト監視設定で対応することができます。運用しているインフラの構成要素が増減しても、再設定は不要です。Datadogの監視アラートは、その変化にリアルタイムで追従していきます。

An example: Monitor Elasticsearch

At Datadog we use Elasticsearch extensively to power our correlation engine. Let’s look at how you can monitor it effectively using the new monitors on top of the existing metric-based monitors.

Datadogでは、メトリクスの相関関係を導き出すエンジンとしてElasticsearchを広く活用しています。従いElasticsearchを例に、メトリクスベースの監視アラートと新しく加わった監視アラート方法を組み合わせて、効果的に監視する方法を見ていくことにしたいと思います。

In this example we will use two of the new monitors: host monitors and integration monitors, in addition to the existing metric monitors to get comprehensive coverage.

この例は、新しい監視アラート方法の内”host monotor”と”integration monotors”の2種類を、既存のメトリクスベースの監視と併用することにより、網羅的切り口で監視アラートを実現する内容になっています。

Monitor all Elasticsearch hosts at once

To monitor all Elasticsearch hosts at once you can use the new host monitor. In this example, all Elasticsearch hosts have a tag that lets you track the whole cluster: name:es-events-data. Datadog automatically tags AWS instances and converts Chef roles and Puppet facts into tags. In addition, you can use the infrastructure overview UI or our API to tag hosts. You’ll never have to reconfigure the monitor as long as hosts are tagged properly.

Elasticsearchのホストをまとめて監視するには、”host monotor”を使うことができます。この例ではクラスタ全体を掌握するために、Elasticsearchの全ホストに、”name:es-events-data”というタグが付与されていると仮定します。Datadogでは、自動でAWSのインスタンスにタグを付与し、ChefのロールやPuppetのファクトにもタグを付与します。更にAPIや”infrastructure overview”のUIからそのホストに関連したらタグを付与することもできます。従ってタグが適切に付与されている環境では、監視アラートを再設定することは一切ありません。

Every minute Datadog will check whether it has received a heartbeat from all hosts with that tag and trigger an alert if any host is missing. Datadog can even tell the difference between a host that stopped reporting and one that was terminated on purpose on AWS.

Datadogでは、監視アラートに設定されたタグを持った全てのホストからハートビート信号が受信できているかを毎分確認し、どれかのホストからの信号が抜け落ちていれば、アラートを出します。Datadogでは、意図的に”terminated”されたホストと、停止してリポートが必要なホストの違いを認識し、アラートに使うことができます。

Host monitor

The rest of the monitor definition is one you are already familiar with: say what’s happening and decide who to notify in your team.

“Say what’s happening”と”Notify your team”の部分は旧監視アラートを設定するUIから受け継いだ部分で、アラートで送信するメッセージとアラートの通知先を設定します。

Monitor Elasticsearch cluster health with an integration monitor

Elasticsearch is a distributed data store: it can survive the loss of a number of its hosts so the host-based monitor is useful but coarse.

Elasticsearchは、分散型のデータストーアです。そのためクラスタ内のホストの何台かが抜け落ちても、クラスタ全体としては機能し続けることができます。この意味でホストベースでの監視アラートは有用ですが、それだけでは心もとない気もします。

The Elasticsearch integration monitor understands the Elasticsearch cluster health API natively so you can easily alert on the health of the whole cluster, using tags if you have multiple clusters.

Elasticsearchのインテグレーションベースの監視アラートは、Elasticsearch clusterのヘルスAPIを使ってクラスタの状態に関する情報を直接収取できるようになています。従って、このヘルス情報を基にアラートを簡単に設定できるようになっています。

Integration monitor

Monitor Elasticsearch metrics with a metric monitor

With the previous two monitors, you can track the health of the cluster and that of each individual node. Metric-based monitors give you a more granular view into Elasticsearch.

先の2つの監視アラート方法に合わせて、各ノードとクラスターの状態を把握し続ける方法があります。メトリクスベースの監視は、Elasticsearchのより詳細なヘルス状態の把握に役立てることができます。

Relocating Elasticsearch shards may negatively affect run-time performance of the cluster so they are a good metric to keep an eye on. The metric elasticsearch.relocatingshards is monitored availability zone by availability zone and triggers if any shard relocates over a period of 5 minutes.

Elasticsearchのシャディングの再配置は、クラスタの実行パフォーマンスを低下させるため、継続して監視する価値のあるメトリクスです。”elasticsearch.relocatingshards”のメトリクスをアベラビリティーゾーン毎に監視し、5分以上継続するシャーディングの再配置が発生した場合は、アラートを出すことにします。

Monitors - Metric

Learn more about monitors

We have updated our API and documentation to describe Availability Monitoring in greater detail. We will follow up this introduction with more in-depth posts. Stay tuned.

“Availability Monitoring”の詳細を解説するために、APIとそのドキュメント を大幅に更改しました。更に、このイントロダクション記事に続き、更に突っ込んだ内容の監視アラート記事を掲載する予定でもあります。(乞うご期待。)

If you’re new to Datadog and want the ability to be alerted based on the availability of your hosts and services, sign up for a 14 day free trial and check it out for yourself.

もしもDatadogを初めて聞いた人で、今管理しているサービスやホストのヘルス状態に基づいてアラートを受けたい場合は、14日間の無料トライアルにサインアップし、ご自身で試してみてください。