[quote=vipsoft @ Apr 6 2010, 10:34 PM]Ok. Don’t believe the user comments on the PHP manual page. tempnam() does respect the umask.
Try editing your apache startup script to use a less restrictive umask (e.g., 0022).[/quote]
I’ve tried everything. I added “umask 002” to httpd.conf (which failed, but works on some distros apparently), to /etc/syscontrol/httpd, which did nothing, and to the initscript /etc/init.d/httpd.
Then I obviously restarted the httpd service.
The files still get created with chmod 500, (and owned by apache:apache as before.)
Do you have any other ideas, or any reasons for why the above did nothing?
Thanks for your help so far, it’s much appreciated.
Edit: For what it’s worth, I’m running Red Hat:
cat /proc/version
Linux version 2.6.18-164.11.1.el5PAE (mockbuild@hs20-bc1-2.build.redhat.com) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-46)) #1 SMP Wed Jan 6 13:43:57 EST 2010
Thanks for your reply. The patches give me the somewhat more useful error message:
chmod() [function.chmod]: SAFE MODE Restriction in effect. The script whose uid is 10003 is not allowed to access /var/www/piwik/tmp/templates_c/wrta6QQDZ owned by uid 48
in '/var/www/piwik/libs/Smarty/internals/core.write_file.php' at the line 28
However, my .htaccess in the root of the domain and the piwik directory both say:
php_value safe_mode "0"
php_flag safe_mode off
and phpinfo() gives me that safe mode globally is off, but local value is on. What gives?
The server we run uses plesk. Plesk had a check box for safe mode on. How irritating. That fixed it.
Thanks so much for your help, I have piwik running now.
The only thing now is that even though it’s running and it’s collecting info in the database (I’m looking at the DB itself), the actual interface shows no visits or anything. Any ideas?
Make sure you’re viewing ‘today’ in the calendar, and that your php timezone is configured correctly – you would have seen an Installation warning for the latter.
The timezone mismatch causes reports to lag. This is in the FAQ. This has to correspond to the timezone of the MySQL server.
We’re making timezone configureable in the next release (0.6). In the meantime, you can set it manually in your piwik/index.php. See http://php.net/timezones for a list of supported timezone strings. (Varies depending on your PHP version, timezonedb package, and whether or not your PHP build was patched to use tzdata.)
[quote=vipsoft @ Apr 8 2010, 07:11 PM]The timezone mismatch causes reports to lag. This is in the FAQ. This has to correspond to the timezone of the MySQL server.
We’re making timezone configureable in the next release (0.6). In the meantime, you can set it manually in your piwik/index.php. See php.net/timezones for a list of supported timezone strings. (Varies depending on your PHP version, timezonedb package, and whether or not your PHP build was patched to use tzdata.)