如何将文件从本地复制到某个远程服务器,该服务器在默认端口(22)之外的端口上托管ssh。
我通常使用以下方式连接到服务器:
ssh username@remotehost.com -p 2000
现在我需要使用scp复制文件 user@localbox:~$ scp ~/.ssh/id_rsa.pub user@remotebox.remotedomain.tld:~/.ssh/id_rsa_localbox.pub -p 2000
但是这并不起作用。
我通常使用以下方式连接到服务器:
ssh username@remotehost.com -p 2000
现在我需要使用scp复制文件 user@localbox:~$ scp ~/.ssh/id_rsa.pub user@remotebox.remotedomain.tld:~/.ssh/id_rsa_localbox.pub -p 2000
但是这并不起作用。
sshfs
也是一个选择 :) - user323419