Skip to main content
APA
Sponsored by CAST AI — Kubernetes cost optimization Better Stack — Uptime monitoring and log management
⚠️

Alert thresholds depend on the nature of your applications. Some queries may have arbitrary tolerance thresholds. Building an efficient monitoring platform takes time. 😉

Solr Prometheus Alert Rules

4 Prometheus alerting rules for Solr. Exported via embedded exporter. These rules cover critical and warning conditions — copy and paste the YAML into your Prometheus configuration.

2.16. embedded exporter (4 rules)

wget https://raw.githubusercontent.com/samber/awesome-prometheus-alerts/refs/heads/master/dist/rules/solr/embedded-exporter.yml
critical

2.16.1. Solr update errors

Solr collection {{ $labels.collection }} has failed updates for replica {{ $labels.replica }} on {{ $labels.base_url }}.

- alert: SolrUpdateErrors
  expr: increase(solr_metrics_core_update_handler_errors_total[1m]) > 1
  for: 0m
  labels:
    severity: critical
  annotations:
    summary: Solr update errors (instance {{ $labels.instance }})
    description: "Solr collection {{ $labels.collection }} has failed updates for replica {{ $labels.replica }} on {{ $labels.base_url }}.\n  VALUE = {{ $value }}\n  LABELS = {{ $labels }}"
warning

2.16.2. Solr query errors

Solr has increased query errors in collection {{ $labels.collection }} for replica {{ $labels.replica }} on {{ $labels.base_url }}.

- alert: SolrQueryErrors
  expr: increase(solr_metrics_core_errors_total{category="QUERY"}[1m]) > 1
  for: 5m
  labels:
    severity: warning
  annotations:
    summary: Solr query errors (instance {{ $labels.instance }})
    description: "Solr has increased query errors in collection {{ $labels.collection }} for replica {{ $labels.replica }} on {{ $labels.base_url }}.\n  VALUE = {{ $value }}\n  LABELS = {{ $labels }}"
critical

2.16.3. Solr replication errors

Solr collection {{ $labels.collection }} has replication errors for replica {{ $labels.replica }} on {{ $labels.base_url }}.

- alert: SolrReplicationErrors
  expr: increase(solr_metrics_core_errors_total{category="REPLICATION"}[1m]) > 1
  for: 0m
  labels:
    severity: critical
  annotations:
    summary: Solr replication errors (instance {{ $labels.instance }})
    description: "Solr collection {{ $labels.collection }} has replication errors for replica {{ $labels.replica }} on {{ $labels.base_url }}.\n  VALUE = {{ $value }}\n  LABELS = {{ $labels }}"
critical

2.16.4. Solr low live node count

Solr collection {{ $labels.collection }} has less than two live nodes for replica {{ $labels.replica }} on {{ $labels.base_url }}.

- alert: SolrLowLiveNodeCount
  expr: solr_collections_live_nodes < 2
  for: 0m
  labels:
    severity: critical
  annotations:
    summary: Solr low live node count (instance {{ $labels.instance }})
    description: "Solr collection {{ $labels.collection }} has less than two live nodes for replica {{ $labels.replica }} on {{ $labels.base_url }}.\n  VALUE = {{ $value }}\n  LABELS = {{ $labels }}"