I set up Apache having a CacheRoot directory for every of my domain names / virtual hosts:
<VirtualHost> ServerName domain1.tld ... CacheRoot /var/www/vhosts/domain1.tld/httpdocs/cache ... </VirtualHost> <VirtualHost> ServerName domain2.tld ... CacheRoot /var/www/vhosts/domain2.tld/httpdocs/cache ... </VirtualHost>
I've this ready to go for a long time and thus fare it's working pretty much with the exception that I must empty the cache by hand once in awhile because htcacheclean does't understand about the different sites.
Now I must setup htcacheclean to keep an eye on the cache sites but as fare when i comprehend the manual, I'm able to only place it to 1 cache directory. I must make a move such as this but that does not work:
<VirtualHost> ServerName domain1.tld ... CacheRoot /var/www/vhosts/domain1.tld/httpdocs/cache htcacheclean -n -t -p/var/www/vhosts/domain1.tld/httpdocs/cache -l1024M ... </VirtualHost>
Could it be even to have multiple cache directorys or must i use only one cache directory its the domain names?