Page 1 of 1
Not able to acknowledge a service through Nagios Web portal
Posted: Fri Feb 08, 2013 7:50 pm
by Shivaramakrishnan
I am getting this error on a particular host.
"It appears as though you do not have permission to view information for this service
If you believe this is an error, check the HTTP server authentication requirements for accessing this CGI and check the authorization options in your CGI configuration file."
The strange thing is I am able to acknowledge all the other services on this host.
CGI file
authorized_for_system_information=nagiosadmin,svaidyanathan
authorized_for_configuration_information=nagiosadmin,svaidyanathan
authorized_for_system_commands=nagiosadmin,svaidyanathan
authorized_for_all_service_commands=nagiosadmin,svaidyanathan
authorized_for_all_host_commands=nagiosadmin,svaidyanathan
On Nagios:
define service {
use generic-service
hosts dbs01-ple03.atl2
service_description Adaptec Raid Check
check_command check_nrpe_1arg!check_adaptech
}
On client :
command[check_adaptech]= sudo /usr/lib/nagios/plugins/check_adaptech
I am able to login and acknowledge all the other services as svaidyanathan and see all the hosts on the nagios server except this service on this host
Please let me know what I need to fix this?
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 1:25 pm
by lmiltchev
I don't see the "svaidyanathan" user set as a monitoring contact in the Adaptec Raid Check service definition:
Code: Select all
contacts nagiosadmin,svaidyanathan
Is "svaidyanathan" able to see all hosts/services? Can you show the following two lines in the cfg.cfg?
Code: Select all
authorized_for_all_hosts=
authorized_for_all_services=
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 2:16 pm
by Shivaramakrishnan
Below the required information,Also I am able to acknowledge other service checks on the same host except this service.
define contactgroup {
contactgroup_name admins
alias Nagios Administrators
members bcolbert, svaidyanathan
}
--------------------------
define host {
name generic-host
use host-pnp
notifications_enabled 1 ; Host notifications are enabled
event_handler_enabled 1 ; Host event handler is enabled
flap_detection_enabled 1 ; Flap detection is enabled
failure_prediction_enabled 1 ; Failure prediction is enabled
process_perf_data 1 ; Process performance data
retain_status_information 1 ; Retain status information across program restarts
retain_nonstatus_information 1 ; Retain non-status information across program restarts
check_period 24x7
check_interval 1
retry_interval 1
check_command check-host-alive
max_check_attempts 10
notification_interval 5
notification_period 24x7
notification_options d,u,r,f
contact_groups admins
register 0
}
----------------------------------------------------------------------
CGI
authorized_for_system_information=nagiosadmin,bcolbert,svaidyanathan
authorized_for_configuration_information=nagiosadmin,bcolbert,svaidyanathan
authorized_for_system_commands=nagiosadmin,bcolbert,svaidyanathan
authorized_for_all_services=*
authorized_for_all_hosts=*
authorized_for_all_service_commands=nagiosadmin,bcolbert,svaidyanathan
authorized_for_all_host_commands=nagiosadmin,bcolbert,svaidyanathan
#authorized_for_read_only=user1,user2
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 2:26 pm
by abrist
Try changing:
Code: Select all
authorized_for_all_services=*
authorized_for_all_hosts=*
To:
Code: Select all
authorized_for_all_services=nagiosadmin,svaidyanathan
authorized_for_all_hosts=nagiosadmin,svaidyanathan
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 2:40 pm
by Shivaramakrishnan
Still the same thing.
"It appears as though you do not have permission to view information for this service...
If you believe this is an error, check the HTTP server authentication requirements for accessing this CGI
and check the authorization options in your CGI configuration file."
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 3:14 pm
by abrist
First, did you restart nagios and httpd after the changes?
Second, have you added the user to the htpasswd file?
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 3:29 pm
by Shivaramakrishnan
Yes,I did.Restarted both nagios and apache.Also if I am able to see other services on the same host and able to acknowledge them (meaning svaidyanathan is added to htpasswd)
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 3:48 pm
by abrist
What is the current service check definition for the raid check? Did you add some contacts to the definition as per lmiltchev's suggestion?
Re: Not able to acknowledge a service through Nagios Web por
Posted: Mon Feb 11, 2013 9:00 pm
by Shivaramakrishnan
Yes I did as mentioned by him,Still "No Luck"..
Any other idea/suggestion?
Re: Not able to acknowledge a service through Nagios Web por
Posted: Tue Feb 12, 2013 10:55 am
by abrist
Could you post the current service check definition and large tail of /usr/local/nagios/var/nagios.log in a code wrap here?