【Linux 命令】mkdir

查看帮助
$ mkdir --help

Usage
mkdir [OPTION]... DIRECTORY...

Option

-m, --mode=MODE   set file mode (as in chmod), not a=rwx - umask
-p, --parents     no error if existing, make parent directories as needed
-v, --verbose     print a message for each created directory
-Z                set SELinux security context of each created directory to the default type
    --context[=CTX]  like -Z, or if CTX is specified then set the SELinux or SMACK security context to CTX
    --help     display this help and exit
    --version  output version information and exit

实用命令
mkdir -m 700 -p /test/test1
-m 700 表示仅owner有rwx权限
-p /test/test1 表示递归创建文件,即先创建test,再创建test1

参考资料
https://www.cnblogs.com/zhongguiyao/p/9169361.html
https://blog.csdn.net/Simon_coder/article/details/78660978/

【Linux 命令】mkdir

上一篇:Ubuntu设置双网卡, 让开发板可以通过PC的网卡上网


下一篇:07、linux设置开启启动