[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Understanding the files attributs



Good afternoon,

First, thank you very much for the wonderful work you did with this
distribution.

I spent hours to understand how functions the "s" attribut.

In a course on Samba, I read the explanation about the exercice:
root# chmod -R ug+rwxs,o-w,o+rx /data   .....

.... and the chmod operation recursively sets the permissions so
that the owner and group have SUID/SGID with read/write/execute
permission, and everyone else has read and execute permission. This
means that all files and directories are created with the same
owner and group as the directory in which they are created. Any new
directories created still have the same owner, group, and
permissions as the directory they are in.

I practised and was unable to produce the result so waited.
I created a directory: drwsrws--- user user date-time test and inside another one: test2
The result is:   user@mymachine:/test$ ls -l
     drwxr-sr-x        user    user   date-time   test2

The user and group OK but the "permissions as the directory they
are in..." waouhh...

Infos: Debian bf24 with kernel 2.6.10. Just a test machine with a
swap and "/", ext3 mounted with options defaults,errors=remount-ro

normally the defaults seam to be: rw, suid ... man pages say that
suid is for user and group, no mention about permissions.

I suppose there is something I missed. The "umask" as been used as
I can see ... Is there somewhere another parameter ?

Does somebody want to light my lantern ?

With my anticipated thanks.

Daniel



Reply to: