Monitoring Ubuntu, Agent File

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Monitoring Ubuntu, Agent File

Post by abrist »

What errors are you receiving?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
tonyyarusso
Posts: 1128
Joined: Wed Mar 03, 2010 12:38 pm
Location: St. Paul, MN, USA
Contact:

Re: Monitoring Ubuntu, Agent File

Post by tonyyarusso »

A.Cormack wrote:Tony - The guide that you've just mentioned would it be useful in my situations? I did just try to the first command "add-apt...." but it didn't like it.
Yeah, that guide will install NRPE, plugins, and some command definitions. If you get a "command not found" error for add-apt-repository, you need to do 'apt-get install python-software-properties' first. (That should be added to the guide too, since that package is not standard on current Ubuntu server installations. It should probably also mention that the package is in universe, so you'll need to make sure that's enabled.)
Tony Yarusso
Technical Services
___
TIES
Web: http://ties.k12.mn.us/
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Re: Monitoring Ubuntu, Agent File

Post by A.Cormack »

Abrist - The error i get is..

Code: Select all

nagiosadmin@ubuntu:/tmp/nrpe-2.14$ make install
cd ./src/ && make install
make[1]: Entering directory '/tmp/nrpe-2.14/src'
make install-plugin
make[2]: Entering directory '/tmp/nrpe-2.14/src'
/usr/bin/install -c -m 775 -o nagios -g nagios -d /usr/local/nagios/libexec
/usr/bin/install: invalid user 'nagios'
make[2]: *** [install-plugin] Error 1
make[2]: Leaving directory '/tmp/nrpe-2.14/src'
make[1]: *** [install] Error 2
make[1]: Leaving directory '/tmp/nrpe-2.14/src'
make: *** [install] Error 2
Tony - Yeah, I tried the apt-get python command before but it still says the command is not found, but i know that is due to something stupid i've missed somewhere
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Monitoring Ubuntu, Agent File

Post by abrist »

Looks like you need to make a nagios user/group first. Try:

Code: Select all

useradd -U -M nagios
And then try running the compile again.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Re: Monitoring Ubuntu, Agent File

Post by A.Cormack »

That workd Abrist and I did the rest of the guide too which all seemed to work. Then i closed Vmware to change to a bridge connection, loaded it up and all the files had gone :/
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Monitoring Ubuntu, Agent File

Post by scottwilkerson »

It is likely setup, your system is likely clearing the files from /tmp when you shut-down the VM
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Re: Monitoring Ubuntu, Agent File

Post by A.Cormack »

Ah ok, so I'm guesssing I need to stop VMware clearing the files? or put the nagios folder in a different location?
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Monitoring Ubuntu, Agent File

Post by abrist »

Just move your working source folder to your directory in /home. Then the files will stay persistent through reboots.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
A.Cormack
Posts: 103
Joined: Fri Nov 23, 2012 6:32 pm

Re: Monitoring Ubuntu, Agent File

Post by A.Cormack »

Sorry to be a pain, but still no luck. Followed the guide that Abrist has done.

Went into "nano /usr/local/nagios/etc/nrpe.cfg" changed...

server_address=192.168.19.134
allowed_hosts=127.0.0.1,192.168.19.134
dont_blame_nrpe=1

but Nagios still saying connection is refused
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Monitoring Ubuntu, Agent File

Post by abrist »

The server_address directive is the ip of the interface the nrpe server should use, essentially it should be set to 127.0.0.1 unless the remote host has more than 1 interface (it should not be set to the nagios server ip).

On the nagios XI server, run nmap to test port 5666

Code: Select all

nmap 192.168.19.134 -p 5666
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Locked