linux - Nagios - 错误 : Could not read object configuration data

标签 linux ubuntu nagios

我们在另外两台服务器上运行了 Nagios 3.2.0 的工作版本,但在这些新服务器上,我们使用 apt-get install 安装了它,但不断遇到以下问题。 权限和配置文件都是安装时的默认设置,将它与我们拥有的 Nagios 工作版本进行比较时,一切似乎都是正确的...

注意:Nagios 网站正在运行,但是当我单击左侧的任何选项时,我得到这个...

Error: Could not read object configuration data!  
Verify configuration options using the -v command-line option to check for errors. 
Check the Nagios log file for messages relating to startup or status data errors.

运行

sudo /usr/sbin/nagios3 -v /etc/nagios3/nagios.cfg

给予:

...
Total Warnings: 0
Total Errors:   0

Things look okay - No serious problems were detected during the pre-flight check

/var/log/nagios3/nagios.log 没有错误,只是一堆:

...
[1389054450] Auto-save of retention data completed successfully.
[1389058050] Auto-save of retention data completed successfully.

不是权限问题,要么尝试将所有内容更改为 nagios 用户和组,但没有成功:

drwxr-xr-x   4 root root    4096 2013-12-10 16:35 .
drwxr-xr-x 141 root root   12288 2014-01-06 16:27 ..
-rw-r--r--   1 root root    1905 2011-06-08 01:07 apache2.conf
-rw-r--r--   1 root root   12218 2011-06-08 01:08 cgi.cfg
-rw-r--r--   1 root root    2441 2011-06-08 01:08 commands.cfg
drwxr-xr-x   2 root root    4096 2013-12-10 16:35 conf.d
-rw-r--r--   1 root root      26 2013-12-10 16:35 htpasswd.users
-rw-r--r--   1 root root   43769 2011-06-08 01:08 nagios.cfg
-rw-r-----   1 root nagios  1293 2011-06-08 01:07 resource.cfg
drwxr-xr-x   2 root root    4096 2013-12-10 16:35 stylesheets

将其改回根目录。

停止 Nagios 并重新启动,但仍然没有。请帮忙!

最佳答案

这是一个权限问题,网络服务器用户应该能够访问nagios目录结构。 尝试以下。假设您的 Web 服务器未以 root 用户身份运行。

chgrp -R webserver_user /var/cache/nagiosx/  

并检查其他 nagios 目录的正确权限。

关于linux - Nagios - 错误 : Could not read object configuration data,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20962668/

相关文章:

linux - 如何为 kubectl 命令提供输入?

python - opencv安装ffmpeg报错

ubuntu - 使用 docker import 时出现 Permission denied 错误

mysql - nrpe: 命令 mysql_check 未定义

linux - 我需要在 Linux 中为 Nagios 用户创建一个帐户吗?

mysql - Nagios NDOUtils 安装 - 无法加载 mysql.so 错误

linux - 如何使用 scrapy 命令动态创建 Feed Export 的文件名

linux - 使用 Linux 命令行更新文件

ubuntu - 何时使用预置文件安装软件包,何时使用 Packer 预配软件包?

python - aspell-python 安装错误