[Linux] - Managing Permissions and Ownership
[Linux] - Managing Permissions and Ownership Topic A: Modify File and Directory Permissions Permissions # ls -l : a long list of files and directories in your current working directory Permission Attributes # - r : Read # -w : Write # -x : Execute Permission Context: # Owner ( u ): user # Group ( g ) # Other ( o ) Permission String Chmod Command Modify the permissions of a file or directory. It has two forms: Chmod symbolic mode and Chmod absolute mode. Chmod symbolic mode # Permission contexts: u/g/o/a # Permission operators: +/-/= # Permission attributes: r/w/x # chmod +x <filename> : add execution permissions on the installation file # chmod g+r file1 : give group read permission to file # chmod o-r : removes read for others # chmod go+rw file1 : give group and other read and write permission # chmod go+rw file1 # ls -l # chmod go-rwx DirA # ls -l # chmod go-w file1 # ls -l Chmod absolute mode # chmod 764 file1 : user=rwx; group=rw; others=r # chmod 700 file1 ...
Comments
Post a Comment