エンドポイントとプールが不健康になる理由
動的ロードバランシングについて話すとき、それはあなたのロードバランサーがトラフィックを処理できるエンドポイントにのみリクエストを送ることを意味します。
しかし、あなたのロードバランサーはどのエンドポイントがトラフィックを処理できるかをどのように知るのでしょうか?それは、モニター、ヘルスモニター、プールのシステムを通じて判断します。
動的ロードバランシングは、プール、モニター、およびヘルスチェックの組み合わせを通じて行われます。
flowchart RL
accTitle: Load balancing monitor flow
accDescr: Monitors issue health monitor requests, which validate the current status of servers within each pool.
Monitor -- Health Monitor ----> Endpoint2
Endpoint2 -- Response ----> Monitor
subgraph Pool
Endpoint1((Endpoint 1))
Endpoint2((Endpoint 2))
end
ヘルスチェックは requests issued by a monitor at regular interval and — depending on the monitor settings — return a pass or fail value to make sure an endpoint is still able to receive traffic.
Each health monitor request is trying to answer two questions:
- Is the endpoint offline?: Does the endpoint respond to the health monitor request at all? If so, does it respond quickly enough (as specified in the monitor's Timeout field)?
- Is the endpoint working as expected?: Does the endpoint respond with the expected HTTP response codes? Does it include specific information in the response body?
If the answer to either of these questions is "No", then the endpoint fails the health monitor request.
For each option selected in a pool’s Health Monitor Regions, Cloudflare sends health monitor requests from three separate data centers in that region.

If the majority of data centers for that region pass the health monitor requests, that region is considered healthy. If the majority of regions is healthy, then the endpoint itself will be considered healthy.
ロードバランシングの分析とログは、グローバルな健康状態の変化のみを表示します。
エンドポイントの健康状態を変更する際の精度と一貫性を高めるために、モニター作成APIエンドポイントを介してconsecutive_upおよびconsecutive_downパラメータを設定することもできます。健康から不健康に変更するには、エンドポイントは指定された回数(consecutive_downで指定)健康とマークされる必要があります。同様に、不健康から健康に変更する場合もconsecutive_upが適用されます。
個々のエンドポイントが不健康になると、それは関連するプールの健康状態に影響を与える可能性があります(ダッシュボードに表示されます):
- 健康: すべてのエンドポイントが健康です。
- 劣化: 少なくとも1つのエンドポイントが不健康ですが、プールはまだ健康と見なされ、トラフィックを受け取る可能性があります。
- クリティカル: プールはヘルススレッショルドで指定された利用可能なエンドポイントの数を下回っており、ロードバランサーからトラフィックを受け取ることはありません(他のプールも不健康であり、このプールがフォールバックプールとしてマークされていない限り)。
- 健康不明: プールのエンドポイントにモニターが接続されていないか、モニターがまだエンドポイントの健康を判断していない状態です。
- 健康なし: あなたのロードバランサーのフォールバックプールのために予約されています。
When a pool reaches Critical health, your load balancer will begin diverting traffic according to its Traffic steering policy:
-
Off:
- If the active pool becomes unhealthy, traffic goes to the next pool in order.
- If an inactive pool becomes unhealthy, traffic continues to go to the active pool (but would skip over the unhealthy pool in the failover order).
-
All other methods: Traffic is distributed across all remaining pools according to the traffic steering policy.
This pool is meant to be the pool of last resort, meaning that its health is not taken into account when directing traffic.
Fallback pools are important because traffic still might be coming to your load balancer even when all the pools are unreachable (disabled or unhealthy). Your load balancer needs somewhere to route this traffic, so it will send it to the fallback pool.
1つ以上のプールが不健康になると、あなたのロードバランサーもダッシュボードで異なる状態を示す可能性があります:
- 健康: すべてのプールが健康です。
- 劣化: 少なくとも1つのプールが不健康ですが、トラフィックはまだフォールバックプールに向かっていません。
- クリティカル: すべてのプールが不健康で、トラフィックはフォールバックプールに向かっています。
ロードバランサーがクリティカルな健康状態に達し、フォールバックプールとして機能するプールも無効になっている場合:
- Cloudflareがあなたのホスト名をプロキシしている場合、530 HTTP/1016オリジンDNS障害が表示されます。
- Cloudflareがあなたのホスト名をプロキシしていない場合、SOAレコードが表示されます。