Can a directory belong to more than one group?
(On windows it seems possible - but when I do an ls - it looks like there is only one group available.)
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.Sign up to join this community
If your filesystem supports posix acl extensions, then yes you can have more than one group. Most normal unix/linux tools and programs wont show you more than the default user:group:other stuff.
getfacl <file/dir> to get current acl settings and
setfacl to set them.
$ getfacl . # file: . # owner: root # group: src user::rwx group::r-x mask::rwx other::--- # only user root got write access and src group read/exec access $setfacl -m g:root:rwx . $setfacl -m g:staff:rwx . # and now root and staff groups have full write access $ getfacl . # file: . # owner: root # group: src user::rwx group::r-x group:root:rwx group:staff:rwx mask::rwx other::---
man mount for mount options
ext2: acl|noacl Support POSIX Access Control Lists (or not).
man getfacl and
man setfacl for acl examples and options.