Thanos Query Grpc Client Error Rate
warning

Description Thanos Query {{$labels.job}} is failing to send {{$value | humanize}}% of requests.
Query for 5m
>>>
	
				
					(sum by (job) (
				
			
				
					
					
						rate
					
				
			
				
					(
				
			
				
					
				
			
				
					{grpc_code!="OK", job=~".*thanos-query.*"}[5m])) / sum by (job) (
				
			
				
					
					
						rate
					
				
			
				
					(
				
			
				
					
				
			
				
					{job=~".*thanos-query.*"}[5m]))) * 100 > 5
				
			
    
Query Explanation

The rule computes, for each Thanos‑Query job, the ratio of failed gRPC client calls (grpc_code != "OK") to total calls over the past 5 minutes, multiplies it by 100, and fires when that error‑rate exceeds 5 %. In other words, if more than 5 % of the query’s gRPC requests have failed in the last 5 minutes, the alert triggers.

Get Alert
Download
Copy to Clipboard