首页 > 代码库 > ATS metric query
ATS metric query
ATS metric query
参考:ATS metric query
1 proxy.node.cache_hit_mem_ratio 2 proxy.node.cache_hit_mem_ratio_avg_10s #查询当前内存命中率 3 4 proxy.node.cache_hit_ratio 5 proxy.node.cache_hit_ratio_avg_10s #查询当前缓存(cache.db)命中率 6 7 proxy.node.bandwidth_hit_ratio 8 proxy.node.bandwidth_hit_ratio_avg_10s #查询当前带宽命中率 9 10 11 12 proxy.node.current_cache_connections #前端用户到cache.db链接数13 14 proxy.node.cache.percent_free #Cache Percent Free(cache.db空闲空间百分比)15 16 proxy.node.current_client_connections #前端用户到ATS的连接数17 18 proxy.node.current_server_connections #到后端源站的连接数19 20 proxy.node.user_agent_xacts_per_second #平均每秒处理的客户端并发数21 22 proxy.node.client_throughput_out #当前ATS输出到前端的带宽流量(单位Mbps)23 24 proxy.node.current_cache_connections 等价于 proxy.node.http.cache_current_connections_count2526 proxy.node.current_client_connections 等价于 proxy.node.http.user_agent_current_connections_count27 28 proxy.node.current_server_connections 等价于 proxy.node.http.origin_server_current_connections_count
关于带宽命中率参考: Bandwidth and Transfer
proxy.node.bandwidth_hit_ratio
The difference of proxy.node.user_agent_total_bytes and proxy.node.origin_server_total_bytes, divided by proxy.node.user_agent_total_bytes.
Represents the ratio of bytes served to user agents which were satisfied by cache hits, since statistics collection began.
proxy.node.bandwidth_hit_ratio_avg_10s
The difference of proxy.node.user_agent_total_bytes_avg_10s and proxy.node.origin_server_total_bytes_avg_10s, divided by proxy.node.user_agent_total_bytes_avg_10s.
Represents the ratio of bytes served to user agents which were satisfied by cache hits, over the previous 10 seconds.
带宽命中率可由下面计算得来:
1 [root@~]# /opt/soft/ats/bin/traffic_ctl metric match total_bytes_avg_10s 2 proxy.node.user_agent_total_bytes_avg_10s 2161301760.000000 3 proxy.node.origin_server_total_bytes_avg_10s 176160640.000000 4 proxy.cluster.user_agent_total_bytes_avg_10s 1325454080.000000 5 proxy.cluster.origin_server_total_bytes_avg_10s 1294467072.000000 6 [root@~]# 7 [root@~]# /opt/soft/ats/bin/traffic_ctl metric get proxy.node.bandwidth_hit_ratio_avg_10s 8 proxy.node.bandwidth_hit_ratio_avg_10s 0.918493 9 [root@~]# 10 [root@~]# awk ‘BEGIN{print (2161301760-176160640)/2161301760}‘11 0.91849312 [root@~]#
关于ATS向前端输出的带宽值
proxy.node.http.throughput
10秒内的响应客户端的输出带宽值,单位是
bytes
1 proxy.node.http.throughput2 Collection: global3 Type: gauge4 Units: bytes5 Datatype: integer6 The throughput of responses to user agents over the previous 10 seconds, in bytes.
proxy.node.client_throughput_out
10秒内的响应客户端的输出带宽值,单位是
megabits
1 proxy.node.client_throughput_out2 Collection: global3 Type: gauge4 Units: mbits5 Datatype: float6 The value of proxy.node.http.throughput represented in megabits.
Code:
1 integer ‘proxy.node.http.throughput‘ [[2 local self = ...3 4 return rate_of_10s(self,5 function() return proxy.node.http.user_agent_total_response_bytes end6 )7 ]]
ATS metric query
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。