How do you define a sub-group within a Main group ?
e.g Main group "PRODUCTION" & sub group "Prod App Servers"
Sub Groups within a group
-
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: Sub Groups within a group
Is this speaking in regards to Hostgroup rules? As in a hostgroup within a hostgroup? Or a service group within a host group?
Re: Sub Groups within a group
i'd appreciate it in any form "either hostgroup of a host group or service group within a host group".
i basicly want to break down projects under each environment " for Dev servers { break it into sub groups such as Web Servers, App servers, DB Servers etc"
i basicly want to break down projects under each environment " for Dev servers { break it into sub groups such as Web Servers, App servers, DB Servers etc"
Re: Sub Groups within a group
i'd love to break down projects or classify servers within Host Groups.
for every environment "DEV | QA | PROD", i wanna have an extendable groups/service group "Web servers, DB Servers, LDAP Servers etc"
for every environment "DEV | QA | PROD", i wanna have an extendable groups/service group "Web servers, DB Servers, LDAP Servers etc"
Re: Sub Groups within a group
The trick here is to use the optional directive hostgroup_members. See my mock-up below:
Code: Select all
define hostgroup{
hostgroup_name production ; The name of the hostgroup
alias Servers in Production ; Long name of the group
hostgroup_members: prod_app_servers,prod_db_servers ;This optional directive can be used to include hosts from other "sub" host groups in this host group. Specify a comma-delimited list of short names of other host groups whose members should be included in this group.
}
define hostgroup{
hostgroup_name prod_app_servers
alias Production app Servers
members server1,server2
}
define hostgroup{
hostgroup_name prod_db_servers
alias Production Database Servers
members server3,server4
}
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.