I've been getting some permissions errors when running:

$ drush cron
user@example.clustered.net: ~/public_html> drush cron
Cron run successfully.
warning:                                                             [warning]
fopen(/tmp/filecache/api/cache/8/87cd8b8808600624d8c590cfc2e6e94b--variables):
failed to open stream: Permission denied in
/home/api/domains/example.com/public_html/sites/all/modules/cacherouter/engines/file.php
on line 150.
warning:                                                             [warning]
fopen(/tmp/filecache/api/cache/8/87cd8b8808600624d8c590cfc2e6e94b--variables):
failed to open stream: Permission denied in
/home/api/domains/example.com/public_html/sites/all/modules/cacherouter/engines/file.php
on line 150.
warning:                                                             [warning]
fopen(/tmp/filecache/api/cache/8/87cd8b8808600624d8c590cfc2e6e94b--variables):
failed to open stream: Permission denied in
/home/api/domains/example.com/public_html/sites/all/modules/cacherouter/engines/file.php
on line 150.
warning:                                                             [warning]
fopen(/tmp/filecache/api/cache/8/87cd8b8808600624d8c590cfc2e6e94b--variables):
failed to open stream: Permission denied in
/home/api/domains/example.com/public_html/sites/all/modules/cacherouter/engines/file.php
on line 150.
warning:                                                             [warning]
fopen(/tmp/filecache/api/cache/8/87cd8b8808600624d8c590cfc2e6e94b--variables):
failed to open stream: Permission denied in
/home/api/domains/example.com/public_html/sites/all/modules/cacherouter/engines/file.php
on line 150.

I first added the current user to the apache group and tried again but this didn't work as drush seems to be running cron as an Anonymous user.

The only "fix" I could find, and this might not be the best approach, was to chmod all created dirs and files to 777.

Patch attached for testing.

CommentFileSizeAuthor
cacherouter_perms-.patch1.07 KBpsynaptic