[JSch-users] Re: PortForwardingL
Status: Alpha
Brought to you by:
ymnk
From: <ym...@jc...> - 2003-01-14 16:47:26
|
Hi, I received a bug report from Per Anderson, but his MTA has rejected my reply. So, I will write here. I hope he will read this e-mail. |Date: Mon, 13 Jan 2003 10:56:58 -0800 |Content-Type: text/plain; charset=US-ASCII; format=flowed |Subject: PortForwardingL |From: Per Anderson |To: su...@jc... |X-Scanned-By: MIMEDefang 2.21 (www . roaringpenguin . com / mimedefang) | |I'm using the PortForwardingL example code in a class to connect to |MySQL. Works great for all the queries exept when the ResultSet being |returned is large. Around 600 to 700 rows. The app just sits there |spinning it's wheels for up to an hour or so and then the server drops |the connection. Same thing whether I use compression or not. | |I'm baffled because this same ResultSet returned when accessing MySQL |without the port forwarding returns in about 30 seconds. All the other |smaller queries work fine and are fast using port forwarding. Is there |a limit to the size of the packet that can be returned when using the |port forwarding? | |Thanks for your help, It must be a bug. I had also recognized similar problem and tried to fix this glitch. Please try http://www.jcraft.com/jsch/jsch-0.0.12-rc1.zip You may not be interested in technical detailed reason of this problem, but I will write here for further reading. The client and server of ssh have their own fixed sized buffer area, which is called as "window" in the draft, to accept packets from other party. Before sending data packets, each party must check that other party's window has enough area and if not, data sending must be suspended. From my laziness, jsch-0.0.11 and early have not checked other party's window size. You will be able to reproduce this problem very easily by connecting to OpenSSH 2.* server, because its window size is very small. # For example, the widow size for X11-forwarding is 4kbytes on OpenSSH 2.*, # but it is defined as 64kbytes on OpenSSH 3.*. Of course, your problem may be caused by other bugs, if so please write me again. Thanks, -- ymnk |