5.7.2 SNMP Configuration In Alertmanager IDIH
SNMP Configuration
In the following command, provide valid ip and port in docker compose file
snmp_notifier:
image: occnidih-docker.dockerhub-iad.oci.oraclecorp.com/snmp-notifier:v2.1.0
privileged: true
volumes:
- ./snmp/:/templates/
environment:
# Required for SNMP v3
- SNMP_NOTIFIER_AUTH_USERNAME=snmp_user
- SNMP_NOTIFIER_AUTH_PASSWORD=P@ssw0rd
- SNMP_NOTIFIER_PRIV_PASSWORD=changeme
command:
- "--trap.description-template=/templates/description-template.tpl"
- "--snmp.destination=[service_xmi]:162"
- "--snmp.retries=2"
- "--snmp.timeout=5s"
- "--snmp.version=V3"
- "--snmp.authentication-enabled"
- "--snmp.authentication-protocol=SHA"
- "--snmp.private-enabled"
- "--snmp.private-protocol=AES"
ports:
- "0.0.0.0:9464:9464"
- "[::]:9464:9464"
logging:
options:
max-size: "10m" # Limits each log file to 10 MB
max-file: "3" # Retains up to 3 rotated log files
networks:
- cnidih-networkUpdate the alertmanager.yaml to ensure snmp is configured appropriately
for sending data to respective NMS.
global:
resolve_timeout: 10s
receivers:
- name: combined-receiver
webhook_configs:
# SNMP Notifier (non-TLS)
- url: 'http://snmp_notifier:9464/alerts'
# Alarm Management (TLS)
- url: 'https://alarmmanagement:8092/api/cnidih/alarmmanagement/v1/alarms'
http_config:
tls_config:
insecure_skip_verify: true
route:
group_by:
- namespace
group_interval: 2m
group_wait: 30s
receiver: combined-receiver
repeat_interval: 5m
routes:
- matchers:
- alertname = "Watchdog"
receiver: combined-receiver
- matchers:
- app =~ "tdr.*|tdrstorage|ttr.*|ttrdecoder|protrace.*|protraceprocessor|nfconfig.*|nfconfigmanager|protocol.*|protocoldecoder|alarm.*|alarmmanagement|api.*|apigateway|cnidihportal|cnidih*|portal*|user.*|usermanagement|kafka-broker|kafka*|zookeeper*"
receiver: combined-receiver