[plug] user permission setting

Matt Kemner zombie at penguincare.com.au
Thu Mar 11 18:39:02 WST 2004


On Thu, 11 Mar 2004, quoth Sol Hanna:

> I think it's something to do with umask, but I'm not sure how to set it.
> When I create/save a file as a regular user, the default permission on
> that file is 644. I want to open this up (specifically on the NFS
> directory) to 664 so that different users in the "users" group can both
> read and write in each of the directories mounted ont he NFS directory
> (yes, this is desirable in this instance). But how?

I had to do the same this week when I installed a Mandrake based linux
terminal server.  The umask setting is inherited, so the best place to
change it is just before the x session runs, that way any applications you
spawn will get the new umask.  I set it in /etc/X11/xdm/Xsession just
before the "exec /etc/X11/Xsession $*"
ie the script now says:

#!/bin/bash -login

umask 002
exec /etc/X11/Xsession $*

# Xsession ends here

You want umask 002, which gives directory perms of 775 and file perms of
664.

I also changed the UMASK_USER setting under the DrakConf security
settings, which in turn changes the /etc/sysconfig/msec file, which gets
inherited by the /etc/profile.d/msec.(c)sh scripts, which are
sourced by /etc/profile and /etc/csh.cshrc.[1]

 - Matt

[1] which of course is far too complex for my liking, being a CLI
    weenie :) - give me a simple config file any day.




More information about the plug mailing list