|
Home > Archive > Apache Server configuration support > August 2005 > rewrite module won't work at all
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
rewrite module won't work at all
|
|
|
| Hello,
I administer several Apache installations, some of them with rewrite
configured and running, but I have one install, where rewrite won't
work. I can't figure out why.
Here is the configuration, a little bit scrambled in pathes:
RewriteEngine On
RewriteLog /var/log/httpd/prod-rewrite_log
RewriteLogLevel 9
RewriteRule ^/bilder/ /einpixel.gif
RewriteRule ^/v-archiv/ /xxxxxxx/yyyyyyy/zzz/noaccess.html
RewriteCond %{HTTP_HOST} !^www.x.y.z
RewriteCond %{HTTP_HOST} !^$
RewriteCond %{SERVER_PORT} !^80$
RewriteRule ^/(.*) http://www.x.y.z:%{SERVER_PORT}/$1 [L,R]
RewriteCond %{HTTP_HOST} !^www.x.y.z
RewriteCond %{HTTP_HOST} !^$
RewriteRule ^/(.*) http://www.x.y.z/$1 [L,R]
RewriteCond %{REQUEST_URI} ^/bilder/(.*)
RewriteRule ^/(.*) http://www.x.y.z/einpixel.gif [L,R]
myserv:/usr/local/apache/bin# ./httpd -v
Server version: Apache/1.3.33 (Unix)
Server built: Aug 24 2005 15:15:52
myserv:/usr/local/apache/bin# ./httpd -l
Compiled-in modules:
http_core.c
mod_env.c
mod_log_config.c
mod_mime.c
mod_negotiation.c
mod_status.c
mod_include.c
mod_autoindex.c
mod_dir.c
mod_cgi.c
mod_asis.c
mod_imap.c
mod_actions.c
mod_userdir.c
mod_alias.c
mod_rewrite.c
mod_access.c
mod_auth.c
mod_setenvif.c
suexec: disabled; invalid wrapper /usr/local/apache/bin/suexec
myserv:/usr/local/apache/bin#
lsof shows that the logfile /var/log/httpd/prod-rewrite_log is being
accessed, but nothing is written to it, nor does Rewrite appear to do
anything at all.
How can I get the module to operation?
Regards, Thomas
| |
| Mr.D0Little 2005-08-24, 8:54 pm |
| Am 24 Aug 2005 07:42:34 -0700 schrieb tm:
> Hello,
>
> I administer several Apache installations, some of them with rewrite
> configured and running, but I have one install, where rewrite won't
> work. I can't figure out why.
>
> Here is the configuration, a little bit scrambled in pathes:
>
> RewriteEngine On
> RewriteLog /var/log/httpd/prod-rewrite_log
> RewriteLogLevel 9
>
> RewriteRule ^/bilder/ /einpixel.gif
>
> RewriteRule ^/v-archiv/ /xxxxxxx/yyyyyyy/zzz/noaccess.html
>
> RewriteCond %{HTTP_HOST} !^www.x.y.z
> RewriteCond %{HTTP_HOST} !^$
> RewriteCond %{SERVER_PORT} !^80$
> RewriteRule ^/(.*) http://www.x.y.z:%{SERVER_PORT}/$1 [L,R]
> RewriteCond %{HTTP_HOST} !^www.x.y.z
> RewriteCond %{HTTP_HOST} !^$
> RewriteRule ^/(.*) http://www.x.y.z/$1 [L,R]
> RewriteCond %{REQUEST_URI} ^/bilder/(.*)
> RewriteRule ^/(.*) http://www.x.y.z/einpixel.gif [L,R]
>
>
> myserv:/usr/local/apache/bin# ./httpd -v
> Server version: Apache/1.3.33 (Unix)
> Server built: Aug 24 2005 15:15:52
> myserv:/usr/local/apache/bin# ./httpd -l
> Compiled-in modules:
> http_core.c
> mod_env.c
> mod_log_config.c
> mod_mime.c
> mod_negotiation.c
> mod_status.c
> mod_include.c
> mod_autoindex.c
> mod_dir.c
> mod_cgi.c
> mod_asis.c
> mod_imap.c
> mod_actions.c
> mod_userdir.c
> mod_alias.c
> mod_rewrite.c
> mod_access.c
> mod_auth.c
> mod_setenvif.c
> suexec: disabled; invalid wrapper /usr/local/apache/bin/suexec
> myserv:/usr/local/apache/bin#
>
> lsof shows that the logfile /var/log/httpd/prod-rewrite_log is being
> accessed, but nothing is written to it, nor does Rewrite appear to do
> anything at all.
>
> How can I get the module to operation?
>
> Regards, Thomas
Hallo Thomas,
ein gutes Forum für solche Probleme ist http://www.modrewrite.de/
Dr. D0Little
| |
|
| Hello Dr. DOlittle,
referring to http://www.modrewrite.de/ helped: they told me that
rewrite directives have to be in the corresponding virtualhost context
if virtualhost is used.
Got rewrite back to operation again.
Thanks for the tip.
Regards, Thomas
|
|
|
|
|