connection abort: recv failed when upload file to AWS EC2
- Dominant language
- Java
- Stars
- 2.7k
- Forks
- 620
- Avg merge
- 3d 23h
- Merged PRs (30d)
- 11
Description
Run script successfully on AWS EC2 but failed when upload file use SFTP.
I have try version 15-21, all have such problem.
Client and Server Version:
[main] INFO net.schmizz.sshj.transport.TransportImpl - Client identity string: SSH-2.0-SSHJ_0_17_2
[main] INFO net.schmizz.sshj.transport.TransportImpl - Server identity string: SSH-2.0-OpenSSH_6.6.1
Code:
```
final String src = "C:\\winscp555setup.7z";
final String target = "/home/centos";
// final SCPFileTransfer ft = getSSHClient().newSCPFileTransfer();
final SFTPClient sftp = getSSHClient().newSFTPClient();
try {
// ft.upload(src, target);
sftp.put(new FileSystemFile(src), target);
} finally {
sftp.close();
}
```
I debug the process, the exception point is
`SFTPFileTransfer.Uploader.prepareFile`
seems the server closed the socked after first response but the client still waiting the inputstream.
Any Information? Thanks a lot.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.