Files
nexus/wiki/concepts/Prometheus.md
2026-04-17 08:38:12 +08:00

37 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: "Prometheus"
type: concept
tags: [monitoring, prometheus, time-series, devops]
sources: [家庭监控方案-prometheus-grafana-node-exporter-cadvisor-blackbox]
last_updated: 2026-04-16
---
## Definition
Prometheus 是开源的时序数据库和监控系统采用拉取Pull模式采集指标支持 PromQL 查询语言和告警规则引擎。
## Key Features
- **拉取模式**:主动从 exporters 拉取指标数据
- **PromQL**:强大的时序数据查询语言
- **告警规则**:支持定义告警条件和阈值
- **多数据源**:可对接多种 exportersnode_exporter、cAdvisor、blackbox_exporter
- **服务发现**支持动态服务发现Kubernetes、Consul 等)
## Architecture
- **Prometheus Server**:采集、存储时序数据
- **Exporters**指标采集器node_exporter、cAdvisor、blackbox_exporter
- **Alertmanager**:告警分发和处理
- **Pushgateway**:支持推送模式的网关(用于短期任务)
## Common Metrics Types
- Counter递增计数器
- Gauge当前值可增可减
- Histogram直方图分布
- Summary分位数统计
## Connections
- [[Prometheus]] → scrapes → [[node_exporter]]
- [[Prometheus]] → scrapes → [[cAdvisor]]
- [[Prometheus]] → scrapes → [[Blackbox_exporter]]
- [[Prometheus]] → sends_alerts → [[Alertmanager]]
- [[Prometheus]] ← visualized_by → [[Grafana]]
- [[Prometheus]] ← core_component → [[监控可观测性]]