httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "System Support" <>
Subject [users@httpd] mod_rewrite prg option not working
Date Mon, 20 Oct 2008 15:08:13 GMT
I am having trouble getting the external program option of RewriteMap to 

RewriteMap convert rnd:/path/to/rnd/file
RewriteMap convert txt:/path/to/txt/file

both work as expected.

RewriteMap convert prg:/path/to/prg/file

does not work, and the program does not even seem to be called.

The location,owner, and permissions of the files are the same as other cgi 
scripts that do work.

The only error that shows up in any file is a 302 error for the unconverted url.

The expected configuration lines show in the Apache Server Information 

Current Configuration:
    In file: /etc/apache2/local.d/misc.conf
       6: RewriteLog "/var/run/rewrite.log"
       7: RewriteLock "/var/run/rewrite.lck"
       8: RewriteLogLevel 4
    In file: /etc/apache2/vhosts.d/test.conf
       5: <VirtualHost>
      13:   RewriteMap convert prg:/path/

The above line was the only one that I change for the different tests.

      46:   <Directory "/www/xxx">
      51:     RewriteEngine On
      52:     RewriteBase /
      53:     RewriteRule ^.*fix /${convert:$1} [L]
        :   </Directory>
        : </VirtualHost>

For the program I am using the example perl script given in the Apache 
mod_rewrite documention.  It works as expected when run from the 
command line.

The rewrite log file is created,  but stays empty even when the request is 
sucesfully rewritten (i.e. I get the expected image in the browser when using 
the txt: and rnd: options).

I am running a locally compiled Apache 2.2.9 under SuSE 11. 


support (at)

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message