Привет, Всем.
Есть простой скрипт
#!/bin/bash
user="$1"
pass="$2"
curl -sS "https://sm.megafon.ru/sm/client/[email protected]&password=$pass" | grep balance| cut -d "<" -f2 | cut -d ">" -f2
Нужен для проверки баланса, и потом модифицировать хочу для проверки статуса мультифона.
В консоли отрабатывает.
Дальше добавил его в скрипты вот так http://joxi.ru/8AnXg9bSj5g0Qm
Создал шаблон, с элементом данных http://joxi.ru/RmzXdVoS01JG1A
Но не работает в логах ошибка
cat zabbix_server.log | grep megafon
30368:20180611:151100.302 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
30366:20180611:151402.071 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (float)]
30374:20180611:151903.178 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Unsupported item key.
30371:20180611:153904.260 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Unsupported item key.
30370:20180611:154004.645 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Unsupported item key.
30369:20180611:155105.826 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (float)]
30373:20180611:161306.824 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (float)]
30366:20180611:163808.671 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
Подскажите что сделал не так?
Есть простой скрипт
#!/bin/bash
user="$1"
pass="$2"
curl -sS "https://sm.megafon.ru/sm/client/[email protected]&password=$pass" | grep balance| cut -d "<" -f2 | cut -d ">" -f2
Нужен для проверки баланса, и потом модифицировать хочу для проверки статуса мультифона.
В консоли отрабатывает.
Дальше добавил его в скрипты вот так http://joxi.ru/8AnXg9bSj5g0Qm
Создал шаблон, с элементом данных http://joxi.ru/RmzXdVoS01JG1A
Но не работает в логах ошибка
cat zabbix_server.log | grep megafon
30368:20180611:151100.302 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
30366:20180611:151402.071 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (float)]
30374:20180611:151903.178 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Unsupported item key.
30371:20180611:153904.260 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Unsupported item key.
30370:20180611:154004.645 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Unsupported item key.
30369:20180611:155105.826 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (float)]
30373:20180611:161306.824 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (float)]
30366:20180611:163808.671 item "79296766219:megafon.sh[{$LOGIN}","{$PASSWORD}"]" became not supported: Received value [] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
Подскажите что сделал не так?
Comment