Nagios Core 4.3.4 - NCPA passive Checks - SE Linux

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
charangandra
Posts: 25
Joined: Tue Feb 13, 2018 6:23 am

Nagios Core 4.3.4 - NCPA passive Checks - SE Linux

Post by charangandra »

Hi,

I've installed Nagios core on Centos 7.3 and using NCPA for passive checks. NCPA is able to send the check results back to nrdp as long as I disabled SE Linux. But Once I enable the SE Linux it is unable to send the details and giving the below error.

SE Linux Enabled: Error as below

2018-08-31 14:58:14,946 108325 INFO Message from NRDP server: BAD CHECK RESULTS DIR
2018-08-31 14:58:14,946 108325 INFO Meta output from NRDP server: Nonexistent

SE Linux Disabled: usual log below

2018-08-31 14:50:07,567 108325 INFO Running check: disk/logical/| --warning 80 --critical 90 --units Gi
2018-08-31 14:50:07,622 108325 INFO Running check: cpu/percent --warning 80 --critical 90 --aggregate avg
2018-08-31 14:50:08,184 108325 INFO Running check: memory/swap --warning 80 --critical 90 --units Gi
2018-08-31 14:50:08,246 108325 INFO Running check: memory/virtual --warning 80 --critical 90 --units Gi
2018-08-31 14:50:08,309 108325 INFO Running check: processes --warning 300 --critical 400
2018-08-31 14:50:08,544 108325 INFO Message from NRDP server: OK
2018-08-31 14:50:08,545 108325 INFO Meta output from NRDP server: 5 checks processed.

Do we need to definitely disabled the SE Linux? It is project requirement to have SE Linux enabled, how can I resolve the issue?

Thanks,
Charan
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Nagios Core 4.3.4 - NCPA passive Checks - SE Linux

Post by scottwilkerson »

charangandra wrote: Do we need to definitely disabled the SE Linux? It is project requirement to have SE Linux enabled, how can I resolve the issue?
Yes, you either need to disable selinux, or write a policy that will allow apache to have access to the check results directory
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
charangandra
Posts: 25
Joined: Tue Feb 13, 2018 6:23 am

Re: Nagios Core 4.3.4 - NCPA passive Checks - SE Linux

Post by charangandra »

Thanks for your quick reply. Is there any Link to follow to write a policy that will allow apache to have access to the check results directory?

Thanks,
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Nagios Core 4.3.4 - NCPA passive Checks - SE Linux

Post by scottwilkerson »

We don't have any publications on the topic, but a quick Google search found the following
http://iris77.net/?p=585
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked