object CheckCommand "nrpe2" {
        import "nrpe"
        arguments["-2"] = {
            set_if = "true"
            description = "Only use Version 2 packets, not Version 3"
        }
}

I dont know where "hostalive-common" and "nrpe" come from.
when i try define my one "nrpe" check command i get an error
"redefine ...."

Am 19.12.2017 um 12:41 schrieb Michael Friedrich:
> 
> 
>> On 19. Dec 2017, at 12:33, basti <mailingl...@unix-solution.de> wrote:
>>
>> Hello,
>>
>> I have destroy my icinga2 config.
>> Yesterday I have change something and after that nothing has worked again.
>> I have search and try many thinks nothing helped.
>>
>> A Host looks like:
>>
>>
>> object Host "host-behind-firewall" {
>>
>>     vars.check_ipv4 = true
>>     vars.os = "Linux"
>>
>>     vars.nrpe_parent = "firewall"
>>     check_command    = "nrpe-behind-parent"
>>     vars.checks_nrpe = [ "host",
>>                          "apt",
>>                          "ntp",
>>                          "load",,
>>                          "release",
>>                          "disk_/",
>>                        ]
>> }
>>
>> My check command looks like:
>>
>> object CheckCommand "nrpe-behind-parent" {
>>         import "hostalive-common"
>>         import “nrpe2"
> 
> Where are these template definitions?
> 
>>         command = [ PluginDir + "/check_nrpe" ]
>>
>>         vars.nrpe_address = "$nrpe_parent$"
>>         vars.nrpe_command = "check_" + "$host$" + "_$name$"
>> }
>>
>> And there is the Problem I Think.
>>
>> All checks return "NRPE v2.15".
>>
>> When I try from commandline:
>>
>> /usr/lib/nagios/plugins/check_nrpe -t 30 -H firewall  -c
>> check_host-behind-firewall_ntp
>>
>> I get a valid result.
>>
>> NRPE v2.15 seems to be returned when no check is specified.
>>
>> What's wrong in my checkCommand?
>>
>> Best Regards,
>> Basti
>>
>> _______________________________________________
>> icinga-users mailing list
>> icinga-users@lists.icinga.org
>> https://lists.icinga.org/mailman/listinfo/icinga-users
> 
> _______________________________________________
> icinga-users mailing list
> icinga-users@lists.icinga.org
> https://lists.icinga.org/mailman/listinfo/icinga-users
> 
_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users

Reply via email to