Trying to keep the Users folder from getting cluttered.
-
How can I keep the Users folder tidy in Leopard? I work at a university where we're moving towards having users login with their Active Directory accounts on Leopard workstations for the first time. We're hoping to keep the Users directory on these workstations clean. We've setup a nice default profile that works wonderfully, now we just want to be able to delete the user's folder after they logout. (we can't do a nightly cron job, folks have 24 hr access to these machines) We were looking at Bombich's http://www.bombich.com/software/lwm.html, but it doesn't seem to work in Leopard. From what I can tell, Bombich has ceased development on it. I have a tidy little perl script that will delete all but the admin user's home folders. I figure I just need some way of triggering it with the appropriate permissions I'm not great with Apple stuff, so I may just be approaching this in the completely wrong way - I'm certainly open to any and all suggestions.
-
Answer:
Here's a http://discussions.apple.com/thread.jspa?messageID=6891519 about setting up a system-wide logout hook. In a nutshell: sudo /usr/bin/defaults write com.apple.loginwindow LogoutHook /path/to/script
soplerfo at Ask.Metafilter.Com Visit the source
Other answers
No Apple-specific advice, but what about a minor tweak to your perl script to delete profile folders older than 24 hours? That could run as a nightly (daily, whateverly) cron job without affecting the currently logged-in user.
pocams
http://www.red-sweater.com/blog/245/taming-launchd and https://sourceforge.net/projects/lingon/ might be what you're looking for.
infinitewindow
I think xil might have it! I'd played with com.apple.loginwindow but I think I had something backwards - I'll report back after more testing tomorrow. Thanks!
soplerfo
Thanks xil - works perfect!
soplerfo
Related Q & A:
- How do I get rid of the BETA message I keep getting?Best solution by support.mozilla.org
- Why do I keep getting booted out of Yahoo IM?Best solution by Yahoo! Answers
- Why do I keep getting disconnected from YM?Best solution by answers.yahoo.com
- Why do I keep getting back email that I sent failure?Best solution by Yahoo! Answers
- Why do I keep getting an error message when I use Yahoo?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.