Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save amolkhanorkar/6728159 to your computer and use it in GitHub Desktop.
Save amolkhanorkar/6728159 to your computer and use it in GitHub Desktop.
Nagios check nrpe error could not complete ssl handshake
When you are tying to connect remote host from nagios server using check_nrpe you may get following error.
$ /usr/lib/nagios/plugins/check_nrpe -H remotehostIP
Output:
check_nrpe error could not complete ssl handshake
Reason for this error is remote host not allowing the nagios server to run command using check_nrpe.
To overcome this problem we need to add ip address of nagios server in remote machine.
Open /etc/nagios/nrpe.cfg using any editor. Then search for allwoed_hosts.
By default allowed host value is allowed_hosts=127.0.0.1
Change 127.0.0.1 to nagios server ip address.
Let’s say if my nagios server ip address 192.168.1.20, you should add as below
allowed_hosts=192.168.1.20
Now restart nagios-nrpe-server in remote host.
$ service nagios-nrpe-server restart
Restart nagios3 and nagios-nrpe-server in nagios server.
$ service nagios3 restart
$ service nagios-nrpe-server restart
Now if you run following command in nagios server, your will get nrpe version details.
$ /usr/lib/nagios/plugins/check_nrpe -H remotehostIP
Output:
NRPE V2.12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment