Hi again,
Well, I don't know much about shell programming, but if the group ID of your
users is 502, then I guess you can change the lines in /etc/bashrc like
below. I just inserted a new option, I didn't delete the original just in
case. I guess it should work
# by default, we want this to get set.
# Even for non-interactive, non-login shells.
if [ "`id -gn`" = "`id -un`" -a `id -u` -gt 99 ]; then
umask 002
elif [ "`id -g`" -eq 502 -a `id -u` -gt 99 ]; then
umask 002
else
umask 022
fi
--------------------------------------------------------
Pablo Vitoria Garcia
Dpto. Qu�mica Inorg�nica, Facultad de Ciencias
Universidad del Pa�s Vasco (UPV/EHU)
Aptdo. 644
48080 Bilbao (Bizkaia)
Tfno. 94 6015992
Fax. 94 4648500
----- Original Message -----
From: "Frank Bax" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 15, 2004 4:10 PM
Subject: Re: [newbie] default permissions
Thanks, that explains it - my ssh and desktop tests were on different
users. When I created the 'real' users (excluding my userid) on this
computer, I put them all in the same group so they could share files. If
the name of the group is 'gwacl' and gid is 502, what code should I add/chg
so that users in this group will use 664 permissions?
Frank
At 09:46 AM 1/15/04, Pablo Vitoria wrote:
>Hi Frank,
>
>The 'if[...' line means: If the effective user name and the effective group
>name running the shell are the same, and the user ID is greather than 99
(to
>exclude special accounts like root...) then set umask equal to 002,
>otherwise set it to 022.
>
>Since, by default, when you add a user to MDK it assigns a user ID bigger
>than 500, and creates a main group for that user with the same name, you
>should get 664 permissions when creating a file (that is what happens in my
>computers) unless you do it as root (user ID = 0), or you have changed the
>defaults in MDK and your users are getting IDs < 99. Or you have changed
the
>group policy.
>
>I hope this helps
>
>Pablo
>
>--------------------------------------------------------
>Pablo Vitoria Garcia
>Dpto. Qu�mica Inorg�nica, Facultad de Ciencias
>Universidad del Pa�s Vasco (UPV/EHU)
>Aptdo. 644
>48080 Bilbao (Bizkaia)
>
>Tfno. 94 6015992
>Fax. 94 4648500
>----- Original Message -----
>From: "Frank Bax" <[EMAIL PROTECTED]>
>To: "MDK Newbie" <[EMAIL PROTECTED]>
>Sent: Thursday, January 15, 2004 2:28 PM
>Subject: [newbie] default permissions
>
>
>| On a MDK91 system shared between several staff, I notice that OOo is
>| creating files with permissions 644. If I drop to shell and create a
>file,
>| it also has 644 permissions, but if I access the machine remotely via
ssh,
>| the permissions are 664. I would like to see 664 all the time, so I
>| started some research. I found the command I'm looking for is umask and
>| that it is already executed in /etc/bashrc:
>|
>| # by default, we want this to get set.
>| # Even for non-interactive, non-login shells.
>| if [ "`id -gn`" = "`id -un`" -a `id -u` -gt 99 ]; then
>| umask 002
>| else
>| umask 022
>| fi
>|
>| But, I don't understand this code. How do I fix this problem?
>|
>|
>|
>
>
>---------------------------------------------------------------------------
-
>----
>
>
>| Want to buy your Pack or Services from MandrakeSoft?
>| Go to http://www.mandrakestore.com
>|
>
>
>
>Want to buy your Pack or Services from MandrakeSoft?
>Go to http://www.mandrakestore.com
----------------------------------------------------------------------------
----
| Want to buy your Pack or Services from MandrakeSoft?
| Go to http://www.mandrakestore.com
|
Want to buy your Pack or Services from MandrakeSoft?
Go to http://www.mandrakestore.com