Nagios 請檢查HTTP伺服器關於該CGI的存取權限設定

來源:互聯網
上載者:User

標籤:

無權查看任何主機的資訊。 請檢查HTTP伺服器關於該CGI的存取權限設定。

搜尋了一下方法

確保 htpasswd.user的所有組為nagios

解決辦法:

vi /usr/local/nagios/etc/cgi.cfg

將use_authentication的值改為0.

use_authentication=0

然後重啟nagios服務

service nagios restart

還有另外一種可能:

設定檔中的hostname稱service_description使用了中文導致的。

記住:hostname和service_description 都最好不要使用中文哦

註:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

use_authentication=0        

按照上面修改將預設的1 改為0,但是改這個之後在服務作業的介面,在想調整服務檢測的時候就會出現這樣的一個提示:
Sorry Dave, I can‘t let you do that...
其實並不需要降低cgi 的安全性,你只需要把你的nagios 管理員賬戶添加到cgi.cfg 檔案就可
以了,比如我的nagios 系統管理使用者是linux(這個命令產生的賬戶 htpasswd -c /usr/local/nagios/etc/htpasswd.users linux  

  只有添加第一個賬戶要用-c 參數)

就需要在cgi.cfg 檔案中修改如下幾項:
將每項的nagiosadmin 更改為linux 即可,多使用者用”,”分割。
authorized_for_system_information=linux
authorized_for_configuration_information=linux
authorized_for_system_commands=linux
authorized_for_all_services=linux
authorized_for_all_hosts=linux
authorized_for_all_service_commands=linux
authorized_for_all_host_commands=linux

Nagios 請檢查HTTP伺服器關於該CGI的存取權限設定

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.