[SOLVED] CUSTOM VARIABLE and EXTERNAL COMMAND
Posted: Tue Mar 01, 2016 10:49 am
Hello,
We use HOST CUSTOM VARIABLE in template file for all our WINDOWS servers.
We want to modify the value of those MACRO by external command
I try CHANGE_CUSTOM_HOST_VARIABLE like this :
/usr/bin/printf "[%lu] CHANGE_CUSTOM_HOST_VAR;host1;_THRES_FSYS_M;10%%\n" $now > $commandfile
By live status, we have modified attributes :
echo -e 'GET hosts\nColumns: host_name modified_attributes_list \nFilter: modified_attributes != 0' | unixcat /var/nagios/live
host1;custom_variable
But In thruk, this always the old value (5%)
How can i retrieve if the new value is apply (i don't have access on NSCLIENT)?
I Want to use to verify hourly if the custom variable is with the good value
Thanks
We use HOST CUSTOM VARIABLE in template file for all our WINDOWS servers.
We want to modify the value of those MACRO by external command
I try CHANGE_CUSTOM_HOST_VARIABLE like this :
/usr/bin/printf "[%lu] CHANGE_CUSTOM_HOST_VAR;host1;_THRES_FSYS_M;10%%\n" $now > $commandfile
By live status, we have modified attributes :
echo -e 'GET hosts\nColumns: host_name modified_attributes_list \nFilter: modified_attributes != 0' | unixcat /var/nagios/live
host1;custom_variable
But In thruk, this always the old value (5%)
How can i retrieve if the new value is apply (i don't have access on NSCLIENT)?
I Want to use to verify hourly if the custom variable is with the good value
Thanks