log out script

Gavin McCullagh gmccullagh at gmail.com
Wed Jun 25 14:36:30 BST 2008


Hi,

On Wed, 25 Jun 2008, Barb A. Tabor wrote:

> Hello. I am wanting my thin clients to wipe out any changes users have 
> made upon log out and default settings load when next user logs in.
> I think I need a script to do this, but am not sure what that script 
> should say. 
> If anyone could help me out on this I would appreciate it.

You're authenticating against active directory (according to your next
email), right?  If the users all have their own accounts, they'll get their
own settings and the next user to login will get the settings for their
account.  However:

If you have everyone using a single dummy account and you _really_ don't
want anything saved, you could just delete and re-create the home directory
with something like this run as the user in question:

	find ~username | xargs rm -f
	cp -r /etc/skel/* ~username

though you'd probably want to think it out a little more than this to make
sure nothing goes wrong.

That solution is a bit extreme in that it's going to remove all files in
that account -- documents, bookmarks, everything.  You could pick a set of
files and directories beginning with "." and delete those

	cd ~username/
	rm -r .gconf/ .gconfd/ .gnome/ .gnome2/ .gnome2_private/ .mozilla/

This would delete a specific bunch of that user's settings.

Gavin




More information about the edubuntu-users mailing list