Answer the question
In order to leave comments, you need to log in
Same value for all hosts to check in Icinga2?
Hello.
I did some RAM check. I made this service:
apply Service "memory" {
check_command = "mem"
assign where host.vars.os == "Linux"
vars.mem_used = true
vars.mem_cache = true
vars.mem_warning = 85
vars.mem_critical = 95
}
object CheckCommand "memory" {
import "plugin-check-command"
command = [ PluginDir + "/check_mem.pl" ]
arguments = {
"-w" = {
required = true
value = "$mem_warning$"
}
"-c" = {
required = true
value = "$mem_critical$"
}
"-u" = {
required = true
value = "$mem_used$"
}
"-C" = "$mem_cache$"
}
vars.mem_used = true
vars.mem_cache = true
vars.mem_warning = 85
vars.mem_critical = 95
}
Answer the question
In order to leave comments, you need to log in
In short, I got it.
You need to add a check for hosts in hosts.conf
in services.conf in this service add:
connect the client to the server using icinga node wizard
Check in zones.conf for the presence of the following line:
object Endpoint "hostname" {
host = "199.99.99.99"
}
object Zone "client-zonename-hostname" {
endpoints = [ "hostname" ]
parent = "master"
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question