Hi, Thank you all for taking the time to respond!
We have tried connecting to two different servers and we only get the problem on the original one. I have enabled logging and attached below the output from a simple connect+disconnect. The only difference I see is this exception from the server where we don't get the error: Logger 1: Caught an exception, leaving main loop due to Socket closed The SSHD where we do get the error is WinSSHD 4.23. Server where we get the error Logger 1: Connecting to x.x.x port 22 Logger 1: Connection established Logger 1: Remote version string: SSH-2.0-1.82 sshlib: WinSSHD 4.23 Logger 1: Local version string: SSH-2.0-JSCH-0.1.44 Logger 1: CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr, arcfour,arcfour128,arcfour256 Logger 1: SSH_MSG_KEXINIT sent Logger 1: SSH_MSG_KEXINIT received Logger 1: kex: server->client aes128-cbc hmac-md5 none Logger 1: kex: client->server aes128-cbc hmac-md5 none Logger 1: SSH_MSG_KEXDH_INIT sent Logger 1: expecting SSH_MSG_KEXDH_REPLY Logger 1: ssh_dss_verify: signature true Logger 2: Permanently added 'x.x.x' (DSA) to the list of known hosts. Logger 1: SSH_MSG_NEWKEYS sent Logger 1: SSH_MSG_NEWKEYS received Logger 1: SSH_MSG_SERVICE_REQUEST sent Logger 1: SSH_MSG_SERVICE_ACCEPT received Logger 1: Authentications that can continue: gssapi-with-mic,publickey,keyboard-interactive,password Logger 1: Next authentication method: gssapi-with-mic Logger 1: Authentications that can continue: publickey,keyboard-interactive,password Logger 1: Next authentication method: publickey Logger 1: Authentications that can continue: password Logger 1: Next authentication method: password Logger 1: Authentication succeeded (password). Logger 1: Disconnecting from x.x.x port 22 Server where we DO NOT get the error: Logger 1: Connecting to y.y.y port 22 Logger 1: Connection established Logger 1: Remote version string: SSH-2.0-OpenSSH_4.3 Logger 1: Local version string: SSH-2.0-JSCH-0.1.44 Logger 1: CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr, arcfour,arcfour128,arcfour256 Logger 1: SSH_MSG_KEXINIT sent Logger 1: SSH_MSG_KEXINIT received Logger 1: kex: server->client aes128-ctr hmac-md5 none Logger 1: kex: client->server aes128-ctr hmac-md5 none Logger 1: SSH_MSG_KEXDH_INIT sent Logger 1: expecting SSH_MSG_KEXDH_REPLY Logger 1: ssh_rsa_verify: signature true Logger 2: Permanently added 'y.y.y' (RSA) to the list of known hosts. Logger 1: SSH_MSG_NEWKEYS sent Logger 1: SSH_MSG_NEWKEYS received Logger 1: SSH_MSG_SERVICE_REQUEST sent Logger 1: SSH_MSG_SERVICE_ACCEPT received Logger 1: Authentications that can continue: gssapi-with-mic,publickey,keyboard-interactive,password Logger 1: Next authentication method: gssapi-with-mic Logger 1: Authentications that can continue: publickey,keyboard-interactive,password Logger 1: Next authentication method: publickey Logger 1: Authentications that can continue: password Logger 1: Next authentication method: password Logger 1: Authentication succeeded (password). Logger 1: Disconnecting from y.y.y port 22 Logger 1: Caught an exception, leaving main loop due to Socket closed Regards, Gustav On 3/18/11 2:25 PM, "David Walend" <david.wal...@mathworks.com> wrote: >Gustav, > >What's the sftp server you are trying to use? Are you hitting a variation >of https://bugzilla.mindrot.org/show_bug.cgi?id=1397 ? > >Good hunting, > >Dave > >> Message: 7 >> Date: Fri, 18 Mar 2011 10:32:20 +0000 >> From: Gustav Karlsson <gustav.karls...@bekk.no> >> Subject: [JSch-users] Unable to connect to SFTP server after 20 >> connects/disconnects >> To: "jsch-users@lists.sourceforge.net" >> <jsch-users@lists.sourceforge.net> >> Cc: Taral Seierstad <taral.seiers...@bekk.no> >> Message-ID: <c9a8f344.261c%gustav.karls...@bekk.no> >> Content-Type: text/plain; charset="us-ascii" >> >> Hi, >> >> We are experiencing an issue when using Jsch to connect to a SFTP- >> server. It seems like the sessions are not properly closed or cleared, >> resulting in a rejection from the SFTP server after 20 >> connects+disconnects. >> >> 1. Execute commands connect, cd, ls and disconnect on SFTP-server 20 >> times. (We disconnect both the channel and the session) >> 2. The next connect results in an exception. (connection through >> command-line sftp now returns an error "ssh_exchange_identification: >> Connection closed by remote host") >> 3. Wait ~30 min and connects will again be accepted. >> >> Has anyone experienced a similar issue and/or know the cause? >> Connecting 20+ times using the command-line SFTP-client does not result >> in this problem. >> >> Regards, >> Gustav Karlsson > >-------------------------------------------------------------------------- >---- >Colocation vs. Managed Hosting >A question and answer guide to determining the best fit >for your organization - today and in the future. >http://p.sf.net/sfu/internap-sfd2d >_______________________________________________ >JSch-users mailing list >JSch-users@lists.sourceforge.net >https://lists.sourceforge.net/lists/listinfo/jsch-users ------------------------------------------------------------------------------ Colocation vs. Managed Hosting A question and answer guide to determining the best fit for your organization - today and in the future. http://p.sf.net/sfu/internap-sfd2d _______________________________________________ JSch-users mailing list JSch-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jsch-users