# nagios configuration question

## slam_head

I recently set up nagios and I'm trying to get it more functional. I'd like to use the check_by_ssh module to get information on remote hosts such as disk usage(df -h), and cpu utilization(w) and set notifications based on these paramaters. Does anyone have a working example they could share.

----------

## tdemarest

We have a moderately complex nagios setup, but I haven't been using check_by_ssh. We use the nrpe setup, which works quite nicely.

----------

## slam_head

I would prefer not to have to install anything on the client machines.  Also security as a big concern in our network so ssh is desirable.

----------

## slam_head

In the end I couldn't get the check_by_ssh working properly, so I used nrpe.  I would have prefered something with encryption and authentication.

----------

## Mad_Jester

We use check_by_ssh for all of our local checks.  If you are still looking for help or examples I would be happy to help.

----------

## m4chine

 *Mad_Jester wrote:*   

> We use check_by_ssh for all of our local checks.  If you are still looking for help or examples I would be happy to help.

 

I would appreciate some examples of a check_by_ssh implementation. I just installed nagios-2.2 but I can't seem to get check_by_ssh working. I've setup pub_keys for authentication, but in the monitor i see this: "Could not create directory '/dev/null/.ssh'."

Any help would be appreciated. Thanks.

----------

## Mad_Jester

 *m4chine wrote:*   

> 
> 
> I would appreciate some examples of a check_by_ssh implementation. I just installed nagios-2.2 but I can't seem to get check_by_ssh working. I've setup pub_keys for authentication, but in the monitor i see this: "Could not create directory '/dev/null/.ssh'."

 

First you need to get ssh working between systems for the nagios user.  Right now it looks like the nagios user doesn't have a valid home directory, instead just /dev/null.  Check the passwd file and set nagios up with a home dir.  

Then create nagios users on the remote systems.  Verify ssh between nagios users via the IP's rather than the names.  Get it all working outside of nagios first.

----------

