mkdir command
The mkdir command is used to create a directory of the specified name, requiring that the user who created the directory has specific write permissions, and that the designated directory cannot be a directory in the current directory.
1. command format
mkdir [Options ] directory
2. command function
The mkdir command enables you to create the specified directory at the specified location, and the user who creates the folder or directory must have folder write permissions. and the folder you create cannot have the same name as the file names in its parent directory.
3. command Parameters
-M = Model mode, set permissions < modes >
-P = Parents to create a multi-level directory, this can be a directory
- v = verbose Displays information each time a new directory is created
--HELP Display Help information and exit
--version output version information and exit
4. Command instances
A. Mkdir directory 1 directory 2, can create multiple directories, multiple directories separated by spaces
650) this.width=650; "Src=" Http://s2.51cto.com/wyfs02/M02/89/B7/wKioL1ga1WSQHMQgAAAK4DRls10743.png-wh_500x0-wm_3 -wmp_4-s_2798869307.png "title=" image 1.png "alt=" Wkiol1ga1wsqhmqgaaak4drls10743.png-wh_50 "/>
b. mkdir-p a/b/c/d/e Create a multilevel directory
650) this.width=650; "Src=" Http://s4.51cto.com/wyfs02/M00/89/B7/wKioL1ga1bjhXHQRAAAQ8pJj5_w584.png-wh_500x0-wm_3 -wmp_4-s_3576678353.png "title=" image 2.png "alt=" Wkiol1ga1bjhxhqraaaq8pjj5_w584.png-wh_50 "/>
c. mkdir-m 777 Dir1 Create A directory that creates permissions for 777
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M00/89/B7/wKioL1ga1eGDgfVsAAAk38txbnY589.png-wh_500x0-wm_3 -wmp_4-s_472409756.png "title=" image 3.png "alt=" Wkiol1ga1egdgfvsaaak38txbny589.png-wh_50 "/>
d. mkdir-v aaaa Creating a new directory displays information
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M01/89/B7/wKioL1ga1iSTBWTnAAAu8P-kgmw218.png-wh_500x0-wm_3 -wmp_4-s_3269261488.png "title=" image 4.png "alt=" Wkiol1ga1istbwtnaaau8p-kgmw218.png-wh_50 "/>
E. MKDIR-VP Scf/{lib/,bin/,doc/{info,product},logs/{info,product},service/deploy/{info,product}}: a command to create a directory structure for a project
650) this.width=650; "Src=" Http://s2.51cto.com/wyfs02/M02/89/BA/wKiom1ga1jLTX8RRAABMsNPVIWE051.png-wh_500x0-wm_3 -wmp_4-s_2712599663.png "title=" image 5.png "alt=" Wkiom1ga1jltx8rraabmsnpviwe051.png-wh_50 "/>
Linux Common Commands Summary 01:mkdir