Different services for different hosts?

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Martco
Posts: 17
Joined: Fri Apr 25, 2014 1:55 pm

Different services for different hosts?

Post by Martco »

I have made 3 .cfg files, windows-svrs.cfg, windows-wks.cfg & cctvvm.cfg. windows-svrs has a hostgroup with a few servers in it, windows-wks has a few workstations in a hostgroup & cctvvm has just one host. svrs & wks use the same services, but cctvvm only uses one (PING). However, on the nagios site it shows that cctvvm is monitoring all the services that are listed in the other files? Why and how can I change/seperate these? Thanks.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: Different services for different hosts?

Post by lmiltchev »

Have you restarted the nagios service after making mods to your configs? Can you show us the "cctvvm.cfg" and a screenshot of what you see in the GUI?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Martco
Posts: 17
Joined: Fri Apr 25, 2014 1:55 pm

Re: Different services for different hosts?

Post by Martco »

###############################################################################
# CCTVVM.CFG - CONFIG FILE FOR MONITORING CCTVVM
###############################################################################


###############################################################################
# HOST DEFINITIONS
###############################################################################

# Define a host for the Windows machine we'll be monitoring
# Change the host_name, alias, and address to fit your situation

define host{
use WinCCTVVM ; Inherit default values from a template
host_name S_CCTVVM ; The name we're giving to this host
alias S_CCTVVM ; A longer name associated with the host
address 10.0.0.142 ; IP address of the host
}

###############################################################################
# SERVICE DEFINITIONS
###############################################################################

#####
#####...... Service Definitions for host_name windows-workstations .......
#####

define service{
use generic-service
host_name S_CCTVVM
service_description NegateExplorer
check_command negate!/usr/local/nagios/libexec/check_nt -H $HOSTNAME$ -v PROCSTATE -d SHOWALL -l explorer.exe
notification_interval 0
normal_check_interval 1
}
Attachments
cctvvm.jpg
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Different services for different hosts?

Post by tmcdonald »

I'm a little confused here. You said that cctvvm has only ping, but I see a check_nt applied to it. Are you sure you are referencing the proper files?

It might help to see your whole config directory. Can you tar and gzip your .../nagios/etc directory and send it in a PM?
Former Nagios employee
Locked