I am setting up Nagios check_hpjd
plugin, but it doesn't recognize "const" command.
I am using Nagios 4.x on a Linux server, and was setting up some network printers to monitor and decided to add check_hpjd
plugin, for more detailed information, but unfortunately it started to give me:
/libexec/check_hpjd: line 1: const: command not found.
I think it is pointless to copy the whole check_hpjd
plugin code here, I just copy the first line here, the system gave me error on:
const char *option_summary = "-H host [-C community]\n";
Should I define the const character somehow or how can I fix it, tried to look from several sources on web aswell, but there is very little info about it unfortunately.
You are using source code of that plugin, so the behavior is correct... You need use builded version, like here for Centos7/RHEL7.