正在处理服务器paramHexIko断开的连接

2024-09-24 02:22:30 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在尝试将文件从远程服务器复制到本地目录。在

我使用pythonparamiko的sftpget来复制文件。在

sftp.get(remote_pate, local_path)

在复制了很少的文件之后,我得到了以下异常。在

^{pr2}$

使用建立连接

ssh = paramiko.SSHClient()
ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
ssh.connect(host, username=username, password=password)
sftp = ssh.open_sftp()

为什么连接断开了?我该怎么办?提前谢谢。在


Tags: 文件服务器目录hostparamikoget远程remote