Kitloft

All tools / chmod reference

chmod 2775 (rwxrwsr-x)

Like 775, with setgid. The usual mode for a shared project directory where every new file should belong to the team group.

chmod 2775 in symbolic form
rwxrwsr-x

Who can do what

ReadWriteExecute
Owner✓✓✓
Group✓✓✓
Others✓–✓

Commands

Set the mode
chmod 2775 my-dir
# same thing in symbolic form:
chmod u=rwx,g=rwxs,o=rx my-dir

In ls -l output, a file with this mode shows as -rwxrwsr-x and a directory as drwxrwsr-x.

Try a different mode

ReadWriteExecuteSpecial
Owner
Group
Others
Octal Symbolic
Command