Fwd: Multiple host in hosts.cfg

Thomas Sluyter nagios at kilala.nl
Wed Nov 22 10:07:50 CET 2006


On 22 Nov, 2006, at 4:44, spdesai at gnvfc.net wrote:

> GOOD EXPLANATION FROM YR SIDE.
>
> SO IF I WANT TO ADD MORE HOSTS THEN I NEED TO ADD IN ONLY HOSTS.CFG  
> FILE NOT
> IN ANY OTHER FILE(LIKE SERVICE/HOSTGROUPS ETC)AS OTHER FILES ARE  
> LOOK HOSTS
> DETAILS FROM HOSTGROUP NAME.
>
> RIGHT ?
>
> PL. CONFIRM ..

Holy shit! Stop shouting! /me covers his ears

Ow...

Aniway, yes. If you want to add hosts then you will only need to add  
them in hosts.cfg. You just have to make sure you subscribe them to  
the host groups they need.

You will not need to edit any of the services*.cfg files unless you  
want to add additional service checks. You will not need to edit any  
of the host group definitions, unless you want to create a new host  
group.

So to expand on my example from yesterday:
* Want to add an SSH check to all systems? Define a new SSH service  
and set its "hostgroup_name" to HG_all.
* Want to start monitoring web servers? Create a host group HG-www,  
define a HTTPD service and set its "hostgroup_name" to HG_www. Then  
subscribe all hosts running as web servers to HG_www.
* Want to add new systems to the HTTPD check? Just add their host  
definitions and subscribe them to HG_www.

Good luck!


Thomas

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
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