What is mod_pagespeed ?
mod_pagespeed is an open-source Apache module that automatically optimizes web pages and resources on them. It does this by rewriting the resources using filters that implement web performance best practices. Webmasters and web developers can use mod_pagespeed to improve the performance of their web pages when serving content with the Apache HTTP Server.
How to install mod_pagespeed?
First, check which Linux distribution you are using by this command:
cloudtech ~: uname -a
Linux cloudtech 126.96.36.199-x86_64-linode10 #1 SMP Tue Nov 10 16:29:17 UTC 2009 x86_64 x86_64 x86_64 GNU/Linux
Second, download the package at this link: mod_pagespeed latest version
Here I am using 64 bits CentOS Linux system, so i ‘ve downloaded mod_pagespeed 64-bit .rpm (CentOS/Fedora)
Third, install the package
rpm -i mod-pagespeed-*.rpm
or follow the instruction in official site. If you cannot install it, try this:
Install and import Google key into RPM, then you can install mod_pagespeed package using yum localinstall command:
rpm --import linux_signing_key.pub
yum localinstall mod-pagespeed-*.rpm
Check which files you just installed:
cloudtech ~: rpm -ql mod-pagespeed-beta
Last, restart Apache to load the new module
cloudtech ~: service httpd restart
How to upgrade mod_pagespeed?
Download the latest version 0.9.15.3-404 and use command yum localinstall mod-pagespeed-*.rpm to install
With this release, you can perform the upgrade to 0.9.15.3-404 with these commands:
sudo yum update
sudo /etc/init.d/httpd restart
On Debian or Ubuntu installation you can use:
sudo apt-get upgrade mod-pagespeed-beta
sudo /etc/init.d/apache2 restart
How to test mod_pagespeed?
Visit your site without mod_pagespeed
Visit your site with mod_pagespeed
Without mod_pagespeed, my site score is 73/100.
With mod_pagespeed, my site score is 81/100.
Monitor the results using Firebug + Pagespeed on your Firefox browser
You can also test your site at ModPageSpeed.com