Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the Linux commands that are often used at work

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

This article is about Linux commands that are often used at work. The editor thought it was very practical, so I shared it with you to learn. The following information is about the Linux command.

Scp is a file copy with Security, which is logged in based on ssh. It is easy to operate, for example, to copy a current file to another remote host, you can use the following command.

Scp / home/1.gif root@172.19.2.75:/home/root

Then you will be prompted to enter the login password of the root user on the other 172.19.2.75 host, and then you will start cp and ungzip

If you want to do the reverse, copy the file from the remote host to the current system, it is also very simple:

Scp root@172.19.2.75:/home/abc.gif / home/root

Find-name ap*-o-name may* / * find files that start with ap or may

Find the content of the text file: / content can quickly locate the shift+insert paste

[root@localhost xss] # cat text1.ini | grep file to check whether the file has the word "text1.ini".

/ test > cat 123.txt | grep wao*

Text content in md::y en:gaaiih waomen # 123.txt

[root@localhost xss] # cp test.cpp. / 123 / / copy

[root@localhost xss] # mv test.cpp test123.cpp / / naming

/ data/AutoBuild/src/photo_branch/test/pp > cp 123_bf.txt 1234.txt back up the file

Command

Command line description

Command

Command line description

Command

Command line description

U

Restore the previous operation

Dd

Delete the current line

[number of rows to copy] yy

The ability to copy text

X,x

Before deleting the cursor, delete the characters in the cursor

A

Insert a new character under the current character

P

Paste

: s/from/t/g

Replace t with all from in the current line

S/from/to/gc is replaced, but the user is asked to confirm dd each time

Delete the current line

[number of rows to copy] yy

Ability to copy text:% s/from/to/g%s represents the entire text replacement

A

Insert a new character under the current character

P

Paste

: X save changes and exit

About Linux commonly used commands to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report