Использование Instance в скрипте.
-
-
Esli pri obrabotke sobitija, to dolzno rabotat' tak:
GetDCIValue($node, FindDCIByName($node, "Disk.Total(" . $6 . ")"));
-
И в таком варианте тоже не работает. Генерируется Minor Alarm на сервере NETXMS c полем Message: Script (LS::P1) execution error: Error 5 in line 3: Invalid operation with NULL value.
Вообще у меня стоит задача сформировать и послать по email сообщение, генерируемое по treshold DCI "Percentage of free disk space".условие treshold: Percentage of free disk space < 10%
event: _VOL_SPACE_LOW
message: Warning! %2 is %4%% (%[LS::P1]). Please free some space!
скрипт LS::P1sub main() { return GetDCIValue($node, FindDCIByName($node, "Disk.Total(" . $6 . ")")); } -
A kak vigljadit parametr Disk.Total i chto propisano v pole "instance" dlja parametra so skriptom? Problema pohoze v tom, chto formiruetsja nepravil'noe imja parametra, i FindDCIByName vozvraschaet NULL.
-
-
A parametr Disk.Total(D:) sobiraetsja?
-
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login