Apache prompts you dont have permission to access /test.php on this server solution

  
                  

First, let's talk about the configuration:
System configuration: Operating system: Red Hat Linux 6.2 Web server: Apache 3.1.1+jakarta-tomcat 3.1.1 Database server: oracle 8i

​​Apache server is currently the most widely used Web servers, according to statistics, more than half of the world's servers use Apache servers. For its benefits, you can go to http://www.apache.org/. Today our server has a bit of a problem: any access will return a 403 error:
Forbidden You don't have permission to access on this server.

No, it turned out to be fine. Except for the problem of excluding the permissions of the directory, I almost rummaged through all the files in the system, especially all the configuration files under /etc/httpd/conf, because I already Access.conf, srm.conf file is added to the httpd.conf file, and at the end of the httpd.conf file is added: Include /etc/httpd/conf/tomcat.conf, in order to connect tomcat and apache. After some thoughts, I thought the problem must be in the httpd.conf file, so I checked the httpd.conf file again and finally found out that there is such a paragraph:
<Files ~> AllowOverride AuthConfig FileInfo Indexs Limit Options Order allow , deny Deny from all----------------- Note: This is it!!---> Remove or comment out this line! ! ! </Files>

A burst of ecstasy, haha, think of a word that Zhao Benshan said "small sample, I took off the vest, I also recognize you", so I changed it to: Allow from all, restart the server, hey, still No? The head started to grow up, thinking: I am here today. It has been turned over more than n times. The httpd.conf file is almost backed up and still can't find the problem. Also blame, suddenly remembered, www.apache.org is not a problem database, almost all the questions can be found above, so go to http://bugs.apache.org/, find the keyword forbidden, Sure enough, let me find out, it turned out that one of our colleagues wanted to be a virtual host, using the Linux configuration tool linuxconf, this tool will cause the httpd.conf file to be modified because of the version of the problem, in fact, I just need to put the above If you get rid of it, you can do everything. Final summary experience: When you encounter something, you must first think of the answer on the website where the software is located, so as not to waste time. The purpose of writing this article: I use the negative textbook, do not always think that I can solve the problem, and not consult the professional website. Many websites already have very perfect faq, which can basically meet the needs of everyone. For example, pb should go to www.sybase.com and go to http://developer.java.sun.com. Turn, vc to the bad kids home yo. In fact, some masters are not how smart they are, but they know how to find what they want from useful places. I also found hope as he did, and it didn't work. I was happy later, but then I couldn't play anymore. Is that not working for me? who can help me? I find! I find! If you can't, save yourself. Solve 403 Forbidden error under Apache Text: Install
Apache on the company computer today, version 2.2.8, just finished testing; configure php.in file under php again to play development< Br>Current error: HTTP error 403 - No access, ie 403 Forbidden: You don't have permission to access /on this server. Permission is not enough? Immediately open the apache configuration file httpd.conf and check it line by line. In about half the time, there is this code:
<Directory /> Options FollowSymLinks AllowOverride None Order deny,allow Deny from all </Directory>

Found it. Since php is configured, "Deny from all" here has rejected all connections. Change the line to “allow from all”, the modified code is as follows, the problem is solved.
<Directory /> Options FollowSymLinks AllowOverride None Order deny,allow allow from all </Directory>

Open http://localhost again in the browser and display it works! Summary: If you have such a 403 forbidden access, you may wish to note that the Apache's httpd.conf configuration file has "Deny from all"; this line of code, to see if it was quietly modified by the system.

Copyright © Windows knowledge All Rights Reserved