File/Directory Permissions Deck Flashcards
Review Permissions - Done as root user
chmod u+rwx file2
Add all permissions to owner of file2
chmod u-x file2
Remove the owner’s permission to execute file2
chmod g+w file2
Add permission to write to the group for file2
chmod o-rwx file2
Remove all permission for others for file2
chmod 777 dir1
Allow all permissions to all users for dir1
chmod 764 dir1
Allow the owner all permissions, the group read and write only and others read only for dir1
chmod g-rw file2
Remove read and write permission for the group for file2
chmod o+wx file2
Add write and execute permission for others for file2
chmod 464 dir1
Allow owner to read only, the group to read and write, the others to read only for dir1
chmod 661dir1
Allow the owner and the group to read and write only and the others to only execute for dir1
chmod 756 dir1
Allow owner all permissions, the group to read and execute only and the others to read and write only for dir1
chmod 532 dir1
Allow the owner to read and execute, the group to write and execute and the others to write only for dir1
Assign ownership of file8 to Group1
chown :Group1 file8
Check for file user and group ownership
ll
Assign ownership of dir4 to User2
chown User2 dir4
or
chown User2: dir4