I. File rename and move (MV) In Linux, renaming files is called moving (moving). The MV command can move files and directories to another location or rename them. 1.1 Using the MV RenameBelow/usr/local create an empty file as test, using the MV
The MV Mobile directory is divided into 2 scenarios:The first type: The target directory is empty, the MV command can be used to move directly, use absolute path to execute or add parameter-F does not prompt whether to move. [[email protected] ~]#
The zero-based Linux 19th ChapterHello~~ again to a week Update blog time ~ ~ This week 51CTO success will blog function upgrade ~ ~ To bring us a new experience ~ ~ New Interface ~ new visual Sense ~ ~ But, in the editor ~ small or accustomed to
In the Linux system, all files, even the CD-ROM also as a file, to use the CD first to establish a directory, and then by mounting to operate the disc, even the mouse, the keyboard is considered a file. Therefore, it is important to learn the
To copy files, use the CP (copy) command. However, the CP command has many uses. In addition to simple replication, you can also create a connection file (that is, a shortcut), compare the new and old two files and update them, copy the entire
Format of the Linux command:commands [-options] [parameters]Cases:Ls-la/etcCommand: LSCommand path:/bin/lsFeatures: Displaying directory filesUsage: ls [-ALDH] []Parameters:-A view all files, including hidden files. The hidden files for Linux are "."
CP command: cp-copy files and directories"Function" copy function, commonly used to do service configuration file backupCP means copy, is the copy of the abbreviation, copy the file and the intention to rename the file, when copying multiple files,
Basic Linux knowledge-file management commands (cp, mv, rm)
In our daily work, we use the five most file operations: Copy, cut, move, rename, and delete. Therefore, we will introduce the three commands involved in the above five operations in Linux:
The CP command copies the source file or directory to the destination file or directory. If the source file is a normal file, the command copies it to the specified destination file, and if it is a directory, you need to use the "-r" option to copy
Linux Command mv, linuxmv
Mv in linux means move.
The general form of this command:
Mv [Option] parameter 1 parameter 2
Option:
-B. If the same file name already exists, back up the file before overwriting.
-F if the same file name already exists
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:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.