taking the experimental environment of centos6.5 as an example
1. Create/tmp directory: A_c, A_d, B_c, B_d
[[email protected] tmp]# Mkdir-pv/tmp/{a,b}_{c,d}
mkdir: The directory "/tmp/a_c" has been created
mkdir: The directory "/tmp/a_d" has been created
mkdir: The directory "/tmp/b_c" has been created
mkdir: The directory "/tmp/b_d" has been created
Note:-P If no parent directory is automatically created,-V displays the workflow, not a required option.
2, create the/tmp/mylinux directory:
[Email protected] tmp]# mkdir-pv/mylinux/{bin,boot/grub,dev,etc/{rc.d/init,sysconfig/network-scripts},lib/ Modules,lib64,proc,sbin,sys,tmp,usr/local/{bin,sbin},var/{lock,log,run}}
\mkdir: The directory "/mylinux" has been created
mkdir: The directory "/mylinux/bin" has been created
mkdir: The directory "/mylinux/boot" has been created
mkdir: The directory "/mylinux/boot/grub" has been created
mkdir: The directory "/mylinux/dev" has been created
mkdir: The directory "/MYLINUX/ETC" has been created
mkdir: The directory "/MYLINUX/ETC/RC.D" has been created
mkdir: The directory "/mylinux/etc/rc.d/init" has been created
mkdir: The directory "/mylinux/etc/sysconfig" has been created
mkdir: The directory "/mylinux/etc/sysconfig/network-scripts" has been created
mkdir: The directory "/mylinux/lib" has been created
mkdir: The directory "/mylinux/lib/modules" has been created
mkdir: The directory "/MYLINUX/LIB64" has been created
mkdir: The directory "/mylinux/proc" has been created
mkdir: The directory "/mylinux/sbin" has been created
mkdir: The directory "/mylinux/sys" has been created
mkdir: The directory "/mylinux/tmp" has been created
mkdir: The directory "/MYLINUX/USR" has been created
mkdir: The directory "/mylinux/usr/local" has been created
mkdir: The directory "/mylinux/usr/local/bin" has been created
mkdir: The directory "/mylinux/usr/local/sbin" has been created
mkdir: The directory "/mylinux/var" has been created
mkdir: The directory "/mylinux/var/lock" has been created
mkdir: The directory "/mylinux/var/log" has been created
mkdir: The directory "/mylinux/var/run" has been created
Use the tree command to view the directory hierarchy we are currently creating
[Email protected] tmp]# Tree/mylinux
-bash:tree:command not found
Installing the tree command using the Yum-y install tree
[email protected] tmp]# Yum install-y tree
[Email protected]/]# Tree/mylinux
/mylinux
├──bin
├──boot
│└──grub
├──dev
├──etc
│├──rc.d
││└──init
│└──sysconfig
│└──network-scripts
├──lib
│└──modules
├──lib64
├──proc
├──sbin
├──sys
├──tmp
├──usr
│└──local
│├──bin
│└──sbin
└──var
├──lock
├──log
└──run
Directories, 0 files
Linux file directory structure experiment