Test report 6: Linux file and directory management 3 (ultra-detailed version)

Experiment 1 umask, chattr, lsattr usage

Purpose: to master the use of umask, chattr, lsattr of.

Experimental requirements:

1, the authority of detection umask as root.

2, create a file test1, a directory test2, see their rights.      

           

                                                               

3, change the umask 002.

4, create a file test3, a directory test4, see their rights.

5, question: Suppose your umask is 003, what umask this case, the file and directory permissions created for?

File: -rw-rw-r--

Contents: drwxrwxr--

6, restore umask of 022.

7, create a directory in the / tmp as XX.

8, set the directory XX of the hidden attribute parameter is a.

9. Create a directory aa xx directory, bb directory.

10, try to delete the directory under the XX bb directory, whether be deleted?

11, created in the / tmp file or a folder, its hidden attribute parameter is set to i, whether this file or folder for deletion, modify, add, and other operations?

 

Published 165 original articles · won praise 436 · views 110 000 +

Guess you like

Origin blog.csdn.net/weixin_44015669/article/details/104095300