SSH Ports


Hi All.
Finished instaling Nagios this morning, everything went very smooth. Grats on the install instructions all.
I have one slight, niggling problem. In the Service Details thread, it says that SSH - connection refused.

I’ve been reading around, found a post on this foum that it was because the port is non-standard. Which is true.
I’ve also tried to perform some of the fixes, one that was also on this forum, but im rather new to Linux. It went over my head a bit.

Could anyone break it down for me, please?
(Sorry again about this everyone)



edit 2 files
commands.cfg and the cfg for your host where you call the ssh check.

in commands.cfg change what follows command_line to read (do this in the part of the file defining ssh)
$USER1$/check_ssh -H $HOSTADDRESS$ -p $ARG1$

Then in the other cfg file change the section defining the ssh service check so that after check_command it says

assuming 5900 was your non standard port.


Im running an Apache2 Server, I’ll assume thats the host. I’ve been through all the files, but can’t find anything to do with the check_ssh! thing.


check /usr/local/nagios/etc/objects/command.cfg


Sorry, I didn’t make that clear enough.

I found and edited this one.

[quote=“Joshua Hughes”]
edit 2 files
commands.cfg and … [/quote]

but not this one.

Hope that helps! Thanks for all the replies so far!