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 is the specific use of the Linux system commands scp and ssh

2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

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

Today, I will introduce to you how to use the Linux system commands scp and ssh. The content of the article is good. Now I would like to share it with you. Friends who feel in need can understand it. I hope it will be helpful to you. Let's read it along with the editor's ideas.

If the port of ssh is 22, you don't have to specify the-p or-P options.

1.sshLinux uses the ssh command to log in to the server: ssh-l root-p 188 192.168.1.2ssh-l user name-p port number host name or IP enter the password

The 2.scpscp command copies a file or directory command:

Copy files: (1) copy local files to remote scp-P 22 file name user name @ computer IP or computer name: remote path scp-P 22 test.txt root@192.168.1.163:/opt/ (2) copy files back to local scp-P 22 user name @ computer IP or computer name: file name local path scp-P 22 root@192.168.1.163:/opt/test.txt / opt

Copy directory: (1) copy local directory to remote scp-r-P 22 directory name user name @ computer IP or computer name: remote path scp-r-P 22 / opt/test/ root@192.168.1.163:/opt/ (2) copy directory back to local scp-r-P 22 user name @ computer IP or computer name: directory name local path scp-r- P 22 root@192.168.1.163:/opt/test/ / opt/

3. Usage problem

If scp can be used on this machine, an error will be reported when scp uploads the file:

Bash: scp: command not found

Lost connection

Then the other party does not have the openssh-clients package installed.

4. After testing, in our company to use scp to upload files to the server, the speed reaches 500KB/S~900KB/S, if you use FlashFXP, the speed is only 40KB/S, powerful scp.

What is Linux system Linux is a free-to-use and free-spread UNIX-like operating system, is a POSIX-based multi-user, multi-task, multi-threaded and multi-CPU operating system, using Linux can run major Unix tools, applications and network protocols.

The above is the whole content of the specific use of Linux system commands scp and ssh, more and more related to the specific use of Linux system commands scp and ssh can search the previous articles or browse the following articles to learn ha! I believe the editor will add more knowledge to you. I hope you can support it!

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

Development

Wechat

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

12
Report