From a947f3829cc8af8bb2e05fc237be499ba1135acf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C5=82awomir=20Paszkiewicz?= Date: Fri, 2 Oct 2015 13:41:43 +0200 Subject: [PATCH] - added configuration for SELinux --- doc/Installation/Installation-(RHEL-CentOS).md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/doc/Installation/Installation-(RHEL-CentOS).md b/doc/Installation/Installation-(RHEL-CentOS).md index 208494e1b..70e85799f 100644 --- a/doc/Installation/Installation-(RHEL-CentOS).md +++ b/doc/Installation/Installation-(RHEL-CentOS).md @@ -215,6 +215,20 @@ First, create and chown the `rrd` directory and create the `logs` directory > If you're planing on running rrdcached, make sure that the path is also chmod'ed to 775 and chown'ed to librenms:librenms. +**SELinux** +> if you're using SELinux you need to allow nginx to write into logs directory. +> semanage tool is a part of policycoreutils-python, so if don't have it, you can install it + +```bash + yum install policycoreutils-python +``` + +```bash + semanage fcontext -a -t httpd_sys_content_t '/opt/librenms/logs(/.*)?' + semanage fcontext -a -t httpd_sys_rw_content_t '/opt/librenms/logs(/.*)?' + restorecon -RFvv /opt/librenms/logs/ +``` + Start the web-server: # For HTTPd (Apache):