Page 1 of 1

How to create and manage 300+ host definition cfg files?

Posted: Thu Nov 03, 2016 3:15 pm
by staceygong
Hi,

I would like to find out what is the general practise for host definition cfg file creation and management.

For example, I have about 300 Linux machines to manage. I need to define host.cfg for each machine, right? Then I will have 300 host.cfg files in /etc/nagios/conf.d.

Should I use puppet or database to generate and manage those host files?

Thanks,
Stacey

Re: How to create and manage 300+ host definition cfg files?

Posted: Thu Nov 03, 2016 3:36 pm
by dwhitfield
You can use host groups: https://assets.nagios.com/downloads/nag ... #hostgroup

Let us know if you have any questions about defining a hostgroup.

Re: How to create and manage 300+ host definition cfg files?

Posted: Fri Nov 04, 2016 8:24 am
by staceygong
Hi,

Thank you for the reply.

I have hostgroups.cfg defined, but that's not my question....

I am thinking of how to automate Nagios setup and monitoring with Puppet (or other configuration management system?).

On client side, I already have puppet to push NRPE addon to a machine, ensure nrpe.cfg is present and nrpe service is running.

On server side, I want to figure out how to automate the creation of the host.cfg for that machine when that machine has nagios nrpe addon....

I would like to know what is the best practise..what other system administrators are using....

Thanks,
Stacey

Re: How to create and manage 300+ host definition cfg files?

Posted: Fri Nov 04, 2016 9:17 am
by dwhitfield
There are definitely people using puppet. Here's a talk of one man giving his experience with Puppet and Nagios: https://www.youtube.com/watch?v=mgUqqs0jQ5k

We will leave this open for others to give their experience.