Perl module for parsing Nagios configs?

Pascal Wessel pascal.wessel at media-online.ch
Mon Oct 21 17:36:06 CEST 2002


Doug,

Yes you are right to point that nagat is not that perfect. 
I made some tests when I started my beta run with nagios 1.0b6 (in fact
I'm a nagios primer :-) and I stopped using nagat for several reasons:

1) some bugs
2) all the comments I had to a cfg file are removed, not fair for my
collegues.
3) lots of parameters showed up and my goals was just having nagios
running. All these parms confused me. 
I switched back to vi 
What I'm doing to edit my config files is:
($NAGIOS_ROOT=/usr/local/nagios)
did a cp -pr $NAGIOSROOT/etc $NAGIOSROOT/stage && cd
$NAGIOSROOT/stage... 
and vi a lot. 
Then played with $NAGIOSROOT/bin/nagios -v $NAGIOSROOT/stage/nagios.cfg

$NAGIOSROOT/stage/nagios.cfg modified to fit my stage directory
structure, like the following:
log_file=/usr/local/nagios/var/nagios.log
cfg_file=/usr/local/nagios/stage/checkcommands.cfg
cfg_file=/usr/local/nagios/stage/misccommands.cfg
cfg_file=/usr/local/nagios/stage/contactgroups.cfg
cfg_file=/usr/local/nagios/stage/contacts.cfg
cfg_file=/usr/local/nagios/stage/dependencies.cfg
cfg_file=/usr/local/nagios/stage/escalations.cfg
cfg_file=/usr/local/nagios/stage/hostgroups.cfg
cfg_file=/usr/local/nagios/stage/hosts.cfg
cfg_file=/usr/local/nagios/stage/services.cfg
cfg_file=/usr/local/nagios/stage/timeperiods.cfg
resource_file=/usr/local/nagios/stage/resource.cfg

If I don't have error during the validation step of my stage tree, I
just copy the modified files to the real etc directory. I think I'll
script this once a day (once I understand nagios - lol)

Thus I think I'll test nagat once a day. When I'll feel more confident
with nagios, I'll for sure dig into nagat. At first I'd better look at
escalations and dependencies. 

... So much to do, so little time ...

Have a nice day,
Pascal


-----Original Message-----
From: doug.moore at ibill.com [mailto:doug.moore at ibill.com] 
Sent: lundi, 21. octobre 2002 17:04
To: pascal.wessel at media-online.ch; nagios-users at lists.sourceforge.net
Subject: RE: [Nagios-users] Perl module for parsing Nagios configs?

Pascal
what success have you had with Nagat? I had to give up on it. it wasn't
stable enough for me to deploy into a production environment. There are
over
26 bugs listed in its bug-track I think. 

Some of the bugs are show stoppers. But if you know PHP, which I don't,
it
might be just the solution. It is a fantastic 1st attempt to "php"
nagios
config files.


-----Original Message-----
From: Pascal Wessel [mailto:pascal.wessel at media-online.ch]
Sent: Monday, October 21, 2002 10:48 AM
To: nagios-users at lists.sourceforge.net
Subject: RE: [Nagios-users] Perl module for parsing Nagios configs?


Hi list,

No sure it's what you need, but do you know nagat ?
http://sourceforge.net/projects/nagat

It's PHP, but it could help.

Warm regards,
Pascal

-----Original Message-----
From: nagios-users-admin at lists.sourceforge.net
[mailto:nagios-users-admin at lists.sourceforge.net] On Behalf Of Chet
Luther
Sent: lundi, 21. octobre 2002 16:27
To: nagios-users at lists.sourceforge.net
Subject: [Nagios-users] Perl module for parsing Nagios configs?

Group,
    Before I go to the trouble of writing a Perl config file parser for
Nagios, I thought I'd check to see if anyone else already has one they'd
be
willing to send my way.  Something that can take multiple files and
parse
then into a single data structure would be preferrable.  If I don't get
anything, I'll be sure to share my module with anyone who wants it.

Thanks,

Chet Luther
chet at rcn.com



-------------------------------------------------------
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



-------------------------------------------------------
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


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.
**********************************************************************



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf




More information about the Users mailing list