Skip to main content
RunBook Academy

CephCII · Management SecurityManagement Security

Securing the monitoring stack

Intermediate⏱ ~17 mincephcurl

What you'll learn

  • Identify what each monitoring component exposes
  • Restrict the metrics endpoints
  • Secure Grafana and Alertmanager
  • Balance access against operational usefulness

Prerequisites

None — start here.

Verified against Ceph Tentacle 20.2.x · Ceph Squid 19.2.x (supported previous) · cephadm matches the verified Ceph release · podman 4.x · csi-rbd and csi-cephfs current · RBD / CephFS / RGW current (matches Ceph release) · Linux kernel 5.15+ (5.10 minimum) · Ubuntu 24.04 LTS (Ceph host baseline) · Debian 12 (Bookworm) (Ceph host baseline) · Rocky Linux / RHEL / AlmaLinux 9.x (Ceph host baseline) · Proxmox VE 9.x (cross-course integration) · Kubernetes 1.31+ (cross-course integration) · 2026-08-18

Not yet marked complete on this device.

Why this matters in production

Metrics endpoints are unauthenticated by default and disclose the shape and state of the cluster in detail.

What each component exposes

ComponentPortExposes
mgr prometheus module9283every cluster metric, pool names, OSD layout
node-exporter9100host metrics, filesystem paths, network config
Prometheus9095the full metric database, query API
Alertmanager9093firing alerts, silences, and the ability to create them
Grafana3000dashboards, and the datasource it queries
ceph mgr services
curl -s "http://$(hostname -s):9283/metrics" | head -20
Metric names disclose pool names, host names, OSD counts, and capacity.
That is not a credential, but it is reconnaissance.

Restricting the metrics endpoints

# what the module is bound to
ceph config get mgr mgr/prometheus/server_addr
ceph config set mgr mgr/prometheus/server_addr 10.10.5.11
ceph config get mgr mgr/prometheus/server_port
The same reasoning as the dashboard: binding to a management interface
removes the endpoint from networks that should not see it.
# node-exporter, deployed by cephadm
ceph orch ls node-exporter --export
service_type: node-exporter
placement:
  host_pattern: '*'
networks:
  - 10.10.5.0/24
ceph orch apply -i node-exporter.yaml

Alertmanager and Grafana

Alertmanager without authentication permits anyone reachable to create
silences — which suppresses alerts cluster-wide.
RiskControl
Anonymous silence creationreverse proxy with authentication
Alert content disclosurenetwork restriction
Grafana anonymous accessdisable it; require login
Grafana datasource credentialsstored in Grafana; protect the instance
Grafana admin accountchange the default password at deployment
ceph orch ls grafana --export
ceph dashboard get-grafana-api-url
# confirm anonymous access is not enabled
ceph orch ps --daemon-type grafana --format json | python3 -c '
import sys,json
for d in json.load(sys.stdin): print(d["daemon_name"], d.get("hostname"), d.get("ports"))'
Silence creation is the one that matters operationally: an attacker who
can silence alerts can act without the alerting path noticing.

Balancing access

Monitoring exists to be looked at. Restricting it so far that nobody
consults it during an incident defeats it.
AudienceAccess
On-call operatorsfull, from the management network or VPN
Application teamsGrafana dashboards scoped to their concerns
Anyone elsenone
Automated scrapersthe metrics endpoint, source-restricted
# CEPH_HOST is the manager host serving the metrics endpoint; substitute your own:
CEPH_HOST=192.0.2.11

# verify from an unintended position that it is not reachable
curl -s -m 3 "http://$CEPH_HOST:9283/metrics" >/dev/null \
  && echo "REACHABLE — restrict this" || echo "not reachable"

Quiz

Knowledge check · 4 questions

  1. Q1. Which monitoring component's exposure has the most direct operational consequence?

  2. Q2. An exposed metrics endpoint hands an attacker a detailed map of the cluster while granting them no action against it.

  3. Q3. Restrict monitoring exposure without breaking operations.

    The monitoring stack is reachable from the client network. On-call operators use Grafana constantly and application teams consult a shared dashboard.

  4. Q4. How does a cephadm service spec restrict which network a monitoring daemon binds to?

Passing score: 75%. Answers are checked in this browser.

Production discipline

Put authentication in front of Alertmanager or restrict it to the management network — silence creation needs no authentication by default, and silencing alerts is the exposure with real operational consequence. Restrict metric endpoints via the service spec’s networks: field.

Cross-course references

  • Kubernetes: unauthenticated metrics endpoints are the same reconnaissance exposure
  • Linux: the ability to suppress alerting outranks the ability to read metrics