add triggers to all Zabbix templates

- add WARNING trigger on ses.license.days_remaining (< 30 days)
- add CRITICAL trigger on ses.scenario.error (strlen > 0)
- populate all 5 missing triggers in zbx_ses_template_5.0_up.xml

All 4 templates now have 7 triggers each.
This commit is contained in:
Maksim Totmin 2026-06-23 18:13:43 +07:00
parent 32c59a4005
commit 11a96222f4
4 changed files with 108 additions and 0 deletions

View File

@ -112,6 +112,15 @@
<value_type>FLOAT</value_type> <value_type>FLOAT</value_type>
<units>d</units> <units>d</units>
<description>Количество дней до окончания лицензии SES. -1 = бессрочная.</description> <description>Количество дней до окончания лицензии SES. -1 = бессрочная.</description>
<triggers>
<trigger>
<uuid>82479a2d-72d3-4935-905e-5aa5ac2c24e3</uuid>
<expression>last(/SES Monitor/ses.license.days_remaining)&gt;0 and last(/SES Monitor/ses.license.days_remaining)&lt;30</expression>
<name>SES: лицензия истекает через (&lt;30 дней) на {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -217,6 +226,15 @@
<trends>0</trends> <trends>0</trends>
<value_type>TEXT</value_type> <value_type>TEXT</value_type>
<description>Текст ошибки: "N сценариев упали". Пустая строка если всё хорошо.</description> <description>Текст ошибки: "N сценариев упали". Пустая строка если всё хорошо.</description>
<triggers>
<trigger>
<uuid>71bad15f-2b6e-4130-8567-4fd88f419bb5</uuid>
<expression>strlen(last(/SES Monitor/ses.scenario.error))&gt;0</expression>
<name>SES: критическая ошибка выполнения сценариев на {HOST.NAME}</name>
<priority>CRITICAL</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
</items> </items>

View File

@ -108,6 +108,14 @@
<value_type>FLOAT</value_type> <value_type>FLOAT</value_type>
<units>d</units> <units>d</units>
<description>Количество дней до окончания лицензии SES. -1 = бессрочная.</description> <description>Количество дней до окончания лицензии SES. -1 = бессрочная.</description>
<triggers>
<trigger>
<expression>{SES Monitor:ses.license.days_remaining.last()}&gt;0 and {SES Monitor:ses.license.days_remaining.last()}&lt;30</expression>
<name>SES: лицензия истекает через (&lt;30 дней) на {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -206,6 +214,14 @@
<trends>31536000</trends> <trends>31536000</trends>
<value_type>TEXT</value_type> <value_type>TEXT</value_type>
<description>Текст ошибки: "N сценариев упали". Пустая строка если всё хорошо.</description> <description>Текст ошибки: "N сценариев упали". Пустая строка если всё хорошо.</description>
<triggers>
<trigger>
<expression>{SES Monitor:ses.scenario.error.strlen()}&gt;0</expression>
<name>SES: критическая ошибка выполнения сценариев на {HOST.NAME}</name>
<priority>CRITICAL</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
</items> </items>

View File

@ -67,6 +67,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<trends>31536000</trends> <trends>31536000</trends>
<value_type>UNSIGNED</value_type> <value_type>UNSIGNED</value_type>
<key>ses.api.liveness</key> <key>ses.api.liveness</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.api.liveness.last()}=0</expression>
<name>SES API недоступен на {HOST.NAME}</name>
<priority>HIGH</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -86,6 +94,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<value_type>FLOAT</value_type> <value_type>FLOAT</value_type>
<units>ms</units> <units>ms</units>
<key>ses.api.response_time</key> <key>ses.api.response_time</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.api.response_time.last()}&gt;{$SES_API_TIMEOUT_MS}</expression>
<name>SES: медленный ответ API (&gt;{$SES_API_TIMEOUT_MS} мс)</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -104,6 +120,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<trends>31536000</trends> <trends>31536000</trends>
<value_type>UNSIGNED</value_type> <value_type>UNSIGNED</value_type>
<key>ses.license.ok</key> <key>ses.license.ok</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.license.ok.last()}=0</expression>
<name>SES: проблема с лицензией на {HOST.NAME}</name>
<priority>HIGH</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -123,6 +147,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<value_type>FLOAT</value_type> <value_type>FLOAT</value_type>
<units>d</units> <units>d</units>
<key>ses.license.days_remaining</key> <key>ses.license.days_remaining</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.license.days_remaining.last()}&gt;0 and {SES Monitor:ses.license.days_remaining.last()}&lt;30</expression>
<name>SES: лицензия истекает через (&lt;30 дней) на {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -161,6 +193,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<trends>31536000</trends> <trends>31536000</trends>
<value_type>UNSIGNED</value_type> <value_type>UNSIGNED</value_type>
<key>ses.scenario.ok</key> <key>ses.scenario.ok</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.scenario.ok.last()}=0</expression>
<name>SES: тестовые сценарии мониторинга падают на {HOST.NAME}</name>
<priority>AVERAGE</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -197,6 +237,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<trends>31536000</trends> <trends>31536000</trends>
<value_type>UNSIGNED</value_type> <value_type>UNSIGNED</value_type>
<key>ses.scenario.failed</key> <key>ses.scenario.failed</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.scenario.failed.last()}&gt;0</expression>
<name>SES: тестовые сценарии мониторинга падают на {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -253,6 +301,14 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<trends>31536000</trends> <trends>31536000</trends>
<value_type>TEXT</value_type> <value_type>TEXT</value_type>
<key>ses.scenario.error</key> <key>ses.scenario.error</key>
<triggers>
<trigger>
<expression>{SES Monitor:ses.scenario.error.strlen()}&gt;0</expression>
<name>SES: критическая ошибка выполнения сценариев на {HOST.NAME}</name>
<priority>CRITICAL</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
</items> </items>

View File

@ -160,6 +160,15 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<value_type>FLOAT</value_type> <value_type>FLOAT</value_type>
<units>d</units> <units>d</units>
<description>Количество дней до окончания лицензии SES. -1 = бессрочная.</description> <description>Количество дней до окончания лицензии SES. -1 = бессрочная.</description>
<triggers>
<trigger>
<uuid>67f94034-c31f-480f-aa47-68c986bdb2e9</uuid>
<expression>last(/SES Monitor/ses.license.days_remaining)&gt;0 and last(/SES Monitor/ses.license.days_remaining)&lt;30</expression>
<name>SES: лицензия истекает через (&lt;30 дней) на {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
<item> <item>
@ -323,6 +332,15 @@ JSON с метриками пишется в /var/tmp/ses_monitor/metrics.json
<trends>0</trends> <trends>0</trends>
<value_type>TEXT</value_type> <value_type>TEXT</value_type>
<description>Текст ошибки: "N сценариев упали". Пустая строка если всё хорошо.</description> <description>Текст ошибки: "N сценариев упали". Пустая строка если всё хорошо.</description>
<triggers>
<trigger>
<uuid>89a0f35d-cfc7-4d58-a0bf-96d9c56c85a2</uuid>
<expression>strlen(last(/SES Monitor/ses.scenario.error))&gt;0</expression>
<name>SES: критическая ошибка выполнения сценариев на {HOST.NAME}</name>
<priority>CRITICAL</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
</item> </item>
</items> </items>