Page 1 of 1

Nogios config file in windows

Posted: Fri Mar 21, 2014 2:43 am
by rnk
Hello NagiosTeam,

We have installed nagios windows server & clinet ("NSCP-0.4.1.73-x64.exe(NSclinet ++)) successfully and also we are able to connect the host using check_nrpe. present we are facing the issues with configurations, we are not able to add more host entries & services in configuration, could you please help me in adding multiple hosts and services. because of this issue we are not proceeding further.

My Host entry file configuration:
=========================

Code: Select all

define host{
        use                     windows-server,host-pnp            ; Name of host template to use
							; This host definition will inherit all variables that are defined
							; in (or inherited by) the linux-server host template definition.
        host_name               < >
        alias                   < >
		hostgroups             windows-servers
        address                 < >
        }
	define service{
        use generic-service
		host_name < >
		service_description CPU Status
		check_command check_nrpe!alias_cpu
		}
	define service{
        use generic-service
		host_name < >
		service_description Service Status
		check_command check_nrpe!alias_service
		}
		
		define host{
        use                     windows-server,host-pnp            ; Name of host template to use
							; This host definition will inherit all variables that are defined
							; in (or inherited by) the linux-server host template definition.
        host_name             < >
        alias                   < >
		hostgroups             windows-servers
        address                 < >
        }
		

	define service{
        use generic-service
		host_name < >
		service_description c: Free Space
		check_command check_nrpe!alias_disk
		}
===========================================

Note : If i add one more service immediately web url is not working.

Thanks & Regards,
Naveen.

Re: Nogios config file in windows

Posted: Fri Mar 21, 2014 11:06 am
by slansing
Okay, so we are going to need more information. When you say you try to add additional configurations, or alter the configuration you have already defined, the nagios web UI breaks? What is being displayed when trying to access the web interface? Have you verified that the configuration files are clean? It's quite possible they are not, and nagios will not start because of that.

If you are using Centos/RHEL with a standard Nagios installation please run the following and show the output, "BE SURE TO WRAP YOUR CODE IN CODE WRAPS," you can click the 'Code' button when you are writing your reply to do this:

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
If your nagios binary, or configuration file are in different directories, please make those changes to the command above.


Also, what is the output of:

Code: Select all

service nagios status

service httpd status
And what version of Nagios are you using? On what distribution?

Re: Nogios config file in windows

Posted: Tue Apr 01, 2014 1:37 am
by rnk
Thanks for sharing the information, currently we are using only windows servers, if we add more host entries in config file then execute "check nagios configuration" command we are getting the no errors, no exception in configuration file.

config details :
============================
Checking objects...
Checked 15 services.
Checked 3 hosts.
Checked 1 host groups.
Checked 0 service groups.
Checked 1 contacts.
Checked 1 contact groups.
Checked 23 commands.
Checked 5 time periods.
Checked 0 host escalations.
Checked 0 service escalations.
Checking for circular paths...
Checked 3 hosts
Checked 0 service dependencies
Checked 0 host dependencies
Checked 5 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors: 0

Things look okay - No serious problems were detected during the pre-flight check
==================================

2) if we check windows services " all 4 nagios services are running success fully".
service details : 1) Nagwin_nagios 2) Nagwin_nagiosfcgi 3) Nagwin_Nginx 4) Nagwin_phpfcgi

3) config file available path is : C:\Program Files (x86)\ICW\etc\nagios\nagwin

4) finally we are cecking the weburl we are not getting the data

5) present 3 host entries added in config file, if we remove the one host entry in config-file, then restart the service we are able to see the web results.

please help me how to add multiple host entries/services in nagios config files, if you have any standard template for windows please share with us.

Thanks & Regards,
Naveen

Re: Nogios config file in windows

Posted: Tue Apr 01, 2014 3:51 pm
by abrist
Just an FYI: nagwin is not controlled by Nagios Enterprises, so for specific issues of cygwin etc, you will most likely have to consult the nagwin guys.
rnk wrote:5) present 3 host entries added in config file, if we remove the one host entry in config-file, then restart the service we are able to see the web results.
Which host is currently having the issue?

I would suggest that you read through the nagios core handbook - it covers many topics including writing config files:
http://library.nagios.com/library/produ ... e/manuals/