Operating system: Introduction to SFTP related knowledge

Operating system: Introduction to SFTP related knowledge

Today I will share with you some knowledge about SFTP, I hope it will be helpful to you!

1. What is SFTP?

SFTP (SSH File Transfer Protocol) is a secure file transfer protocol based on SSH (Secure Shell). Using the SFTP protocol can provide a secure network encryption algorithm during file transfer, thereby ensuring the secure transmission of data. In the Linux operating system, the default port of SFTP is 22. The transmission provides a password and key authentication mechanism, which can effectively prevent threats and public technology during the transmission process.

2. SFTP Composition

Server: The host where the SFTP service is installed, usually a Linux server. Windows servers can also install the SFTP service through software, such as freeSSHd software. Client: The client that installs the software to access the SFTP server, such as XFTP, WinSCP, FileZilla, FlashFXP and other clients.

3. SFTP verification connection method

  • Account and password verification: Use account ID and password for verification, and the credentials are encrypted during the verification process.
  • SSH key authentication: Authentication is performed using an SSH password.
  • Account password + SSH key mixed verification: Both verifications must be met before a connection can be made.

4. Common SFTP commands

4.1 Login

 #Password login
sftp -P 22 [email protected]
#Key login
sftp -P 22 -i ~/.ssh/id_rsa [email protected]

4.2 Basic Operations of SFTP Shell

 #Current working directory:
pwd
#View the files in the current directory:
ls
ls -la
# Change directory:
cd
#Local working directory:
lpwd
#View the files in the local working directory:
lls
#Switch the local working directory:
lcd dirname

4.3 Download server files to local

 #Download the server file to local
get remote_file_name
#Rename
get remote_file_name local_file_name
#recursion
get -r some_directory_name
#Keep the original file attributes and date
get -Pr some_directory_name

4.4 Upload local files to remote server

 #Upload local files to the remote server
put localFile
#recursion
put -r local_directory_name

<<:  Do you know two common communication methods of Vue?

>>:  By the end of 2021, my country will have 10.1 5G base stations per 10,000 people

Recommend

Can IPTV also have a nationwide network?

IPTV is good, everyone knows it! The number of IP...

Domain name www, to have or not to have, that is the question

Historical background Although people often confu...

6G! China Mobile and Nokia renew strategic cooperation agreement

Zhongguancun Online News: China Mobile and Nokia ...

GSMA releases world's first new 5G network guidelines

GMSA and China Telecom have released new guidelin...

Network management benefits! Several difficult problems and solutions for LAN

As a qualified network administrator, I believe t...

Learning and remembering: RPC framework calling process

Introduction to RPC RPC is the abbreviation of Re...

By 2028, the global 5G infrastructure market will reach US$80.5 billion

[[417378]] According to data released by market r...

The data is not real-time enough: try long connection?

background In certain scenarios, we often need to...