Linux Learning: Chapter Three-linux common commands -2__linux

Source: Internet
Author: User
Tags clear screen

A file Operation command

1 Create an empty file or modify the file time

Touch filename

Command name: Touch

Path to command:/bin/touch

Execute Permissions: All Users

2) Delete

RM-RF file name

-R Delete Directory

-F Coercion

Command name: RM

Command English original intention: remove

Path to command:/BIN/RM

Execute Permissions: All Users

3 Cat file name to view the contents of the file. Through

Command name: Cat

Path to command:/bin/cat

Execute Permissions: All Users

-N List Line numbers

4) More File name screen display file content

Command name: more

Path to command:/bin/more

Execute Permissions: All Users

Space to page DOWN b page UP Q exit

6) Head FileName Display file header

Command name: Head

Path to command:/usr/bin/head

Execute Permissions: All Users

Head-n Row Number file name specifies the first few lines of the file to display

head-n 20 filename

HEAD-20 file name

7) Tail file name display end

CTRL + C forced termination

Ctrl+l Clear Screen

8) Symbolic Link file

ln

Command name: LN

Command English original intent: Link

Path to command:/BIN/LN

Execute Permissions: All Users

Shortcut

New links, taking different hard drive locations

Modify either file, both changes

Delete source file, soft connection not open

Ln-s source file file name must write absolute path


Two commands that both files and directories can operate


1 RM Delete files or directories

2) Copy

Command name: CP

Command English original intention: copy

Path to command:/BIN/CP

Execute Permissions: All Users

CP Source file target Location

-R Replication Directory

-P Joint File property copy

-D If the source file is a linked file, copy the link property

-A equivalent to-PDR

CP AA/TMP/AA formerly replicated

CP aa/tmp/bb renamed Replication

3) Cut or renamed

Command name: MV

Command English original meaning: move

Path to command:/BIN/MV

Execute Permissions: All Users

MV Source file target location

mv/root/aa/tmp/

MV AA BB


Three Rights Management

1 Permission Bits

-rw-r--r--1 root 0 08-11 01:45 AA

Permission bit is 10-bit

First: Representing file types

-Common documents

D Catalog Files

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.