D&C GLug - Home Page

[ Date Index ] [ Thread Index ] [ <= Previous by date / thread ] [ Next by date / thread => ]

RE: [LUG] umask for a user with no shell account

 

Kelly,
 
The umask is associated with a process, not a username.  The fact that most people only set the umask in .profile or some such start-up file only illustrates another feature of umask - that it is inherited from the parent process.  Any program can change it's process's umask, and languages like C and Perl have a umask function. 
If you are running the backup jobs from a script, then set umask to all zeros, otherwise make sure the program does it.
However setting the umask does not set permissions, it only removes (masks) them.  Most utilities do not set the permissions to 0777, except compilers.  Instead they use 0666, so setting the umask to zero will still not give you 0777, you will have to chmod for that.
 
Clive 


From: Kelly Jones
Sent: Wed 02/11/2005 17:31
To: DC LUG
Subject: [LUG] umask for a user with no shell account

I have a user defined that i use for backing up customers machines to my samba server,  i have restricted shell login for this user and want files created by this user to have 777 permissions.  How can i do this if the user has no home directory or shell login?


--
Kelly Jones <kellyjones@xxxxxxxxxxxxxxxxx>

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________