SFTP问题排查 java.io.IOException: Pipe closed

又是一个线上问题,排查的时间不算长,但是由于日志体现不出来,因此不敢确认是不是sftp的问题,也算是经验记录一下

错误日志:(由于日志打印不是特别规范,描述一下大概的错误信息,主要是这两行)

java.io.IOException: Pipe closed
com.jcraft.jsch.ChannelSftp.start(ChannelSftp.java:315)

排查过程:

  1. 查看是不是远程服务器不通或者sftp功能未开启
    ping xx.xx.x.xtelnet xx.xx.x.x 22
    发现都能通
  2. 手动检查sftp是否可用
    sftp [email protected] 然后输入密码
    该过程发现sftp无法登录
[user@xxxx xxx]$ sftp [email protected]
The authenticity of host 'xx.xx.x.62 (xx.xx.x.62)' can't be established.
ECDSA key fingerprint is SHA256:xEJcjbTcbm1UXBVxr4JpQQ41DDBoyDN1eBa3XNWwQhk.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'xx.xx.x.62' (ECDSA) to the list of known hosts.
[email protected]'s password: 
Connection closed.  
Connection closed

经过和运维同事沟通发现是sftp账号的密码有问题

你可能感兴趣的:(记录,Linux)