After installing and configuring cacherouter+xcache, I started getting these groups of errors in dblog:
fopen() [function.fopen]: SAFE MODE Restriction in effect. The script whose uid is X is not allowed to access /tmp owned by uid 0 in file [snip]/sites/all/modules/cacherouter/Cache.php on line 110
fopen(/tmp/prefix-cache_menu_lock) [function.fopen]: failed to open stream: Success in file [snip]/sites/all/modules/cacherouter/Cache.php on line 110.
flock() expects parameter 1 to be resource, boolean given in file [snip]/sites/all/modules/cacherouter/Cache.php on line 111.
unlink() [function.unlink]: SAFE MODE Restriction in effect. The script whose uid is X is not allowed to access /tmp owned by uid 0 in file [snip]/sites/all/modules/cacherouter/Cache.php on line 124.
Attached is a patch to README.txt which explains how to fix the problem I had.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | readme_txt-2.patch | 2.58 KB | tetramentis |
| readme_txt.patch | 2.57 KB | tetramentis |
Comments
Comment #1
tetramentis commentedComment #2
tetramentis commentedI got a slightly better patch (attached) thanks to #945650: suggestions for settings.php.
Comment #3
andypostgetcwd() and $_SERVER['SERVER_NAME'] could be wrong in case multisite.
So I propose to use same string as for 'path'. Users can replace this paths with values by their own
Powered by Dreditor.
Comment #4
tetramentis commentedThen maybe my original string would be better than just copying 'path', as it contains a hint to make path absolute:
'lock_dir' => '/absolute/path/to/your/sites/default/files/filecache',I have tested that in a multisite install and it did work for me, but my multisite might not be what others are using: I'm using DocumentRoot directives for several sites to point at a single Drupal directory.
This is a minor convenience point so generally I don't mind using a simpler string with no code/variables in it.