httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ralf S. Engelschall" <>
Subject Re: Intra-server redirections in .htaccess
Date Thu, 19 Sep 1996 15:19:47 GMT
On 19 Sep 1996 15:18:44 +0200 in en.lists.apache-new-httpd you wrote:
> Ralf S. Engelschall wrote:

> > No, please don't start hacking an ErrorDocument as I did in the old days.
> > There is a much simpler solution: just use mod_rewrite and the following code
> > in the .htaccess file of /here:
> > 
> >     RewriteEngine on
> >     RewriteRule   ^flob\.html$  /there/lob.html
> > 
> > This will do a internal redirect. Try it out...

> Thanks for your advice - I have looked at your module and it looks very
> powerful.  I am rather wary of using it though, as it makes my apache
> binary nearly 20% bigger (184356->226840).  I haven't tested it out but
> I guess that one would have to be careful about using it in httpd.conf;
> as then each URL would be parsed which would make the server slower. 

> I'm not very experienced with servers though - do you think my
> reservations are important or not?

1. 40 KB is really unimportant, because modern Unix derivates
   will page in only code which is needed and (in this case) 40 KB on stuff
   which is additionally needed will not kill any machine. The days of our
   R-6502 64KB memory are gone, so really ignore a few more KB.

2. As said, the above rule should be put in your .htaccess
   file in /here and not in the httpd.conf file. So it will only slow down
   the server in context of /here and not for all requests which occur on the

3. Even if put into the servers httpd.conf, don't think about CPU-cycles in
   the days of Pentium and UltraSPARC machines. For instance, my is an old i486/DX66 with only 16 MB RAM and it runs
   fine under Apache 1.1.1 with approx. 30-40 RewriteRules in the httpd.conf
   and approx. 50 per-dir rules spread over the various .htaccess files. Ok,
   you are right: It will slow down! Yes. But not so dramatically that you
   should not use it ;-) I'm sure any CGI-Program will slow down the server
   at least twice as much.

4. Not using mod_rewrite for such a simple rule is ok. Yes, but
   be sure: When you once have discovered the power of mod_rewrite you will
   have a lot of more rules and never again thinking about this single

                                        Ralf S. Engelschall    

View raw message