Where Does Prometheus Store Config and Metrics?
Prometheus keeps config in prometheus.yml and metrics in its data directory. Reload config with SIGHUP; plan disk for retention.
Last updated
Prometheus pairs a small YAML config with a heavyweight time-series store. Scrape targets, intervals, rules, and alertmanager links live in prometheus.yml, reloaded without restarts. Every sample then lands in the data directory under retention policy.
Disk planning decides reliability here. Local retention covers recent dashboards while long-term history belongs in remote storage. Package installs and Docker images default to different data paths, so check the service flags or compose volumes before assuming. Rules files ride alongside the main config.
Where Prometheus stores this, by platform
/etc/prometheus/prometheus.yml
Config plus rules here; metrics in the data dir set by flags. Reload with SIGHUP after edits. Size retention from disk reality, not defaults.
Frequently asked questions
How do I reload config without downtime?
Send SIGHUP or hit the reload endpoint with web enable-lifecycle on. Bad YAML fails the reload while the old config keeps scraping, which beats a restart. Validate with promtool check config first in CI.
How much disk does Prometheus need?
Size the data directory from retention time and scrape load; defaults keep two weeks. Remote-write or Thanos sidecars carry history beyond local disk. Snapshot with the admin API before upgrades, and never let the disk hit full mid-compaction.
Notice an outdated path? Let us know.