Koozali.org: home of the SME Server
Obsolete Releases => SME 8.x Contribs => Topic started by: Bud on April 29, 2012, 09:22:04 AM
-
Please guys i need some help again :D
I have 5 x SME 8 Servers and need to monitor them using Nagios (On another Distro :sad: )
My question is all i want to do is install the NRPE Contrib on the SME 8 Servers, however when i get to " Allow the central Nagios server to access the NRPE service " as per the link http://wiki.contribs.org/Nagios_NRPE i cannot get the NRPE to install or configured on any of the SME 8 Servers
Please can you explain what i am doing wrong or what need to do to get NRPE Installed on the Remote SME Servers.
Any help greatly appreciated
-
you forgot to tell us the meaning of "i cannot get the NRPE to install or configured on any of the SME 8 Servers"
please remember that no one has a crystal ball so if you need help you must help us to understand your issue..
please report here the exact error message, thank you
-
Stefano thanks for your reply
Sorry, what i want to know is that i followed the how to install as per link http://wiki.contribs.org/Nagios_NRPE for the SME 8 Servers.
When i get to the area where it says:
========================
NRPE configuration
Create a the NRPE configuration file /etc/nagios/nrpe.cfg. Use the nrpe.cfg provided by this conrib as a starting point. Add the IP address of your central Nagios server to the variable allowed_hosts. Use the local IP of the central Nagios server if you check the server over the local network or over a VPN, otherwise use the WAN IP.
========================
There is No file called nrpe.cfg in /etc/nagios/ on the SME 8 Servers
I need to understand how to configure the nrpe.cfg file for the SME 8 Servers. Must i also forward port 5666/tcp to the SME 8 servers
Also what do i do in:
========================
Allow the central Nagios server to access the NRPE service
Add the IP address of the your central Nagios to Local Networks in the server-manager.
Configure the TCP wrapper. This is required for SSL connections to the NRPE.
=======================
The Remote Nagios Server is using DynDNS
Sorry for the Noob Questions :)
-
bud, please, re-read carefully here (http://forums.contribs.org/index.php/topic,48523.msg241064.html#msg241064)
-
Stafano thanks for your reply :)
I do know about the solution you pointed to - thank you mmccarn
However that was when i was going to use SME 8 with the " Nagios Server " Contrib as the " Nagios Server Monitoring Solution "
Now the client is using another distro with Nagios to monitor the 5 x SME Servers
Are you saying that I also need to install rhe " Nagios Server " contrib on all SME Servers including the " NRPE Contrib "in order for the NRPE " Client " to work on those servers?
Sorry i was under the impression that all i needed to do was install the " NRPE Client " Contrib on the SME Servers in order for Nagios ( which is on a different distro ) to monitor the SME Servers.
Please confirm
-
NRPE SME8 Installation
Configure the dag repositoy
The following command will configure the dag repository on SME Server.
/sbin/e-smith/db yum_repositories set dag repository \
Name 'Dag - EL5' \
BaseURL 'http://apt.sw.be/redhat/el5/en/$basearch/dag' \
EnableGroups no \
GPGCheck yes \
GPGKey http://dag.wieers.com/packages/RPM-GPG-KEY.dag.txt \
Visible no \
Exclude freetype,htop,iptraf,rsync,syslinux \
status disabled
After adding it to the database we have to update the changes to the configuration file:
signal-event yum-modify
/usr/bin/yum --enablerepo=dag install \
nagios-plugins \
nagios-plugins-setuid \
perl-Config-Tiny \
perl-Class-Accessor
Copy nrpe rpm's and install
yum localinstall nagios-3.2.1-5.el5.rf.i386.rpm
yum localinstall nagios-nrpe-2.5.2-1.el5.rf.i386.rpm
yum localinstall nagios-plugins-nrpe-2.5.2-1.el5.rf.i386.rpm
vim /etc/nagios/nrpe.cfg
allowed_hosts=127.0.0.1,62.249.247.18
cd /etc/rc7.d
cp -s /etc/init.d/nrpe S95nrpe
port forward 5666 to localhost
vim /etc/e-smith/templates/etc/hosts.allow/nrpe
{
$OUT="nrpe: " . ($nrpe{HostsAllow} ? $nrpe{HostsAllow} : "127.0.0.1 62.249.247.18" );
}
expand-template /etc/hosts.allow
service nrpe restart
-
vim /etc/e-smith/templates/etc/hosts.allow/nrpe
That should be:
mkdir -p /etc/e-smith/templates-custom/etc/hosts.allow
vim /etc/e-smith/templates-custom/etc/hosts.allow/nrpe
-
Hi All
I know this is an old thread but Garys instructions are excellent and still relevant for installing Nagios as a client only configuration.
Just expanding on the section in the instructions
Copy nrpe rpm's and install
yum localinstall nagios-3.2.1-5.el5.rf.i386.rpm
yum localinstall nagios-nrpe-2.5.2-1.el5.rf.i386.rpm
yum localinstall nagios-plugins-nrpe-2.5.2-1.el5.rf.i386.rpm
The locations of the rpm's to download (at least as at now) before installing them are:
http://pkgs.repoforge.org/nagios/nagios-3.2.1-5.el5.rf.i386.rpm
http://pkgs.repoforge.org/nagios-nrpe/nagios-nrpe-2.5.2-1.el5.rf.i386.rpm
http://pkgs.repoforge.org/nagios-nrpe/nagios-plugins-nrpe-2.5.2-1.el5.rf.i386.rpm
I also made a few minor changes and included Charlie's comments in my blog post.
http://howden.net.au/thowden/2013/05/sme-server-as-a-nagios-nrpe-client-only/
cheers
Tony
-
That should be:
mkdir -p /etc/e-smith/templates-custom/etc/hosts.allow
vim /etc/e-smith/templates-custom/etc/hosts.allow/nrpe
But why create a custom template when all you need to do is set a db property?
config setprop nrpe HostsAllow '127.0.0.1 a.b.c.d'
-
Actually, I see you do need a custom template here. But I would still use a custom template and a database property:
{
$OUT="nrpe: ";
$OUT .= $nrpe{HostsAllow} || "127.0.0.1";
}
and then:
config setprop nrpe HostsAllow '127.0.0.1 a.b.c.d'
to allow the remote access.
-
Hi Charlie
Actually, I see you do need a custom template here. But I would still use a custom template and a database property
I have not researched this, but I have always assumed (dangerous, I know) that the database entries were for the developers and that my dabbling with custom-templates was more for the server admin to allow for modifications.
I like the custom templates as I can 'see' what's going on, while the database entries are hidden. Is there any documentation that helps to enlighten me on this? I am interpreting your comments to say that there are cases when templates are 'needed' rather than optional, and times when database entries are 'required' in addition to templates, which also puzzles me as I would have thought one-or-the-other.
Specifically with this configuration, it is working without a database entry. How does the DB entry help?
Thanks.
Tony
-
If you don't want to use the configuration db, then all your custom template needs to contain is:
127.0.0.1 62.249.247.18