Local login server and file transfer command

The server is used in the recent development, record the command:

Login server:

ssh [email protected]

Login server (specific port):

ssh -p 端口号 [email protected]

Transfer files locally to the server :

scp ./文件名 [email protected]:/root/路径

Transfer files locally to the server (specific port):

scp -P 端口号 ./文件名 [email protected]:/root/路径

The server downloads files to the local :

scp [email protected]:/root/文件路径 ./

Exit ssh:

logout

Guess you like

Origin blog.csdn.net/Rachel_IS/article/details/107200720