in reply to Enhancing Speed

There is an instance of Perlmonks that runs under mod_perl 2 already, at http://qs1969.pair.com. It still has some quirks, because from time to time, DBI does not want to play anymore when it gets timeouts, but other than that it is fairly stable.

However, most of Perlmonks slowness is CPU and database bound. How do you think that gzipping content helps reduce the CPU time or database time used by Perlmonks?

Replies are listed 'Best First'.
Re^2: Enhancing Speed
by ahmad (Hermit) on Aug 18, 2010 at 16:01 UTC

    When you gzip the content, pages will take less time to download which means Apache will be able to serve more in less time.

    I kept hearing that gzipping content stress the CPU, but it's a myth based on my experience (I use mod_deflate with Apache 2.2).

    I don't have the statistics of your site, nor the server specifications ... but I've managed to lower the load of big websites (uses PHP not Perl) by gzipping content.

    It will take 10 minutes from your time ... And after 2 days if you think it did not make things better you can turn it off (unload the module), restart apache and that's it ... you're not modifying any part of your code.

    You don't have to recompile apache in order for it to work.y

      I don't think that will work. The machine already spends 100% of the CPU time creating the page. How will making it spend time on compressing the content make the site faster?

        If there are some slow clients who are requesting pages, Then Apache children will have to wait until each client download the page which will result in Apache running more children which in turns consumes more memory and CPU ... not to mention that you'll be processing extra pages with the old ones.

        I don't have the full picture, you are more capable to decide ... but as I said if it didn't work or if it turns out to be bad, then disabling it is very easy and won't take much time.