Percentage of 5xx responses per service?
BeginnerProductionRapid-Fire PromQL & LogQL
Answer
100 * sum by (service) (rate(http_requests_total{status=~"5.."}[5m]))
/ sum by (service) (rate(http_requests_total[5m]))
Both sides aggregate by the same labels, so the division matches one-to-one.
More on Rapid-Fire PromQL & LogQL
Requests per second per service over the last 5 minutes?Beginnerp99 latency per route from a histogram?IntermediateTop 5 pods by CPU usage in a namespace?BeginnerMemory working set as a percentage of the container limit?IntermediateWhich scrape targets are down right now?BeginnerWhich filesystems will fill up within 4 hours?Intermediate