error in nagios 4.3.1 when searching!

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
majed
Posts: 98
Joined: Mon Mar 17, 2014 5:29 am

error in nagios 4.3.1 when searching!

Post by majed »

Peace, i can see the hosts when i click hosts or services but when i try to search i get:

Code: Select all

It appears as though you do not have permission to view information for any of the hosts you requested...

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.
here is my apache nagios configuration:
/etc/apache2/modules.d/99_nagios4.conf

Code: Select all

<IfDefine NAGIOS>

  ScriptAlias /nagios/cgi-bin/ /usr/lib64/nagios/cgi-bin/
  <Directory "/usr/lib64/nagios/cgi-bin/">
    AllowOverride AuthConfig
	#AllowOverride None
    Options ExecCGI
	<RequireAll>
	Require all granted
	AuthName "Nagios Access"
   AuthType Basic
   AuthUserFile /etc/nagios/htpasswd.users
   Require valid-user
   </RequireAll>
  </Directory>
  


  Alias /nagios /usr/share/nagios/htdocs/
  <Directory "/usr/share/nagios/htdocs/">
    AllowOverride AuthConfig
	#AllowOverride None
	<RequireAll>
	Require all granted
	AuthName "Nagios Access"
	AuthType Basic
	AuthUserFile /etc/nagios/htpasswd.users
	Require valid-user
	</RequireAll>
  </Directory>

</IfDefine>
/etc/nagios/cgi.cfg

Code: Select all

main_config_file=/etc/nagios/nagios.cfg
physical_html_path=/usr/share/nagios/htdocs/
url_html_path=/nagios
show_context_help=0
use_pending_states=1
use_authentication=1
use_ssl_authentication=0
authorized_for_system_information=nagiosadmin
authorized_for_configuration_information=nagiosadmin
authorized_for_system_commands=nagiosadmin
authorized_for_all_services=nagiosadmin
authorized_for_all_hosts=nagiosadmin
authorized_for_all_service_commands=nagiosadmin
authorized_for_all_host_commands=nagiosadmin
default_statusmap_layout=5
default_statuswrl_layout=4
ping_syntax=/bin/ping -n -U -c 5 $HOSTADDRESS$
refresh_rate=90
result_limit=0
escape_html_tags=1
action_url_target=_blank
notes_url_target=_blank
lock_author_names=1
navbar_search_for_addresses=1
navbar_search_for_aliases=1
any help?
Seek and you shall find, knock and it shall be opened, cry and you shall find comfort
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: error in nagios 4.3.1 when searching!

Post by scottwilkerson »

What user are you logged in as? (see upper left corner)
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
majed
Posts: 98
Joined: Mon Mar 17, 2014 5:29 am

Re: error in nagios 4.3.1 when searching!

Post by majed »

I thought that was too obvious, needless to mention that it is nagiosadmin.
Seek and you shall find, knock and it shall be opened, cry and you shall find comfort
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: error in nagios 4.3.1 when searching!

Post by scottwilkerson »

Can you search for a host you know exists, such as localhost?

The message you describe is displayed if your search has no results.
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
majed
Posts: 98
Joined: Mon Mar 17, 2014 5:29 am

Re: error in nagios 4.3.1 when searching!

Post by majed »

wow, it worked! but i thought it would find the host if i type just part of it! sounds like a bug.
Seek and you shall find, knock and it shall be opened, cry and you shall find comfort
Locked