Hi John,
Thanks for the response.
Actually there is no exception. The read thread from the InputStream of Channel
returns -1 at the end of the SFTP file transfer (not always at times only).
Note the SFTP file transfer is different thread and just using the connected
Jsch session to transfer the file. Here I have attached the code where we are
reading from the Channel Input Stream.
in_ = channel_.getInputStream();
int nRead = in_.read(readBuf_);
if( nRead < 0 ) {
log.warning("SecureShellIO.read: EOF");
return -1;
}
So Intermittently at the end of SFTP transfer process, the nRead for the
terminal returns -1 (EOF). Since we detects -1 we are closing the entire
session assuming the EOF reached.
Can you please guide us to move forward.
Thanks,
Muthu.
--- On Thu, 1/29/09, Stote, John (RBC Dexia IS) <[email protected]>
wrote:
From: Stote, John (RBC Dexia IS) <[email protected]>
Subject: RE: [JSch-users] EOF error during SFTP file transfer
To: [email protected], [email protected],
[email protected], [email protected]
Date: Thursday, January 29, 2009, 2:29 AM
Stack trace ?
From: Muthu Ramakrishnan
[mailto:[email protected]]
Sent: Wednesday, 28 January
2009 23:54
To: [email protected]; [email protected];
[email protected]
Subject: [JSch-users] EOF error during SFTP file
transfer
Hi,
I am using Jsch 0.1.33. We have recently
implemented the SFTP file transfer functionality over the established
JSch
Session. The SFTP file transfer works fine. But some times, at the end of
the file transfer: we are receiving the EOF error at JSch session and the
entire session got disconnected because of this.
I am really not
sure how this file transfer impacts the already connected Jsch session,
further EOF error and crashes the entire session.
Can someone
please throw hint on this? We are in the final phase to release
this.
Thanks in
advance.
Muthu
____________________________________
This e-mail may be privileged and/or confidential, and the sender does not
waive any related rights and obligations. Any distribution, use or copying of
this e-mail or the information it contains by other than an intended
recipient(s) is unauthorized. If you received this e-mail in error, please
advise me (by return e-mail or otherwise) immediately and delete this e-mail.
The contents of any attachment to this e-mail may contain software
viruses or other defect which might affect your own computer system once
received or opened. While companies under RBC Dexia Investor Services Trust and
its affiliates take reasonable precautions to minimize that risk, we cannot
accept liability or responsibility for any damage or loss which may occur or be
sustained as a result of a software virus or other defect. You are responsible
for virus checks before opening any attachment.
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
JSch-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jsch-users