If you are looking for an "old school" method of doing this, check out sed.
it is a very powerful tool to edit multiple files at once. Greg Pangrazio pangr...@gmail.com On Tue, May 4, 2010 at 8:14 AM, Assaf Flatto <nag...@flatto.net> wrote: > Leonardo Carneiro - Veltrac wrote: >> Hi list, >> >> I have the following situation: I'm monitoring a bunch of services on a >> bunch of servers (ok, nothing new so far). >> All machines run the same services, but not all services is being >> monitored by now (since they are custom services, i'm still writing >> plugins for all of them). New machines are being added every day, and >> also, i'm writing new plugins to check the services. >> >> When a new machine is added, is relatively easy: i copy the config file >> from another machine and change the name of the host and other unique >> attributes, but when a new service is added (a.k.a. i have finish >> another plugin), i need to edit all the dozens of config files for each >> server to add this new service. >> >> There is a smarter way to do this? >> Sorry for my poor english. Tks in advance. >> > Try using templates and hostgroups > Templates will allow you to use a central base definition to the service > or host . > http://nagios.sourceforge.net/docs/3_0/objectinheritance.html > > you can assign a service to a hostgroup and thus all host in the group > will have the service checked on them. > > http://nagios.sourceforge.net/docs/3_0/objectdefinitions.html#service > > -- > Never,Ever Cut A Deal With a Dragon > > > I am doing a Charity Bike ride On the 27 of June for the > Capital to Coast Charity. Please help by Donating > http://www.justgiving.com/Lovefilm-capital-to-coast > > > > ------------------------------------------------------------------------------ > _______________________________________________ > Nagios-users mailing list > Nagios-users@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 > ------------------------------------------------------------------------------ _______________________________________________ Nagios-users mailing list Nagios-users@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