This blog if there is insufficient to write the place also hope that readers will not hesitate to enlighten
Introduce the symbol in the blog: [] Everything is not fixed, ... Indicates that there can be more than one!
Basic knowledge of files
File metadata: Non-file components, including: file name, size, type, permissions, the genus owner Group, the timestamp of the file
File data: Content in a file (part of a file)
Three timestamps of files
Accesstime : File access time; shorthand "atime" to read the contents of the file
Modifytime : File modification time; abbreviated "Mtime", content changed
Changetime : File change time; abbreviated "CTime", metadata changed
Touch command to create a new file and change the timestamp of the file
Syntax: touch [filename ...]
Touch [ Options ...] [filename ...]
Options:
-A : Change access time only
- C : Do not create any files
- M : Change only modified time
- D : Change access time and modification time at the same time
- T : Use the specified timestamp instead of the current time, if the file exists, change the file's access time and the time stamp for the file's modification time, if the file does not exist, create a file, specify the access time of the file and the time stamp of the file modification time; Format: "Month day hour minute."
mkdir Command Create a new directory
Syntax: mkdir [filename ...]
mkdir [ Options ...] [File name]
Options:
- P : Continuous creation of multi-level catalogs; directory presence not error
- v : Show creation Process
- M : Add octal permission bit after option; Set permissions to create directory
New file or directory considerations
1. file names are strictly case sensitive
2. file name can use any character except "/", special characters are not recommended
3. The maximum length of the file name cannot exceed 255 characters
4. file name with "." Files that begin with are hidden files
5. If there is a space in the file name, enclose it in quotation marks ""
For a command to view file metadata, I'll introduce you in the next blog post
Finally write to the friend who is learning Linux: Want to learn Linux more practice, light can not learn, light listen also learn not, only more practice to know the mastery of Linux
If you do not know anything about this blog or have any suggestions can give me a message, your support is my future to write the power of the blog
Linux New files and directories