Amazon EC2 上的 Kubernetes
以下示例演示适用于 Amazon EC2 上 Kubernetes 的 JSON 格式组件配置。
{ "alarmMetrics":[ { "alarmMetricName":"cluster_failed_node_count", "monitor":true }, { "alarmMetricName":"node_cpu_reserved_capacity", "monitor":true }, { "alarmMetricName":"node_cpu_utilization", "monitor":true }, { "alarmMetricName":"node_filesystem_utilization", "monitor":true }, { "alarmMetricName":"node_memory_reserved_capacity", "monitor":true }, { "alarmMetricName":"node_memory_utilization", "monitor":true }, { "alarmMetricName":"node_network_total_bytes", "monitor":true }, { "alarmMetricName":"pod_cpu_reserved_capacity", "monitor":true }, { "alarmMetricName":"pod_cpu_utilization", "monitor":true }, { "alarmMetricName":"pod_cpu_utilization_over_pod_limit", "monitor":true }, { "alarmMetricName":"pod_memory_reserved_capacity", "monitor":true }, { "alarmMetricName":"pod_memory_utilization", "monitor":true }, { "alarmMetricName":"pod_memory_utilization_over_pod_limit", "monitor":true }, { "alarmMetricName":"pod_network_rx_bytes", "monitor":true }, { "alarmMetricName":"pod_network_tx_bytes", "monitor":true } ], "logs":[ { "logGroupName":"/aws/containerinsights/kubernetes/application", "logType":"APPLICATION", "monitor":true, "encoding":"utf-8" } ], "subComponents":[ { "subComponentType":"AWS::EC2::Instance", "alarmMetrics":[ { "alarmMetricName":"CPUUtilization", "monitor":true }, { "alarmMetricName":"StatusCheckFailed", "monitor":true }, { "alarmMetricName":"disk_used_percent", "monitor":true }, { "alarmMetricName":"mem_used_percent", "monitor":true } ], "logs":[ { "logGroupName":"APPLICATION-KubernetesClusterOnEC2-IAD", "logPath":"", "logType":"APPLICATION", "monitor":true, "encoding":"utf-8" } ], "processes" : [ { "processName" : "my_process", "alarmMetrics" : [ { "alarmMetricName" : "procstat cpu_usage", "monitor" : true }, { "alarmMetricName" : "procstat memory_rss", "monitor" : true } ] } ] }, { "subComponentType":"AWS::EC2::Volume", "alarmMetrics":[ { "alarmMetricName":"VolumeReadBytes", "monitor":true }, { "alarmMetricName":"VolumeWriteBytes", "monitor":true }, { "alarmMetricName":"VolumeReadOps", "monitor":true }, { "alarmMetricName":"VolumeWriteOps", "monitor":true }, { "alarmMetricName":"VolumeQueueLength", "monitor":true }, { "alarmMetricName":"BurstBalance", "monitor":true } ] } ] }