Some time a go I set up a LAMP server for students to do mysql/php work on.
I used mod_userdir so that individual students have their own workspace and enabled samba to give them smb access.
All if fine except that during the course some of the students have made web-pages that allow files to be uploaded.
Because Apache runs under the user wwwrun when files are uploaded using the students custom php scripts the files are then owned by wwwrun. Since the user does not own the file they uploaded they cannot delete it using samba.
Whats the best way around this problem other than running apache as root (not going to happen), or have cron periodically chown the files ?