基于症状的监视和基于原因的监视是什么意思?

问题描述

在SRE上下文中,症状和基于原因的监视是什么意思?为什么如此重要?哪些工具用于此类监视?

解决方法

症状与原因


您的监控系统应解决两个问题:发生了什么问题, 为什么?

“损坏之处”表示症状; “为什么”表示 (可能是中间的)原因。下表列出了一些假设 症状和相应原因。

“什么”与“为什么”是以下方面最重要的区别之一 以最大的信号和最小的噪声编写良好的监视。

示例

+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+
|                        Symptom                         |                                                      Cause                                                      |
+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+
| I’m serving HTTP 500s or 404s                          | Database servers are refusing connections                                                                       |
|--------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------|
| My responses are slow                                  | CPUs are overloaded by a bogosort,or an Ethernet cable is crimped under a rack,visible as partial packet loss |
|--------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------|
| Users in Antarctica aren’t receiving animated cat GIFs | Your Content Distribution Network hates scientists and felines,and thus blacklisted some client IPs            |
|--------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------|
| Private content is world-readable                      | A new software push caused ACLs to be forgotten and allowed all requests                                        |
+--------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+

Source

用于监视的工具取决于您的平台,监视的内容和方式。例如,Azure Monitor适用于Azure中托管的应用程序和基础结构,Amazon CloudWatch适用于AWS中的应用程序和基础结构,因此该列表一直存在。