getting error can't open main configurations file
getting error can't open main configurations file
Hi I am getting this error. Can you please help me here.?
Error: Cannot open main configuration file '/etc/nagios/nagios.cfg' for reading!
Error: Cannot open main configuration file '/etc/nagios/nagios.cfg' for reading!
Re: getting error can't open main configurations file
I am using Nagios core 4.3.4 in ubuntu 16.04 LTS
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: getting error can't open main configurations file
does the file exist?
If so can you attach it?
Code: Select all
ls -al /etc/nagios/nagios.cfg
Re: getting error can't open main configurations file
rwxrwxr-x 3 nagios nagios 4096 May 16 19:34 .
drwxr-xr-x 8 root root 4096 May 10 17:51 ..
-rw-r----- 1 www-data nagios 12999 May 10 17:51 cgi.cfg
-rw-r--r-- 1 root root 50 May 10 17:54 htpasswd.users
-rw-r----- 1 nagios nagios 44816 May 10 17:51 nagios.cfg
drwxrwxr-x 2 nagios nagios 4096 May 16 15:07 objects
-rw-rw---- 1 nagios nagios 1312 May 10 17:51 resource.cfg
drwxr-xr-x 8 root root 4096 May 10 17:51 ..
-rw-r----- 1 www-data nagios 12999 May 10 17:51 cgi.cfg
-rw-r--r-- 1 root root 50 May 10 17:54 htpasswd.users
-rw-r----- 1 nagios nagios 44816 May 10 17:51 nagios.cfg
drwxrwxr-x 2 nagios nagios 4096 May 16 15:07 objects
-rw-rw---- 1 nagios nagios 1312 May 10 17:51 resource.cfg
Re: getting error can't open main configurations file
Sorry this is the correct one please ignore my previous post.
-rw-rw-r-- 1 nagios nagios 44818 May 16 19:21 /usr/local/nagios/etc/nagios.cfg
-rw-rw-r-- 1 nagios nagios 44818 May 16 19:21 /usr/local/nagios/etc/nagios.cfg
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: getting error can't open main configurations file
Ok. Where are you getting this error? What are you doing when that happens?Ravikimt wrote:Sorry this is the correct one please ignore my previous post.
-rw-rw-r-- 1 nagios nagios 44818 May 16 19:21 /usr/local/nagios/etc/nagios.cfg
Ravikimt wrote:Hi I am getting the error below. Can you please help me here.?
Error: Cannot open main configuration file '/etc/nagios/nagios.cfg' for reading!
Re: getting error can't open main configurations file
When I am doing Pre flight check for checking Nagios configuration then I am getting this error on my treminal
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: getting error can't open main configurations file
you should use
Code: Select all
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Re: getting error can't open main configurations file
I have resolved my problem so you can close this topic.
Thanks for the help.
Thanks for the help.
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: getting error can't open main configurations file
Great! Locking