Page 1 of 1

monitoring hosts using ssh - can you change default account?

Posted: Tue Jan 30, 2018 6:55 am
by paulconca
Moderator Edit: This thread has been split from another - https://support.nagios.com/forum/viewto ... =6&t=45292

In the future, please create a new thread and link to the old one instead of adding on.


Same question :!:

All the server we need to monitor already have an account and keys (not Nagios).

Is it possible use a different account on the Nagios Monitoring server to SSH to the client servers?

Thank you

Re: monitoring hosts using ssh - can you change default acco

Posted: Tue Jan 30, 2018 1:48 pm
by dwhitfield
Yep:

Code: Select all

./check_by_ssh --help
check_by_ssh v2.2.1 (nagios-plugins 2.2.1)

....

 -l, --logname=USERNAME
    SSH user name on remote host [optional]

....

Re: monitoring hosts using ssh - can you change default acco

Posted: Wed Jan 31, 2018 6:34 am
by paulconca
Thank you

I am presuming you need a private key for the non-Nagios account?

If yes, where do you put that key?

Regards

Re: monitoring hosts using ssh - can you change default acco

Posted: Wed Jan 31, 2018 10:43 am
by dwhitfield
You'll just need to follow https://assets.nagios.com/downloads/nag ... ng_SSH.pdf but use a different account than nagios.