First paragraph: Common file types
-Normal file
D catalog File
B-Block file
L Soft links (equivalent to shortcuts in Windows)
Second paragraph: Permissions
* * * Three-bit for a group
Top three: Represents the file's owner's permissions on the file
Intermediate three-bit: the permissions on the file that represent the genus Group of the file
Post three-bit: represents other people's permissions on the file
R readable
W Writable
X executable
-Placeholder
Third paragraph:
. Represents a permissive level created under the
Command: Getenforce view selinux status
Vim/etc/sysconfig/selinux
SELinux three levels: change after reboot effective
Enforcing open, effective
Permissive warning but no limit
Disabled uninstalling the module does not use
Fourth: Number of file hard connections
Fifth paragraph: Owner
Sixth paragraph: Genus Group
Seventh: File Size (bytes) ll-h (more friendly display of file size)
Eighth Paragraph: Creation date
Nineth paragraph: File name
Modify file permissions (i)
chmod u=rwx Shuai.txt
chmod g=rx,o=x Shuai.txt
chmod u=r,g=-,o=-
Modify directory Permissions (i)
Same as changing files
Recursively modifies the directory itself and all directories and files under it
The command is: chown-r
modify file permissions, Modify directory Permissions (ii)
Use +-= To modify
modify file permissions, Modify directory Permissions (iii)
R------> 4
W------> 2
x------> 1
For files:
READ: Can read the contents of the file
Write: Can modify the contents of the file
Execute: You can execute the file as a program
For catalogs:
READ: You can see subdirectories and sub-files under this directory
Write: You can create, delete, and rename files in this directory
Execute: Can CD into the directory
Linux Permissions Related