Timeperiod already been defined

Gotner, James jgotner at fhcrc.org
Wed Apr 16 01:46:00 CEST 2003


List members,

  I am having no luck getting this going.  I have tried removing the second
entry, only to have nagios -v complain about the first entry already being
defined.  I did a grep on all of my config files and the timeperiods only
show up in timeperiods.cfg once each.  I have tried changing the timeperiod
names and I have tried retyping the config file from scratch and still get
the same problem...  Could someone look at my config file and tell me if
there is anything wrong?  I built my config file according to the
documentation, so I wouldnt think that there is a problem.  Is there a
problem compiling nagios with gcc that comes with redhat 7.3?  I know there
have been intermittent problems with gcc 2.96, since it is actually redhat's
version and not supported by the gcc community, and also has caused problems
with compiling other programs... Has anyone gotten nagios to work on RH 7.3
at all?  Has anyone had a problem compiling nagios with gcc v3.2.x, as that
will probably be my next step?  Can nagios work under cygwin, so I can test
my config files at least?  Thanks for any help...

James Gotner

Security Certified Network Professional
A+ Hardware/Software, Linux+, Network+, i-Net+ Certified Professional
Certified Internet Webmaster Associate



-----Original Message-----
From: Gotner, James 
Sent: Thursday, April 10, 2003 2:16 PM
To: 'nagios-users at lists.sourceforge.net'
Subject: [Nagios-users] Timeperiod already been defined


OK, solve one problem, get into another... While running nagios -v, I now
receive an error stating that timeperiod 'worktime' has already been
defined. And - Error: Could not register timeperiod 'worktime'.
Well, I have all timeperiods defined in one file, timeperiods.cfg, and
worktime and one other, 24x7, are the only ones defined.  Apparently, nagios
accepts the 24x7 definition, as I get an error on the second one.  I
searched through the archives, and noticed someone with a similar problem.
They recompiled the program and their problem was solved... Well, that didnt
work for me... Any suggestions on what else to check?  Thanks.

Nagios v1.0
RedHat Linux 7.3

timeperiods.cfg
-----------------

# Time Period Definition
# Description: A time period is a list of times during various days that are
# considered to be "valid" times for notificatins and service checks.  It
# consists of one or more time periods for each day of the week that
"rotate"
# once the week has come to an end.  Exceptions to the weekly time range are
# not supported.

#define timeperiod{
#	timeperiod_name		timeperiod_name		; Short name used to
ID the timeperiod
#	alias				alias				;
Description for timeperiod
#	sunday			00:00-24:00			; Time
periods to be used, seperate with commas for multiple timeperiods
#	monday			00:00-24:00			; If you do
not want any notification on a certian day, then do not
#	tuesday			00:00-24:00			; include
the day in the definition or comment out.
#	wednesday			00:00-24:00
#	thursday			00:00-24:00
#	friday			00:00-24:00
#	saturday			00:00-24:00
#}

define timeperiod{
	timeperiod_name		24x7
	alias				All the time
	sunday			00:00-24:00
	monday			00:00-24:00
	tuesday			00:00-24:00
	wednesday			00:00-24:00
	thursday 			00:00-24:00
	friday			00:00-24:00
	saturday			00:00-24:00
}

define timeperiod{
	timeperiod_name		worktime
	alias				The Nine to Fiver
#	sunday						; Not used
	monday			09:00-17:00
	tuesday			09:00-17:00
	wednesday			09:00-17:00
	thursday			09:00-17:00
	friday			09:00-17:00
#	saturday						; Not used
}

---End timeperiods.cfg--------


James Gotner

Security Certified Network Professional
A+ Hardware/Software, Linux+, Network+, i-Net+ Certified Professional
Certified Internet Webmaster Associate





-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list