MySQL Slave replication lag
critical

Description MySQL replication lag on {{ $labels.instance }}
Query for 1m
>>>
	
				
					( (
				
			
				
					
				
			
				
					 - 
				
			
				
					
				
			
				
					) and ON (instance) 
				
			
				
					
				
			
				
					 > 0 ) > 30
				
			
    
Query Explanation

The rule calculates each replica's effective lag as mysql_slave_status_seconds_behind_master minus any configured mysql_slave_status_sql_delay, but only for instances that have a non‑zero mysql_slave_status_master_server_id (i.e., are actively replicating). If this adjusted lag is greater than 30 seconds, the alert is triggered.

Get Alert
Download
Copy to Clipboard