AKA SNMP Network(网络设备监控)

Dashboard

For snmp exporter with interface
Last updated: 6 months ago

Start with Grafana Cloud and the new FREE tier. Includes 10K series Prometheus or Graphite Metrics and 50gb Loki Logs

Downloads: 58

Reviews: 0

  • 1.png
    1.png

docker compose

version: '2'
services:
  prometheus:
    image: prom/prometheus:v2.29.2
    container_name: prometheus
    hostname: prometheus
    restart: always
    user: root
    volumes:
      - /etc/localtime:/etc/localtime
      - /data/prometheus/prom_data:/prometheus
      - /data/prometheus/prom_config/prometheus.yml:/etc/prometheus/prometheus.yml
    ports:
      - "9090:9090"
    depends_on:
      - snmp-exporter
  snmp-exporter:
    image: prom/snmp-exporter:v0.20.0
    container_name: snmp-exporter
    restart: always
    environment:
      TZ: Asia/Shanghai
    volumes:
      - /etc/localtime:/etc/localtime
      #- /data/prometheus/snmp_conf:/etc/snmp_exporter
    ports:
    - 9116:9116
networks:
  default:
    external:
      name: aka-network

prometheus.yml

mkdir -p /data/prometheus/prom_config/
vim prometheus.yml

global:
  scrape_interval:     15s # By default, scrape targets every 15 seconds.
  evaluation_interval: 15s # By default, scrape targets every 15 seconds.
  external_labels:
      monitor: 'elsa'
scrape_configs:
  - job_name: 'prometheus'
    scrape_interval: 5s
    static_configs:
      - targets: ['192.168.157.206:9090']
  - job_name: '4F_H3C'
    static_configs:
      - targets:
        - x.x.x.x:55161 # 填写路由地址
    metrics_path: /snmp
    params:
      module: [if_mib]
    relabel_configs:
      - source_labels: [__address__]
        target_label: __param_target
      - source_labels: [__param_target]
        target_label: instance
      - target_label: __address__
        replacement: 'snmp-exporter:9116'  # SNMP exporter.

snmp v2认证

# 修改 snmp.yml 文件 增加以下内容
h3c:
  version: 2
  auth:
    community: xxxxx
Get this dashboard:
15473
Dependencies: