Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

read all the posts regarding this issue - and none of them seed to help my instance...

I just moved all my dev stuff form a vista machine (where it worked fine) to a Windows 7 machine - Apache 2.2... and I'm using the same conf files... but now for some reason my .htaccess file is causing a "You don't have permission to access / on this server." error.

(I am positive it's the .htaccess file - because if i remove or rename the file from the directory - the site comes up just fine...)

now - the .htaccess file is used to facilitate short URLs and I cannot simply remove it - it's not my site to make such design decisions - I'm simply managing it...

SO FAR - I have made sure I have all my conf entries as:

Order allow,deny
Allow from all

and thru the windows file/directory UI - I've set the folder permissions for the httpd root AND my wwwroot (located in my users folder) to have the local user have FULL CONTROL...

but I'm still getting the error... frustrating.

Error log reads:

Sat Jan 14 21:17:03 2012] [error] [client 127.0.0.1] Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies that RewriteRule directive is forbidden: C:/Users/me/wwwroot/{path to site}/

interestingly - Options FollowSymLinks is in the conf file - exactly as it was before...

anyone feel like walking me thru a permissions thing on win 7?????

thanks in advance/

share|improve this question

migrated from stackoverflow.com Jan 15 '12 at 7:28

This question came from our site for professional and enthusiast programmers.

    
We're just guessing unless you provide your configuration. –  Shane Madden Jan 15 '12 at 7:38

2 Answers 2

Using a text editor, open the httpd.conf file. In XAMPP, this file is found in the \apache\conf directory, Locate the following line of code:

#LoadModule rewrite_module modules/mod_rewrite.so

Remove the # from the line as seen below to enable the module:

LoadModule rewrite_module modules/mod_rewrite.so

Save the httpd.conf file and Restart your server Restart your Apache Server

share|improve this answer

I believe that if you have Allow,Deny and their are no Deny statements then there is an implicit Deny from all. You should swap the order. As specified by the documentation, this would be better anyways as your wish to allow from all.

By using Deny,Allow you are saying:

  • If your request matches a deny rule and NO allow rules, then deny
  • If you request matches a deny BUT matches an allow, then allow
  • If your request matches no denies but matches an allow, then allow
  • If your request matches nothing, deny

I believe this will give you the behavior you desire while being entirely explicit.

share|improve this answer
    
THX John, I'll try that - but there are many places the default conf file has allow,deny... most actually, the only place it has deny,allow is where it says it's "starting" in a most locked down manner... can you tell me where you got you information - is there 'good' documentation on the conf files somewhere??? I've only read the comments in the file itself. And it doesn't answer why it worked on vista but not 7... but like i said - I'll try it and let you know. –  jpmyob Jan 15 '12 at 4:15
    
--- NO GO - changed ALL references of "Order allow,deny" to "Order deny,allow" - no change. but thanks –  jpmyob Jan 15 '12 at 4:21
    
Order allow,deny will deny as the default action if there's no matching Allow statement (as well as the deny action winning when there's a matching statement of both Allow and Deny) - in this case, the Allow from all should allow all requests. –  Shane Madden Jan 15 '12 at 7:37

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.