<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7653.38">
<TITLE>RE: [Gluster-users] help, chmod g+s FOLDER doesn't make sense under glusterfs</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->
<P><FONT SIZE=2>Hi Raghavendra,<BR>
<BR>
<BR>
I appreciate your quick reply.<BR>
<BR>
<BR>
I would hope that glusterfs can set the file's group id to the mode of the<BR>
parent directory(if it has a set group id). This feature is very useful for group sharing. Let me show an example here.<BR>
<BR>
<BR>
[citiceo@bass1 tmp]$ id<BR>
uid=10000(citiceo) gid=1000(citi) groups=1000(citi),1002(allbankusers)<BR>
[citiceo@bass1 tmp]$ ll -d a<BR>
drwxrws--- 2 root allbankusers 4096 Aug 25 22:41 a<BR>
[citiceo@bass1 tmp]$ echo abc > a/b<BR>
[citiceo@bass1 tmp]$ ll a/b<BR>
-rw-r----- 1 citiceo allbankusers 4 Aug 25 22:41 a/b<BR>
<BR>
[chaseceo@bass1 tmp]$ id<BR>
uid=10001(chaseceo) gid=1003(chase) groups=1002(allbankusers),1003(chase)<BR>
[chaseceo@bass1 tmp]$ cat a/b<BR>
abc<BR>
<BR>
<BR>
This examples shows how citiceo share a file to chaseceo under ext3 filesystem. If glusterfs is used, citiceo has to run an additional command chgrp to change the file's group ownership.<BR>
<BR>
<BR>
chgrp is not a hassle for any cluster administrator. But for regular users, it is a big problem. Moreover, glusterfs is a great filesystem, with which one can create a huge size file system for a cluster that has complicated users and groups mapping. Group sharing is an important feature for such a system, so cluster administrators don't need to train their users.<BR>
<BR>
<BR>
Best,<BR>
Manhong<BR>
<BR>
<BR>
<BR>
-----Original Message-----<BR>
From: Raghavendra G [<A HREF="mailto:raghavendra.hg@gmail.com">mailto:raghavendra.hg@gmail.com</A>]<BR>
Sent: Mon 8/25/2008 10:13 PM<BR>
To: Dai, Manhong<BR>
Cc: gluster-users@gluster.org<BR>
Subject: Re: [Gluster-users] help, chmod g+s FOLDER doesn't make sense under glusterfs<BR>
<BR>
Hi,<BR>
<BR>
below is an excerpt of 'man creat'<BR>
<BR>
O_CREAT<BR>
If the file does not exist it will be created. The owner<BR>
(user ID) of the file is set to<BR>
the effective user ID of the process. *The group ownership<BR>
(group ID) is set either to<BR>
the effective group ID of the process or to the group ID of<BR>
the parent directory* (depend-<BR>
ing on filesystem type and mount options, and the mode of the<BR>
parent directory, see, for<BR>
example, the mount options bsdgroups and sysvgroups of the<BR>
ext2 filesystem, as described<BR>
in mount(8)).<BR>
<BR>
glusterfs is setting the group ownership to effective group id of the<BR>
process.<BR>
<BR>
regards,<BR>
<BR>
On Tue, Aug 26, 2008 at 5:51 AM, Dai, Manhong <daimh@umich.edu> wrote:<BR>
<BR>
> Hi,<BR>
><BR>
><BR>
> This test is done under ext3 file system<BR>
> [root@bass1 ~]# id<BR>
> uid=0(root) gid=0(root)<BR>
> groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel)<BR>
> [root@bass1 ~]# ll -d a<BR>
> drwxr-sr-x 2 root allusers 4096 Aug 25 21:44 a<BR>
> [root@bass1 ~]# touch a/b<BR>
> [root@bass1 ~]# ll a/b<BR>
> -rw-r--r-- 1<BR>
> root allusers 0 Aug 25 21:44 a/b<BR>
><BR>
><BR>
> This test is done under glusterfs file system<BR>
> [root@bass1 home]# ll -d a<BR>
> drwxr-sr-x 2 root allusers 6 Aug 25 21:45 a<BR>
> [root@bass1 home]# touch a/b<BR>
> [root@bass1 home]# ll a/b<BR>
> -rw-r--r-- 1 root root 0 Aug 25 21:46 a/b<BR>
><BR>
><BR>
> As we see here, the file b should belong to group allusers.<BR>
><BR>
> Doesn't gluster support this feature? which could make group sharing easy.<BR>
> I would rather I did something wrong, please tell me how to fix this<BR>
> problem.<BR>
><BR>
><BR>
> Best,<BR>
> Manhong<BR>
><BR>
> _______________________________________________<BR>
> Gluster-users mailing list<BR>
> Gluster-users@gluster.org<BR>
> <A HREF="http://zresearch.com/cgi-bin/mailman/listinfo/gluster-users">http://zresearch.com/cgi-bin/mailman/listinfo/gluster-users</A><BR>
><BR>
><BR>
<BR>
<BR>
--<BR>
Raghavendra G<BR>
<BR>
A centipede was happy quite, until a toad in fun,<BR>
Said, "Prey, which leg comes after which?",<BR>
This raised his doubts to such a pitch,<BR>
He fell flat into the ditch,<BR>
Not knowing how to run.<BR>
-Anonymous<BR>
<BR>
</FONT>
</P>
</BODY>
</HTML>