Linux commands for me

To add user to a group

useradd -g group user

id user

 

To cause all future folders and files created in /samba/founders to be owned by the “founders” group, do the following

chgrp founders /samba/founders && chmod g+s /samba/founders

Change permissions in all sub folders and files

chmod -R 755 directory-name/

read = 4
write = 2
execute = 1

so:
r– = 4
rw- = 6
rwx = 7