1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91
| 监控指标 cadvice: 计算容器cpu的使用率: sum(irate(container_cpu_usage_seconds_total{image!=""}[1m])) without (cpu) 容器内存使用量(单位:字节) container_memory_usage_bytes{image!=""} 查询容器网络接收量速率(单位:字节/秒) sum(rate(container_network_receive_bytes_total{image!=""}[1m])) without (interface) 查询容器网络传输量速率(单位:字节/秒): sum(rate(container_network_transmit_bytes_total{image!=""}[1m])) without (interface) 查询容器文件系统读取速率(单位:字节/秒): sum(rate(container_fs_reads_bytes_total{image!=""}[1m])) without (device) 查询容器文件系统写入速率(单位:字节/秒): sum(rate(container_fs_writes_bytes_total{image!=""}[1m])) without (device)
MySQLD Exporter: 查询吞吐量(速率) sum(rate(mysql_global_status_commands_total{command=~"insert|update|delete"}[2m])) without (command) 连接情况 当前剩余的可用连接数 mysql_global_variables_max_connections - mysql_global_status_threads_connected 前MySQL实例连接拒绝数 mysql_global_status_aborted_connects 缓冲池使用情况 MySQL实例的缓冲池利用率 (sum(mysql_global_status_buffer_pool_pages) by (instance) - sum(mysql_global_status_buffer_pool_pages{state="free"}) by (instance)) / sum(mysql_global_status_buffer_pool_pages) by (instance) 2分钟内磁盘读取请求次数的增长率的变化情况 rate(mysql_global_status_innodb_buffer_pool_reads[2m]) 查询执行性能 Slow_queries的增长情况 rate(mysql_global_status_slow_queries[2m]) kube NodeCPU使用率: sum(irate(node_cpu_seconds_total{nodename="10.10.173.203",mode!="idle"}[1m]))*100 Node CPU负载: node_load1 node_load5 node_load15
Node内存使用率: (1-node_memory_MemAvailable_bytes/node_memory_MemTotal_bytes)*100
根分区剩余空间: node_filesystem_avail_bytes{device="rootfs"}
Node CPU数量: machine_cpu_cores
容器CPU使用率: (sum(irate(container_cpu_usage_seconds_total{container_name!="",pod_name!="",namespace="test-godeyes"}[1m])) by(cluster,namespace,container_name,pod_name))/(sum(container_spec_cpu_quota{namespace="test-godeyes",container_name!="",pod_name!=""}) by(cluster,namespace,container_name,pod_name) /100000)*100 容器内存使用率: container_memory_rss{namespace="test-godeyes",container_name!="",pod_name!=""}/(container_spec_memory_limit_bytes{namespace="test-godeyes", container_name!="",pod_name!=""}) <=1
容器inode使用总数: container_fs_inodes_total{namespace="test-godeyes",container_name!="",pod_name!=""}
mysql连接数: mysql_global_status_connections{vip="10.19.124.36:3306"}
mysql状态: MySQL_Up{vip="10.19.124.36:3306"}
mysql ops: delta(mysql_global_status_innodb_row_ops_total{vip="10.19.185.107:3306"}[5m]) mysql hit命中率: (mysql_global_status_qcache_hits-mysql_global_status_qcache_inserts )/mysql_global_status_qcache_hits * 100
redis状态: redis_cluster_state{addr="10.19.100.8:7000"}
redis连接数: redis_connected_clients{addr="10.19.100.8:7000"}
redis命中率: redis_keyspace_hits_total{addr="10.19.100.8:7000"}/(redis_keyspace_misses_total{addr="10.19.100.8:7000"}+redis_keyspace_hits_total{addr="10.19.100.8:7000"})
redis内存使用率: redis_memory_used_bytes{addr="10.19.100.8:7000"}/redis_memory_max_bytes{addr="10.19.100.8:7000"}
mq状态: rabbitmq_up
mq积压: rabbitmq_queue_messages_ready
mq内存: rabbitmq_node_mem_used/rabbitmq_node_mem_limit
|