I’m looking for a way to display errors that apache generates under
/var/log/apache/error_log
for my colleagues who are working on the same project. The coding language is php.
First I tried to do a simple php readfile script, but since the file is only visible too the root user i was unsuccessful. I do not want to use things like cpanel or kloxo. can anyone help ?
To answer this properly we’d need to know a lot more about your setup.
Kind of implies that this some variant of Unix – but which one?
Does that mean you’re trying to make the file available via HTTP or do the relevant users have shell accounts?
If its just the permissions problem you need to solve and it’s one of the mainstream Linux variants, then it’s probably setup to use logrotate, and the config files for logrotate will be in /etc/logrotate.d/httpd or /etc/logrotate.d/apache so go read the man page for logrotate then change the file to something like…..
Here the ‘create 660 apache webdev’ makes the file owned by apache uid, webdev gid with permission -rw-rw—-
That will then take effect for all future log rollovers. You still need to set the permissions on the directory, e.g.
will give everyone read access to the directories
..and change permissions on the current files…