Skip to main content

how to enable httpd to access to homedir

here are the notes how to enable accessing homedir for httpd

enable access to home user directory
# /etc/httpd/conf/httpd.conf
locate UserDir section

<IfModule mod_userdir.c>
#
#
# UserDir disabled                       (comments this line)
#
#

to allow httpd accessing homedir set selinux by typing this command on terminal
# setsebool -P httpd_enable_homedirs 1
# chcon -R -t httpd_sys_content_t ~username/public_html

example.
#  chcon -R -t httpd_sys_content_t ~belogix/public_html


 notes:
~userid directory must have permission 711
~userid/public_html/ directory must have permission 755

check your setting by open your web browser pointed to http://ipaddrwebserver/~user/

Comments

Popular posts from this blog

about gigabyte NIC onboard not detected on enterprise linux distribution

on several gigabyte motherboard, onboard network interface card  will not be detected on enterprise linux distribution (e.g. scientific linux, oracle linux server, etc). alternatively you must supply add-on card. or if you insist to use the onboard card, you must install the unofficial nic driver. this is tutorial how to install driver for onboard network interface card GIGABYTE first of all prepare your system. make sure it has package group "Development Tools" installed. if it has not, install it # yum groupinstall “Development Tools” download the source code : https://www.dropbox.com/s/na91bu4az4p9827/AR81Family-linux-v1.0.1.14.tar.gz extract the source code : # tar zxvf AR81Family-linux1.0.1.14.tar.gz the extraction process will make the new directory "AR81Family*", change to the directory # cd AR81Family* compile the source by type on terminal : # make then, # make install wait until the compiling process finish. next make the new scrip...

about getsebool and setsebool

The setsebool is used to set SELinux boolean value i.e. various configurations can be enabled or disabled using this tool. In other words, the setsebool command switches on and off the protection of SELinux. Type getsebool -a to see all such options which can be enabled or disabled at run time: e.g. # getsebool -a The following should give you a complete listing of all the vsftpd switches: e.g.  # getsebool -a | grep ftp  For example, if httpd_disable_trans set to 1, it will disable SELinux protection for  Apache web server. To disable it, enter:  # setsebool -P httpd_can_network_connect=1 To enable it, enter:    # setsebool -P httpd_can_network_connect=0

All certification