Developer on Alibaba Coud: Build your first app with APIs, SDKs, and tutorials on the Alibaba Cloud. Read more ＞
Basic Linux commands-general Linux technology-Linux technology and application information. For more information, see the following. Below are some LINUX commands
Basic Linux commands
Ls-r (recursive) recursion. In addition to displaying all the files under the directory, there are all the files under the subdirectory of the Directory, that is, all the fruits are poured out.
Ls -- color: the executable file is green, the normal file is white, and the directory is blue (the directory is also a file .)
Ls -- help
Change directories, create new directories, and delete directories
Cd/command to the root directory.
Cd/directory name to a directory.
Cd... to the directory at the upper level.
Cd back to your directory
Create a directory using mkdir
For example, mkdir loveletter creates a directory named loveletter.
Mkdir. loveletter creates a new hidden directory
Rm deletes a file. For directories with files,
Rm file name/directory name to be deleted cannot be deleted directly.
Delete the files in the rm directory-rf connection directory together.
Mv command to change the file name and directory name
Command for copying files and directories using cp
Man command usage reference tool.
For example, the old mv file name is a new file name.
Old mv directory name new directory name
Use of cp
Cp loveletter newloveletter because of the file loveletter and the new file newloveletter
Cp loveletter home/loveletter new file is created in home, so you can name it again
Man _ command name
Man ls can see all the explanations about ls commands.
Enter the user name and password, root/key
After entering, because the front selection is not a graphical interface, may be disappointed, but to study the real linux, you must practice this.
Ls command to list files and directories.
It must be blank for the first time, because you have not created any files
Ls-A lists all files, including hidden files. As long as the first character before the file name is A ".", this file is A hidden file.
If the first character before a directory name is ".", the directory is hidden.
Ls-l is used to first create a list
This article is an English version of an article which is originally in the Chinese language on aliyun.com and is provided for information purposes only. This website makes no representation or warranty of any kind, either expressed or implied, as to the accuracy, completeness ownership or
reliability of the article or any translations thereof. If you have any concerns or complaints relating to the article, please send an email, providing a detailed description of the concern or
complaint, to email@example.com. A staff member will contact you within 5 working days. Once verified, infringing content will be removed immediately.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
and provide relevant evidence. A staff member will contact you within 5 working days.