1
  1. I have my website/blog in /home/tarach/www/tarach.net
    1. All files and directories starting from /home/tarach/www are to user: tarach, group: www-data ( apache httpd group )
    2. I've setup virtualhost tarach.net to point to dir from 1)
    3. Apache is requesting access to .htaccess file in /home/tarach
    4. After creating file /home/tarach/.htaccess and setting group of that file and my home directory to www-data it started working. Earlier I had message : [Thu Jul 09 04:13:28 2015] [crit] [client 79.185.210.150] (13)Permission denied: /home/tarach/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable, referer: http://tarach.net/

I don't want my Apache webserver to be accessing my home directory. What should I do to eliminate it.

vhost configuration enter image description here

I've pasted it as an image because looks like editor can't handle Apache configuration at all and gives a lot of display errors. http://pastebin.com/vpAFQ6PP

1

Apache will search recursively up the tree for .htaccess files, on every access, which is why .htaccess files (i.e. anything besides AllowOverride none) is a bad idea if you want high performance. If you can, put the directives in the config itself and turn off AllowOverride.

Perhaps Adding a <Directory> segment with AllowOverride none for the parent directory may help.

  • Adding AllowOverride none for <Directory /> triggers you don't have permission to access / on this server. and in error.log (13)Permission denied: access to / denied. I'm using apache2 aptitude version 2.2.22-13+deb7u4 – sebastian_t Jul 10 '15 at 13:11

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.