NSCA setup on Nagios itself?


I’ve been reading up on passive checks and writing to the command file via NSCA. I’ve setup the daemon on the Nagios host just fine and also installed the check_nsca program plus the plugins on the remote hosts. Am I right in thinking that I don’t need to install Nagios itself on each remote host to do this? - I’ll set up a cron job for each type of service that will write back to the command file of the Nagios host every few minutes or so.
However, the distributed monitoring section implies that Nagios itself must be installed on each remote machine via the diagram. True?

What I’m confused about is how/what I have to define in my hosts/services config file in order for this to work. The docs make no mention of having to set up anything else either in the NSCA readme or the official Nagios docs. Are the entries in the command file automatically associated with a host in the hosts.cfg file and is the whole thing automatic?

Anything else to set up?

Edited ]


Hi Rage,

Here is what I understood. I m expecting somebody else to correct me if I understand wrong.

for small site (if you don’t have many hosts to monitor) just use active check would be fine.

nagios server (nagios/web interface/check_nrpe/plugins)
host1 host2 (nrpe/plugins)

for large amount of hosts / different locations, it needs passive check from distributed nagios server to central nagios server. However, distributed nagios server would still use active check for the hosts it responsible for checking.

              central nagios server  
      (nagios/web interface/plugins/nsca)
                   /                     \

distributed nagios srv1 distributed nagios srv2
| |
/ \ /
host1 host2 host3 host4

above is just my 2 cents, may not be correct, trying to understand it too.



oops! the forum changed the format, hope you can figure it out.


I would just use NRPE, but I can only get it to work on one of my remote hosts. The rest don’t show up as processes using ‘ps -elf | grep nrpe’ (I’m running NRPE as stand-alone daemon) and Nagios won’t pick up the services, so I’m assuming its not running for whatever reason.

So using NSCA is really the only way I can monitor remote hosts…but I don’t know how to set up my service on the Nagios server to read in the command file. The manual states that the service definitions must match in the config files for both the remote Nagios host and the central one…but I don’t see how you can do that when a service requires a check_command.


from my understanding

  1. NSCA is used between central nagios server and distributed nagios server, have nothing to do with the end host monitoring.
  2. if you got a problem when running the nrpe, you might need to troubleshoot on that anyway, because distributed nagios server need nrpe to get information too.
  3. I m not sure if I understand you correctly but seems you confuse about the function of NSCA.

correct me if I m wrong, thanks.



here is what I got from the list user Scott Sugar, I think his points are clear. FYI.

Central host has:
Nagios Web Interface
Nagios Plugins
Nagios Config files for all the hosts and services you want to see on the web interface (including services that are passivly checked)
NSCA daemon

Each Distributed host has at least:
Nagios Plugins
check_nrpe -> to query the NRPE daemons on each monitored machine
send_nsca -> to passivly send the results back to the central server

And each remote host that you are monitoring has:
NRPE daemon OR
NRPE_NT daemon for winnt -> win2k3
as well as any plugins that you want to run on that machine
note that NRPE_NT requires plugins that run under windows…


service_description must match on both, not the check command. The remote host performs the active check, and the nagios server is setup to accept passive checks. If you have freshness checking enabled, then use the service_is_stale active check.