mkdir -p /root/mod_pagespeed cd /root/mod_pagespeed wget -O mod-pagespeed-stable_current_x86_64.rpm https://dl-ssl.google.com/dl/linux/direct/mod-pagespeed-stable_current_x86_64.rpm yum install cpio -y rpm2cpio mod-pagespeed-stable_current_x86_64.rpm| cpio -idmv
mv -f ./etc/httpd/conf.d/pagespeed.conf /etc/httpd/conf/extra/pagespeed.conf mv -f ./etc/httpd/conf.d/pagespeed_libraries.conf /etc/httpd/conf/extra/pagespeed_libraries.conf mv -f ./usr/bin/pagespeed_js_minify /usr/bin/pagespeed_js_minify mv -f ./usr/lib64/httpd/modules/mod_pagespeed_ap24.so /usr/lib/apache/mod_pagespeed_ap24.so mkdir -p /var/cache/mod_pagespeed mkdir -p /var/log/pagespeed
perl -pi -e 's|/usr/lib64/httpd/modules/|/usr/lib/apache/|g' /etc/httpd/conf/extra/pagespeed.conf เพิ่มไฟล์ใน /etc/httpd/conf/extra/httpd-includes.conf
Include /etc/httpd/conf/extra/pagespeed.conf Include /etc/httpd/conf/extra/pagespeed_libraries.conf
service httpd restart ลองเช็คผ่าน https://ismodpagespeedworking.com/ ถ้าขึ้น mod_pagespeed Running ก็เป็นอันเรียบร้อยครับ