Hi All,
I am complete new to Icinga, started using Icinga just last week. With help of online community forums I tried monitoring disk services on linux host without using agent. I added public key of “nagios” user from master server to the hosts, command line working fine using check_by_ssh plugin for all the hosts added. But the problem is with Icingaweb2 ui. I am able to see service working fine on only first host added but other host added afterwards are throwing “check_by_ssh” returned status 255. Below are my conf files:
- commands.conf
object CheckCommand “diskchecksun” {
import “plugin-check-command”
command = [ PluginDir + “/” + “check_by_ssh”, “-q”, “-H”, “$address$”, “-l”, “$user$”, “-C”, "$plugin_path$/check_disk -w $warningg$ -c $criticall$ -p $path1$ -p $path2$ " ]
}
- services.conf
apply Service “disksun” {
import “generic-service”
check_command = “diskchecksun”
assign where host.vars.agent == “db_sun”
}
- hosts.conf
object Host “host1” {
import “generic-host”
address = “host1.xyz”
vars.os = “Linux”
vars.agent = “db_sun”
vars.user = “host1user”
vars.plugin_path = “/host1/plugin/path”
vars.warningg = “10%”
vars.criticall = “5%”
vars.path1 = “/host1/path1”
vars.path2 = “/host1/path2”
}
object Host “host2” {
import “generic-host”
address = “host2.xyz”
vars.os = “Linux”
vars.agent = “db_sun”
vars.user = “host2user”
vars.plugin_path = “/host2/plugin/path”
vars.path1 = “/host2/path1”
vars.path2 = “/host2/path2”
}
In this example “host1” is working fine but “host2” is throwing error.
Please help to resolve the issue.
The Icinga 2 network monitoring daemon (version: r2.10.5-1)