1

I am using mpm_itk_module that allows me to specify a different user for each apache vhost:

<VirtualHost *:80>
    ServerName www.example1.com
<IfModule mpm_itk_module>
    AssignUserId example1 example1
</IfModule>

<VirtualHost *:80>
    ServerName www.example2.com
<IfModule mpm_itk_module>
    AssignUserId example2 example2
</IfModule>

But when enabling mod_pagespeed, the cache folders (inside /var/cache/mod_pagespeed) are created as apache:apache and then it cannot write to them.

It is like the initial pagespeed folders are created as default apache user, but later it tries to write as the individual vhost user(s) and fails.

If I make /var/cache/mod_pagespeed writable as 0777 then the folders are created by first user that writes cache (example1 or example2), but then the second user cannot write there anymore.

Is it uncommon to use different groups for these users ? Should I run all the virtual hosts as same group like www ? example1:www and example2:www ?

I can specify different cache folder for each vhost, but they still share some common folder(s) like shm_metadata_cache and permissions and ownership is still a problem.

Or maybe mod_pagespeed has an option for users setup ?!

Romeo Ninov
  • 6,538
  • 1
  • 22
  • 31
adrianTNT
  • 3,671
  • 5
  • 29
  • 35

0 Answers0