strutture:lnf:dr:calcolo:sistemi:ceph:alertmanager
Differences
This shows you the differences between two versions of the page.
| strutture:lnf:dr:calcolo:sistemi:ceph:alertmanager [2023/11/22 14:44] – created rorru@infn.it | strutture:lnf:dr:calcolo:sistemi:ceph:alertmanager [2023/11/22 14:44] (current) – rorru@infn.it | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ===== Alertmanager ===== | ||
| + | Ad ogni installazione di CEPH eseguita con '' | ||
| + | ==== Configurazione custom ==== | ||
| + | |||
| + | Per modificare la configurazione di default di Alertmanager è necessario ridefinire il template con il quale la configurazione e per Alertmanager viene generata e utilizzata nei container che ospitano Alertmanager. | ||
| + | |||
| + | Immaginando quindi di voler abilitare l' | ||
| + | |||
| + | 1. Ottenere il template attuale: | ||
| + | < | ||
| + | # ceph config-key get mgr/ | ||
| + | |||
| + | # {{ cephadm_managed }} | ||
| + | # See https:// | ||
| + | |||
| + | global: | ||
| + | resolve_timeout: | ||
| + | {% if not secure %} | ||
| + | http_config: | ||
| + | tls_config: | ||
| + | insecure_skip_verify: | ||
| + | {% endif %} | ||
| + | |||
| + | route: | ||
| + | receiver: ' | ||
| + | routes: | ||
| + | - group_by: [' | ||
| + | group_wait: 10s | ||
| + | group_interval: | ||
| + | repeat_interval: | ||
| + | receiver: ' | ||
| + | {% if snmp_gateway_urls %} | ||
| + | continue: true | ||
| + | - receiver: ' | ||
| + | repeat_interval: | ||
| + | group_interval: | ||
| + | group_by: [' | ||
| + | match_re: | ||
| + | oid: " | ||
| + | {% endif %} | ||
| + | |||
| + | receivers: | ||
| + | - name: ' | ||
| + | webhook_configs: | ||
| + | {% for url in default_webhook_urls %} | ||
| + | - url: '{{ url }}' | ||
| + | {% endfor %} | ||
| + | - name: ' | ||
| + | webhook_configs: | ||
| + | {% for url in dashboard_urls %} | ||
| + | - url: '{{ url }}/ | ||
| + | {% endfor %} | ||
| + | {% if snmp_gateway_urls %} | ||
| + | - name: ' | ||
| + | webhook_configs: | ||
| + | {% for url in snmp_gateway_urls %} | ||
| + | - url: '{{ url }}' | ||
| + | {% endfor %} | ||
| + | {% endif %} | ||
| + | </ | ||
| + | |||
| + | E inserire quanto ottenuto in un file dal nome '' | ||
| + | |||
| + | 2. Aggiungere al contenuto le definizioni globali (valori esempio): | ||
| + | < | ||
| + | smtp_smarthost: | ||
| + | smtp_from: ' | ||
| + | smtp_require_tls: | ||
| + | smtp_auth_username: | ||
| + | smtp_auth_password: | ||
| + | </ | ||
| + | |||
| + | 3. Aggiungere al contenuto i destinatari nella lista '' | ||
| + | < | ||
| + | email_configs: | ||
| + | - to: ' | ||
| + | </ | ||
| + | |||
| + | Il contenuto del file dovrebbe essere a questo punto simile a: | ||
| + | < | ||
| + | # {{ cephadm_managed }} | ||
| + | # See https:// | ||
| + | |||
| + | global: | ||
| + | resolve_timeout: | ||
| + | {% if not secure %} | ||
| + | http_config: | ||
| + | tls_config: | ||
| + | insecure_skip_verify: | ||
| + | {% endif %} | ||
| + | smtp_smarthost: | ||
| + | smtp_from: ' | ||
| + | smtp_require_tls: | ||
| + | smtp_auth_username: | ||
| + | smtp_auth_password: | ||
| + | |||
| + | |||
| + | route: | ||
| + | receiver: ' | ||
| + | routes: | ||
| + | - group_by: [' | ||
| + | group_wait: 10s | ||
| + | group_interval: | ||
| + | repeat_interval: | ||
| + | receiver: ' | ||
| + | {% if snmp_gateway_urls %} | ||
| + | continue: true | ||
| + | - receiver: ' | ||
| + | repeat_interval: | ||
| + | group_interval: | ||
| + | group_by: [' | ||
| + | match_re: | ||
| + | oid: " | ||
| + | {% endif %} | ||
| + | |||
| + | receivers: | ||
| + | - name: ' | ||
| + | webhook_configs: | ||
| + | {% for url in default_webhook_urls %} | ||
| + | - url: '{{ url }}' | ||
| + | {% endfor %} | ||
| + | - name: ' | ||
| + | webhook_configs: | ||
| + | {% for url in dashboard_urls %} | ||
| + | - url: '{{ url }}/ | ||
| + | {% endfor %} | ||
| + | email_configs: | ||
| + | - to: ' | ||
| + | {% if snmp_gateway_urls %} | ||
| + | - name: ' | ||
| + | webhook_configs: | ||
| + | {% for url in snmp_gateway_urls %} | ||
| + | - url: '{{ url }}' | ||
| + | {% endfor %} | ||
| + | {% endif %} | ||
| + | </ | ||
| + | |||
| + | 4. Sostituire il template nella configurazione per cephadm: | ||
| + | ceph config-key set mgr/ | ||
| + | | ||
| + | 5. Avviare a riconfigurazione dei servizio esistente: | ||
| + | ceph orch reconfig alertmanager | ||
| + | |||
| + | 6. Verificare con '' | ||
