Forum Moderators: phranque
I'm having some problems with RedirectMatch and I'm not sure how to even troubleshoot at this point.
I run a virtual host on my "development environment" locally on Apache 2.0.44 (Win32) where everything is working fine.
I tried recreating the virtual host on Apache 1.3.6 (AIX) today and am having some problems related to RedirectMatch.
I'm attempting to redirect root reqeusts and basically the RedirectMatch seems to be 100% ignored.
Nothing (out of the usual) is showing up in the access or error logs.
hitting [x.y.z...] shows a "GET / HTTP/1.1" and the following is returned to the browser, "Forbidden
You don't have permission to access / on this server."
Error log shows, "Directory index forbidden by rule."
I've tried different combinations of full URLs, quoting and not quoting, etc. to no avail.
Here's the VH definition from httpd.conf:
<VirtualHost *>
# redirect root requests to web-object index.htm
RedirectMatch ^/$ /cgi-bin/dev/index.htm
DocumentRoot /usr/local/apache/htdocs/x.y.z
ServerName x.y.z
ErrorLog logs/x.y.z-error_log
CustomLog logs/x.y.z-access_log combined
DirectoryIndex index.htm index.html
ScriptAlias /cgi-bin/ "/usr/local/apache/htdocs/x.y.z/cgi-bin/"
<Directory "/usr/local/apache/htdocs/x.y.z">
Options FollowSymlinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
Any ideas?
Thanks
RedirectMatch ^/?$ http://hostname/cgi-bin/dev/index.htm
Still totally ignored. :( Tried this example based on your suggestion:
RedirectMatch ^/?$ [microsoft.com...]
[x.y.z...] returns:
"GET / HTTP/1.1" 403 284 "-"