Hello!
I am new to NagiosXI. I just purchased the software. Everything seems to be working well except that hostgroup names (not the servers in the hostgroups) show up for all users.
Example: I have a user named Joe. Joe is setup to only view hosts within a certain hostgroup. When I login as Joe the only hosts I can see are in the hostgroup he has access to. However, he can also see the names of all other hostgroups as well. Not the contents of the hostgroups but just the names. This is a problem as I am using hostgroups to catagorize the companies we do business with. It measn that a user can see all of the companies we have hosting setup for. Again, he can not see the hosts or anything else within the hostgroup, just the hostgroup names. This happens in all hostgroup views.
I am running Nagios XI 2011R1.6. I am installed on a CentOS 5.6 server and it was a clean install before I put Nagios on the server. My logfiles do not provide any data. I am very experienced with Nagios core and have gone through the config with a fine tooth comb and everything is setup properly. Any advice?
Thanks
Phil
Hostgroup names still visible to all users
Re: Hostgroup names still visible to all users
Moving this to the customer forums Phil.
Nicholas Scott
Former Nagios employee
Former Nagios employee
Re: Hostgroup names still visible to all users
Did you setup through the config files or you tried to use the Nagios XI web interface?
I tested it on XI by creating a user (joe):
Admin->Manage Users->Add New User (Security settings = User, all boxes cleared)
I created a contact group (linux-testers) and added joe as a member:
Core Config Manager->Contact Groups->Add New
Then I reconfigured the hosts that I wanted to be visible to joe:
Home->Host Detail->Ubuntu->Configure->Re-configure this host->
Groups->Linux Servers (linux-servers)
Notifications->Other individual contacts->joe & Specific contact groups->linux-testers
I logged off, cleared my browser's cache and logged on as joe
I was able to see only the host group "linux-servers".
You can probably review our documentation on this topic here:
http://assets.nagios.com/downloads/nagi ... enancy.pdf
Let us know if you were able to fix it.
I tested it on XI by creating a user (joe):
Admin->Manage Users->Add New User (Security settings = User, all boxes cleared)
I created a contact group (linux-testers) and added joe as a member:
Core Config Manager->Contact Groups->Add New
Then I reconfigured the hosts that I wanted to be visible to joe:
Home->Host Detail->Ubuntu->Configure->Re-configure this host->
Groups->Linux Servers (linux-servers)
Notifications->Other individual contacts->joe & Specific contact groups->linux-testers
I logged off, cleared my browser's cache and logged on as joe
I was able to see only the host group "linux-servers".
You can probably review our documentation on this topic here:
http://assets.nagios.com/downloads/nagi ... enancy.pdf
Let us know if you were able to fix it.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Hostgroup names still visible to all users
I have an account now and I can post... 
I did not export from a Nagios core installation. I set everything up through NagiosXI. I have reviewed the document you highlighted above before and we are setup exactly the same way. Let me show you some code...
Contagroups.cfg
define contactgroup {
contactgroup_name SOA
alias SOA
contactgroup_members HOSTINGOPS
}
Contacts.cfg
define contact {
contact_name blah
alias blah blah
contactgroups SOA
host_notification_period blah_notification_times
service_notification_period blah_notification_times
host_notification_options d,u,r,f,s
service_notification_options w,u,c,r,f,s
email [email protected]
host_notifications_enabled 1
service_notifications_enabled 1
use xi_contact_generic
}
Hostgroups.cfg
define hostgroup {
hostgroup_name SOA
alias SOA
}
hosts config (this is one of them, they are all the same:
define host {
host_name soaweb5.web2.xxxxx.net
use SOA-hosts,WEB2DOMAIN-hosts
address 192.168.26.141
hostgroups SOA
max_check_attempts 5
check_interval 5
retry_interval 1
contact_groups HOSTINGOPS,SOA
notification_interval 60
icon_image win_server.png
statusmap_image win_server.png
_xiwizard _customwindowsserver
register 1
}
I have other hostgroups and hosts setup. When I login with a user in the SOA contactgroup I can see all of the SOA hosts and services but no other hosts and services. The problem is I CAN SEE all of the other hostgroup names.
Any suggestions?
Thanks
Phil
I did not export from a Nagios core installation. I set everything up through NagiosXI. I have reviewed the document you highlighted above before and we are setup exactly the same way. Let me show you some code...
Contagroups.cfg
define contactgroup {
contactgroup_name SOA
alias SOA
contactgroup_members HOSTINGOPS
}
Contacts.cfg
define contact {
contact_name blah
alias blah blah
contactgroups SOA
host_notification_period blah_notification_times
service_notification_period blah_notification_times
host_notification_options d,u,r,f,s
service_notification_options w,u,c,r,f,s
email [email protected]
host_notifications_enabled 1
service_notifications_enabled 1
use xi_contact_generic
}
Hostgroups.cfg
define hostgroup {
hostgroup_name SOA
alias SOA
}
hosts config (this is one of them, they are all the same:
define host {
host_name soaweb5.web2.xxxxx.net
use SOA-hosts,WEB2DOMAIN-hosts
address 192.168.26.141
hostgroups SOA
max_check_attempts 5
check_interval 5
retry_interval 1
contact_groups HOSTINGOPS,SOA
notification_interval 60
icon_image win_server.png
statusmap_image win_server.png
_xiwizard _customwindowsserver
register 1
}
I have other hostgroups and hosts setup. When I login with a user in the SOA contactgroup I can see all of the SOA hosts and services but no other hosts and services. The problem is I CAN SEE all of the other hostgroup names.
Any suggestions?
Thanks
Phil
Re: Hostgroup names still visible to all users
Phil,
I am not sure what the problem is, but I see some differences in our config files. Did you try creating a user and setting it up the way I described it?
In your "Contactgroups.cfg" you use "contactgroup_members", which is not required. You have to use "members" which is required. Also, I don't see your member "bla" defined in your "Contactgroups.cfg". For example, my "contactgroups.cfg" looks like this:
Also, in my hosts config file, I have both, "contacts" and "contact_groups" defined. I have only "contact_groups".
My hosts config file looks like this:
I tested it for one user only. I haven't tested it for a group of users. As soon as I do this, I will give you some feedback. With this setup though, my user "joe" can only see the Windows XP host and it's services. The rest of the hosts & services are not visible for joe.
I am not sure what the problem is, but I see some differences in our config files. Did you try creating a user and setting it up the way I described it?
In your "Contactgroups.cfg" you use "contactgroup_members", which is not required. You have to use "members" which is required. Also, I don't see your member "bla" defined in your "Contactgroups.cfg". For example, my "contactgroups.cfg" looks like this:
Code: Select all
define contactgroup {
contactgroup_name windows-testers
alias windows-testers
members joe
}My hosts config file looks like this:
Code: Select all
define host {
host_name Windows XP
use xiwizard_windowsdesktop_host
alias Windows XP
address XXX.XXX.X.XX
hostgroups windows-servers
max_check_attempts 5
check_interval 5
retry_interval 1
contacts joe,nagiosadmin
contact_groups windows-testers
notification_interval 60
first_notification_delay 0
notification_options d,u,r,f,s
notifications_enabled 1
icon_image windowsxp.png
statusmap_image windowsxp.png
_xiwizard windowsdesktop
register 1
}
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Hostgroup names still visible to all users
Hello!
Sorry it took so long to reply. I found the problem. If you create hostgroups that do not have members (hosts) in them already then they WILL SHOW UP for all users until you place a host in them that has the right permissions. Problem solved. The bottom line is that I should not create a hostgroup until I actually need it and have a host to put into it.
Thanks
Phil
Sorry it took so long to reply. I found the problem. If you create hostgroups that do not have members (hosts) in them already then they WILL SHOW UP for all users until you place a host in them that has the right permissions. Problem solved. The bottom line is that I should not create a hostgroup until I actually need it and have a host to put into it.
Thanks
Phil
Re: Hostgroup names still visible to all users
Thanks for your feedback, Phil!
Be sure to check out our Knowledgebase for helpful articles and solutions!