It seems the document for vhost config left out the line for ModPagespeedGeneratedFilePrefix because when I copied them I got this error:
mod_pagespeed is enabled. The following directives must not be NULL\nModPagespeedFileCachePath=/var/cache/mod_pagespeed/\nModPagespeedGeneratedFilePrefix=
Configuration Failed
This is what I used and seems to work
ModPagespeed on
# The ModPagespeedFileCachePath directory must exist and be writable by the
# apache user (as specified by the User directive).
ModPagespeedFileCachePath "/var/mod_pagespeed/cache/"
ModPagespeedGeneratedFilePrefix "/var/mod_pagespeed/files"
# Other ModPagespeed directives here ...
# This page lets you view statistics about the mod_pagespeed module.
Order allow,deny
# You may insert other "Allow from" lines to add hosts you want to allow to
# look at generated statistics. Another possibility is to comment out the
# "Order" and "Allow" options from the config file, to allow any client that
# can reach your server to examine statistics. This might be appropriate in
# an experimental setup or if the Apache server is protected by a reverse
# proxy that will filter URLs in some fashion.
Allow from all
SetHandler mod_pagespeed_statistics
1 Response to ModPagespeed Virtual host configuration