这里使用的是scp实现远程拷贝上传文件
import paramiko
scp = ssh.open_sftp()
#上传
scp.put('local_file_path','remote_file_path')
#拷贝
scp.get('remote_file_path','local_file_path')
scp.close()
说明:local_file_path是本地文件的路径;remote_file_path是远端服务器上的文件路径
这里使用的是scp实现远程拷贝上传文件
import paramiko
scp = ssh.open_sftp()
#上传
scp.put('local_file_path','remote_file_path')
#拷贝
scp.get('remote_file_path','local_file_path')
scp.close()
说明:local_file_path是本地文件的路径;remote_file_path是远端服务器上的文件路径