* Doug MacEachern
|
| On 15 Sep 2000, Bjørn Ola Smievoll wrote:
| 
| > I need to retrieve the value of the ErrorLog directive (i.e. the path
| > & filename of the error_log), but I can't find a way to do it with
| > mod_perl.  (The C api equivalent is the error_fname field in the
| > server_rec struct).
| 
| this patch should work.  can you tell me why you need it so i can decide
| if this should be added to the distribution?

I want to return the last 5 lines or so of the error_log each time
there's a 500 error.  The faculty and students ordinarily don't have
access to the error log, so it will be helpful for them to see the
last lines from the log file to help them fix problems with their
documents (mostly wrong file perms and stuff like that).

I could hardcode the value, but since we distribute our server package
to well over 50 servers, some running multiple virtualhosts, I doubt
that would work very well.

(From a security standpoint this might not be the best idea, so I'll
probably limit it to lines that start with [ (so not to return the
occasional perl code dump) and to our local domain as it's only useful
if you're able to fix the problem as well (useful in an
non-evil-minded context that is)).


Thanks,

(bo)

Reply via email to