Forum Moderators: phranque

Message Too Old, No Replies

user directory log files

         

hutchic

9:53 pm on Feb 21, 2006 (gmt 0)

10+ Year Member



A large multi-user system with mod_userdir.c enabled how can I export the log files specific to the user's directory to their public_html directory.

any help appreciated

jdMorgan

10:46 pm on Feb 21, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



mod_log_config [httpd.apache.org] is your friend.

See also Log Files [httpd.apache.org] - Custom logging

Jim

lammert

11:16 pm on Feb 21, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



A large multi-user system

If large means "a lot of users", please be aware of the problem that every opened logfile takes one file descriptor. Apache keeps the files open for subsequent writes. There is only a limited number of file descriptors available and too much log files could therefore cause your server to crash or stop responding.

If real time access to the logfiles is not an issue, splitting the central files once a day with a script or small program and distribute them to the user directories might be an alternative.

jdMorgan

11:27 pm on Feb 21, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Good point: That issue is addressed in the cited documentation.

Also, be sure to password-protect those log files -- to prevent log spamming and keep bandwidth down. Most hosts also schedule a monthly or weekly cron job to gzip the old log files to reduce disk storage requirements.

Jim