Re: [osol-discuss] [zfs-discuss] Which kind of ACLs does tmpfs support ?

2009-09-16 Thread Trevor Pretty




Interesting question takes a
few minutes to test...

http://docs.sun.com/app/docs/doc/819-2252/acl-5?l=en&a=view&q=acl%285%29+
http://docs.sun.com/app/docs/doc/819-2239/chmod-1?l=en&a=view

ZFS

[tp47...@norton:] df .
Filesystem size   used  avail capacity  Mounted on
rpool/export/home/tp47565
    16G   1.2G   9.7G    11%    /export/home/tp47565
[tp47...@norton:] touch file.3
[tp47...@norton:] ls -v file.3
-rw-r-   1 tp47565  staff  0 Sep 16 15:02 file.3
 0:owner@:execute:deny

1:owner@:read_data/write_data/append_data/write_xattr/write_attributes
 /write_acl/write_owner:allow
 2:group@:write_data/append_data/execute:deny
 3:group@:read_data:allow
 4:everyone@:read_data/write_data/append_data/write_xattr/execute
 /write_attributes/write_acl/write_owner:deny
 5:everyone@:read_xattr/read_attributes/read_acl/synchronize:allow
[tp47...@norton:] chmod A+user:lp:read_data:deny file.3
[tp47...@norton:] ls -v file.3 
-rw-r-+  1 tp47565  staff  0 Sep 16 15:02 file.3
 0:user:lp:read_data:deny
 1:owner@:execute:deny

2:owner@:read_data/write_data/append_data/write_xattr/write_attributes
 /write_acl/write_owner:allow
 3:group@:write_data/append_data/execute:deny
 4:group@:read_data:allow
 5:everyone@:read_data/write_data/append_data/write_xattr/execute
 /write_attributes/write_acl/write_owner:deny
 6:everyone@:read_xattr/read_attributes/read_acl/synchronize:allow
[tp47...@norton:] 



Let's try the new ACLs on tmpfs

[tp47...@norton:] cd /tmp
[tp47...@norton:] df .
Filesystem size   used  avail capacity  Mounted on
swap   528M    12K   528M 1%    /tmp
[tp47...@norton:] grep swap /etc/vfstab 
swap        -        /tmp        tmpfs    -    yes    -
/dev/zvol/dsk/rpool/swap    -        -        swap    -    no    -
[tp47...@norton:] 

[tp47...@norton:] touch file.3
[tp47...@norton:] ls -v file.3
-rw-r-   1 tp47565  staff  0 Sep 16 14:58 file.3
 0:user::rw-
 1:group::r--        #effective:r--
 2:mask:rwx
 3:other:---
[tp47...@norton:] 

[tp47...@norton:] chmod A+user:lp:read_data:deny file.3
chmod: ERROR: ACL type's are different
[tp47...@norton:] 

So tmpfs does not
support the new ACLs

Do I have to do the
old way as well?


Roland Mainz wrote:

  Hi!



Does anyone know out-of-the-head whether tmpfs supports ACLs - and if
"yes" - which type(s) of ACLs (e.g. NFSv4/ZFS, old POSIX draft ACLs
etc.) are supported by tmpfs ?



Bye,
Roland

  


-- 





Trevor
Pretty |
Technical Account Manager
|
+64
9 639 0652 |
+64
21 666 161
Eagle
Technology Group Ltd. 
Gate
D, Alexandra Park, Greenlane West, Epsom
Private Bag 93211,
Parnell, Auckland










www.eagle.co.nz 
This email is confidential and may be legally 
privileged. If received in error please destroy and immediately notify 
us.


___
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org

Re: [osol-discuss] [zfs-discuss] Which kind of ACLs does tmpfs support ?

2009-09-15 Thread Robert Thurlow

Roland Mainz wrote:


Ok... does that mean that I have to create a ZFS filesystem to actually
test ([1]) an application which modifies ZFS/NFSv4 ACLs or are there any
other options ?


By all means, test with ZFS.  But it's easy to do that:

# mkfile 64m /zpool.file
# zpool create test /zpool.file
# zfs list
test   67.5K  27.4M18K  /test

Rob T
___
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org


Re: [osol-discuss] [zfs-discuss] Which kind of ACLs does tmpfs support ?

2009-09-15 Thread Ian Collins

Roland Mainz wrote:

Norm Jacobs wrote:
  

Roland Mainz wrote:


Does anyone know out-of-the-head whether tmpfs supports ACLs - and if
"yes" - which type(s) of ACLs (e.g. NFSv4/ZFS, old POSIX draft ACLs
etc.) are supported by tmpfs ?
  

I have some vague recollection that tmpfs doesn't support ACLs snd it
appears to be so...



Is there any RFE which requests the implementation of NFSv4-like ACLs
for tmpfs yet ?

  

ZFS

opensolaris% touch /var/tmp/bar
opensolaris% chmod A=user:lp:r:deny /var/tmp/bar
opensolaris%

TMPFS

opensolaris% touch /tmp/bar
opensolaris% chmod A=user:lp:r:deny /tmp/bar
chmod: ERROR: Failed to set ACL: Operation not supported
opensolaris%



Ok... does that mean that I have to create a ZFS filesystem to actually
test ([1]) an application which modifies ZFS/NFSv4 ACLs or are there any
other options ?
Use function interposition.  I am currently updating an ACL manipulation 
application and I use mocks for the acl get/set functions.


--
Ian.

___
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org


Re: [osol-discuss] [zfs-discuss] Which kind of ACLs does tmpfs support ?

2009-09-15 Thread Mark Shellenbaum

Roland Mainz wrote:

Hi!



Does anyone know out-of-the-head whether tmpfs supports ACLs - and if
"yes" - which type(s) of ACLs (e.g. NFSv4/ZFS, old POSIX draft ACLs
etc.) are supported by tmpfs ?



tmpfs does not support ACLs

see _PC_ACL_ENABLED in [f]pathconf(2).  You can query the file system 
for what type of ACLs it supports.





Bye,
Roland




___
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org