Re: [JSch-users] Problem with connections closing intermittently during use
Status: Alpha
Brought to you by:
ymnk
From: <ym...@jc...> - 2010-06-21 21:49:55
|
Hi, +-From: Bradley Wagner <bra...@ha...> -- |_Date: Wed, 16 Jun 2010 11:45:28 -0400 _________________ | |I'm using the Jsch library to call a variety of SFTP commands: ls, |put, mkdir against an OpenSSH server (SSH-2.0-OpenSSH_5.2) on OS |X. |I keep a session open for a while and sometimes the session closes |while executing the "ls" command and I get the following stack |trace: |2010-06-16 11:41:41,157 ERROR [SFTPShuttle] : Error occurred when |invoking 'ls' command, error code: |4: |at com.jcraft.jsch.ChannelSftp._stat(ChannelSftp.java:1751) |at com.jcraft.jsch.ChannelSftp._stat(ChannelSftp.java:1758) |at com.jcraft.jsch.ChannelSftp.ls(ChannelSftp.java:1196) ... Which jsch version are you trying? And then, will that problem only occur the within ls method? How about enabling keepAlive? I mean that ... session.setServerAliveInterval(1000); session.connect(); ... Sincerely, -- Atsuhiko Yamanaka JCraft,Inc. 1-14-20 HONCHO AOBA-KU, SENDAI, MIYAGI 980-0014 Japan. Tel +81-22-723-2150 +1-415-578-3454 Skype callto://jcraft/ |