prometheus
使用docker-compose部署
- /root/docker-compose.yml
- /root/prometheus.yml
- /root/targets.json
version: '3'
services:
prometheus:
image: prom/prometheus
restart: always
volumes:
- '/root/prometheus/rules:/etc/prometheus/rules'
- '/root/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml'
- '/root/prometheus/targets.json:/etc/prometheus/targets.json'
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--web.enable-lifecycle'
ports:
- '9090:9090'
blackbox:
image: prom/blackbox-exporter
restart: always
ports:
- '9115:9115'
alertmanager:
image: prom/alertmanager
restart: always
ports:
- '9093:9093'
volumes:
- /root/prometheus/alertmanager.yml:/etc/alertmanager/alertmanager.yml
grafana:
image: grafana/grafana
ports:
- "3000:3000"
restart: always
grafana
- 可用docker-compose.yml运行
- 默认账号密码 admin/admin
- 插件市场 https://grafana.com/grafana/dashboards/
linux监控
黑盒监控
nohup ./blackbox_exporter --config.file="./blackbox.yml" --web.listen-address=":9098" --log.level=debug > /dev/null 2>&1 &
- Grafana 面板ID 9965
midway
14403