Universal Linux basic knowledge, Linux files and folder permissions, do not move on 777 permissions. The online tutorial is too complex to be wordy, briefly summarized as follows ...
One, view Linux file permissions
Ls-l (General)
LL (Ubuntu applies, equals Ls-al)
Ii. Permission Identifiers
R (Read), W (write), X (Execute)
4 (Read), 2 (write), 1 (performed)
Note: The directory must have executive rights to read
Second, modify the Linux file permissions
Method One
Chmod-r 777 dir/
-R Change dir directory and all sub files and folders within Dir
777 refers to the "file belongs to the user, belong to the user group, other users" to read, write, execute.
Method Two
chmod parameters: A (user and group), U (user), G (Group), 0 (other users)
chmod operator: + (plus),-(minus), = (given)
chmod +x file.txt (user, group, other user, plus execution)
chmod u+x file.txt (user, plus executive right)
Third, Linux common file permissions
777 (Read and write execution, read/write execution, read and write execution)
755 (Read and write execution, reading execution, read execution)
644 (Read and write, reading, reading)
400 (read, prohibit, prohibit