3 Nagios servers, 1 site

Hi, I have a problem. The company I work for has so many servers, that they want to use seperate Nagios servers on different locations so they can evenly distribute the load caused by monitoring. I’ve been assigned to make this new solution possible. My question is, is there an easy way to combine data from different Nagios servers to 1 Nagios website? We would like to manage the 3 servers from 1 location. Thanks in advance for the feedback.

Kind regards,
Arjan Meijer

That is indeed possible. Kind of a distributed Nagios setup. You’ll need to use a daemon called NSCA on the three servers to send the information about the hosts on their site to the main Nagios server.

Managing the servers from one location is easy as long as you can somehow remotely login into them, through ssh, telnet, etc.

Yes I get all kinds of funky errors about invalid variables, etc. I went to fix 2 which was sufficient to discover that it will be an endless monkeying around so I decided to ask the experts instead - what modifications did youhave to make to your file in order to get nagos 2.0 running? Could you be more specific so I can do the same

Thanks

You won’t be managing the 3 remote servers from the one website. What you will be managing is the central nagios server, where the other 3 remote servers send there output, via nsca.
In order to manage the remote servers, it will require a ssh connection to be made and vi the .cfg files, etc. as SonOfThunder has pointed out.

Not a problem though, and I have many many remote servers sending me data via nsca, and rarely have to mess with the remote ones.

OK thanks for the replies. Im going to install NSCA en test it, if i have any questions i’ll post them here hoping you can help me.

Oops, double post.

OK, this may sound dumb, but do i need to run Nagios aswell on the remote servers? Or is send_nsca enough…

You’ll have to run what could be called a mini-Nagios setup. This will mean installing Nagios without the CGI’s or web interface. It will serve only to run the local checks on the local system, and you will need to then use check_nsca to send the check output back to the central Nagios server.

If you check the NSCA sticky in this forum, you’ll find a wonderful little script jakkedup has written for your ocsp command, which will be run after every host/service check.

I didn’t write any scripts, just to be clear about that. :slight_smile:

Anyway, if you truly wish to decrease load on the ONE network, then why not go ahead and install the whole nagios on each of the nodes, including apache.
Or, do as Son pointed out, and use mini setups, all sending to central server.

What I am setting up now, is full nagios setups on each network segment, and each is sending to central server. In time, the central server will be 100% passive, getting all check result data from the worker bees.

That sounds like a good setup, but i think we’re too small for that yet. The central Nagios server is supposed to be set up at our office, and most of the monitored servers are evenly distributed over 2 datacenters on another location. The other 2 Nagios servers are going to be placed in those 2 datacenters. In total there are about 700 servers to be monitored. To make things easier for the administrators we want to collect al data from all the checks from all 3 servers, and show them on 1 Nagios site, instead of 3 sites for each server. Monday om going to sit down with an engineer to find out what NSCA can do for us exactly.

That is what I am suggesting. But since you have nagios installed and making checks on the 3 segments of your network, you might as well install apache. The reason I suggest this, is because your central server may die, and now you have no way of looking at the status of your network. Remember, the Cnetral nagios server will be 100% passive, and making no checks of it’s own. This allows you to view the entire network in one place.

If any 1 of your other boxes dies, it is easy to change the central nagios server from passive checks to active checks.

Just go for distributed Nagios like Jakkedup said. We do run 1 mainserver with 3 substituded Nagios servers. These substituted servers just act like a normail Nagios server, but sends the results to the mainserver using the nsca client.

Its like: Substituted server does a check on a server by nrpe, the result will be send to the main nagios by send_nsca…

As I stated, you will have your 3 remote nagios machines collecting data and sending via nsca to the central location. But, if you actually want to be able to do things like look at the config files, force a check, disable a check, then I’d suggest you do as I did. Install Apache and nagios on those 3 machines. Each machine can be viewed via the web. Each machine will be collecting data for ONLY it’s segment of the network. Each machine will be controlled via the website urls to each of them. You can force checks, etc. But the big thing here is this:
All 3 servers will be sending there data to ONE central server. That server will be the one you most often look at. Since it shows EVERYTHING. But, you can’t force a service check from that machine, since it is not an ACTIVE machine. All of it’s checks are passive checks coming in via nsca from the other 3.

It’s so much easier to manage that way. Rather than having cronjobs running, etc. on the remote 3 machines.