error in nagios 4.3.1 when searching!

This forum is intended for the discussion of Nagios Core development. Feature requests, patches, bug fixes, and all types of development-related discussions are welcome!

NOTE: The SourceForge.net nagios-devel mailing list has been deprecated in favor of this forum in order to expedite support and provide additional features not available on the old mailing list.

error in nagios 4.3.1 when searching!

Postby majed » Wed Jun 14, 2017 3:18 am

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
majed
 
Posts: 82
Joined: Mon Mar 17, 2014 5:29 am

Re: error in nagios 4.3.1 when searching!

Postby scottwilkerson » Wed Jun 14, 2017 10:31 am

What user are you logged in as? (see upper left corner)
User avatar
scottwilkerson
CTO
 
Posts: 7620
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises

Re: error in nagios 4.3.1 when searching!

Postby majed » Thu Jun 15, 2017 3:23 am

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
majed
 
Posts: 82
Joined: Mon Mar 17, 2014 5:29 am

Re: error in nagios 4.3.1 when searching!

Postby scottwilkerson » Thu Jun 15, 2017 12:42 pm

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

The message you describe is displayed if your search has no results.
User avatar
scottwilkerson
CTO
 
Posts: 7620
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises

Re: error in nagios 4.3.1 when searching!

Postby majed » Fri Jun 16, 2017 12:59 am

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
majed
 
Posts: 82
Joined: Mon Mar 17, 2014 5:29 am


Return to Nagios Core Development

Who is online

Users browsing this forum: No registered users and 2 guests