User Tools

Site Tools


linux:useful_apache

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
linux:useful_apache [2020/05/25 08:25] – created bstaffordlinux:useful_apache [2022/11/23 12:49] (current) – external edit 127.0.0.1
Line 7: Line 7:
 END_OF_TEXT END_OF_TEXT
 service httpd restart</code> service httpd restart</code>
-=Disable HTTP Trace=+=====Disable HTTP Trace=====
 <code>cat <<'END_OF_TEXT' >> /etc/httpd/conf/httpd.conf <code>cat <<'END_OF_TEXT' >> /etc/httpd/conf/httpd.conf
 RewriteEngine On RewriteEngine On
Line 30: Line 30:
 } }
 END_OF_TEXT</code> END_OF_TEXT</code>
 +====Symbolic Links====
 +By default symbolic links may not work on Apache on CentOS. Assuming the symlink we are considering points to /example, then use the following command. This will add the appropriate SELinux context to the /exampledirectory and all its contents
 +<code>chcon -Rv --type=httpd_sys_content_t /example</code>
 +Replace <code>httpd_sys_content_t</code> with <code>public_content_t</code> if you want it to work with ftp as well.
 +====XAuth====
 +When using an xauth, you may get this error
 +<code>ERROR = /usr/bin/xauth:  timeout in locking authority file /home/username/.Xauthority</code>
 +The solution is to fix the SELinux permissions
 +<code>chcon unconfined_u:object_r:user_home_dir_t:s0 /home/username</code>
 +====Allow Perl to Connect To MySQL====
 +Run this command to allow Perl to connect to Database server while still having SELinux enabled.
 +<code>semanage boolean -m --on httpd_can_network_connect_db</code>
 +
 +
 +
  
linux/useful_apache.1590395146.txt.gz · Last modified: (external edit)