Well, we did a lot of server hacking before with some MySQL, eAccelerator, and httpd.
There’s a lot of major blogs out there I have checked using Web Page Compression Tool that are not using compression. (For one, I checked John Chow’s blog)
Try to check one of your posts instead of checking your main URL as the tool is funky with root domains. (e.g. Check http://zedomax.com/blog/2008/02/23/never-give-up-especially-your-blog-dude/ instead of http://zedomax.com)
Here’s a screenshow of compression test I did for one of John Chow’s posts:
As you can see, John Chow’s blog does not use compression. As a result, he’s losing out on almost 5 times of bandwidth!!!
With level 9 compression, his site could be loaded on your web browser at 21K instead of the whopping 100K.
Now the compression might not be for all of you with slow CPUs. Our Zedomax.com runs on Quad-CPU server which has a lot of CPU processing power.
Here’s a screenshow of my server under normal load:
As you can see, most of the time, my CPU is idling at 80.8%! That means my CPU is pretty much sitting on its ass instead of doing work for me.
Now, if you have a similar situation, compression will help your site load faster and also bring your load down so you can handle more traffic.
Here’s how to enable compression if you have a dedicated or access to root on your server:
(Most servers have zlib installed, if you don’t have zlib installed, you will have to install that first, you can check it by making a test file and putting <?php phpinfo() ?> and search for zlib)
Add the following lines to your /etc/php.ini:
zlib.output_compression = on
zlib.output_compression_level = 5
and then restart apache! (of course):
httpd -k restart
Now, go check one of your posts on the Compression Test Tool here.
As you can see above, I just compressed one of my blog posts by a whopping 76.1%!
If you are using Super Cache plugin for WordPress, make sure to go to options and do this too:
Now, your server will run faster since there’s less data being transmitted to your visitors, meaning you save bandwith, time, and most importantly, the ability to handle more traffic.
At 70% increase in bandwidth, that could translate to that many more visitors too as bandwidth is directly proportional to amount of time a visitor stays on your site. (Yes, I did take Calculus in college, I failed miserably before passing.) The less time a visitor takes to load a page on your blog or your site, the more time and bandwidth you have for other visitors.)
I was searching through the web for many ways to use compression for server optimization but I couldn’t find any so I sort put everything together here.
Hopefully, it helps you.
And one more thing, you can also check out this great tutorial on your httpd.conf setup.
You can always check out HOWTO decrease load on your server by 5 times also.