Well I could use mod_rewrite, the only reason I chose this method was because it was easier to set up. Is there any difference between the two?
Shawn -----Original Message----- From: Ian Joyce [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 08, 2005 8:31 PM To: shawn Subject: Re: PerlTransHandler question On Tue, 8 Mar 2005 17:19:29 -0700, shawn <[EMAIL PROTECTED]> wrote: > Hi, I have been having a few problems with dial-up users downloading large > pictures from my mod_perl enabled webserver, also I see spikes in cpu usage > which also suggests to me that the server is doing a lot of work serving up > the large images. What I would like to do is set up an image cluster, to > allow mod_perl to basically only execute code within the page, release and > let another server worry about serving up images. What I have done so far is > altered my PerlTransHandler with the code below > > > > if($host ne 'dev.webserver.com' && $host ne > 'images.webserver.com'){ > > if($new_uri =~ m/\.(jpg|gif|css|pdf|bmp|js|eps)$/i){ > > #now redirect the image > > > $r->header_out(Location=>"http://images.webserver.com$new_uri"); > > return REDIRECT; > > } > > } > > > > > > So far this working on my development environment, but what I am really > wondering about is if this will actually take the load off mod_perl? (it's a > little hard for me to tell without significant traffic) Will the mod_perl > server execute the page and release the connection and not care how long the > images server is taking? If anyone has a better solution or an idea I would > love to hear it. Why not use mod_rewrite? --Ian > > > > Thanks > > Shawn