[
https://issues.apache.org/jira/browse/SSHD-795?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Goldstein Lyor resolved SSHD-795.
---------------------------------
Resolution: Fixed
Assignee: Goldstein Lyor
Fix Version/s: 1.8.0
> IOException (Broken pipe) on a socket local forwarding channel causes SSH
> client-server connection down
> -------------------------------------------------------------------------------------------------------
>
> Key: SSHD-795
> URL: https://issues.apache.org/jira/browse/SSHD-795
> Project: MINA SSHD
> Issue Type: Bug
> Affects Versions: 1.7.0
> Reporter: Roberto Deandrea
> Assignee: Goldstein Lyor
> Priority: Major
> Fix For: 1.8.0
>
> Attachments: apache-sshd.trace.zip, brokenpipe.trace
>
>
> Hi,
> I have a problem with local port forwarding mechanism implemented in Apache
> SSHD.
> In my company we successfully use Apache SSHD library for secure local socket
> forwarding protocols.
> When on a local port forwarding channel an IOException (Broken pipe) happen
> for some reason (network, etc...), the SSH client server is being
> disconnected abruptly.
> I'm not convinced this is the right behavior. I think it is not necessary to
> bring down SSH client server connection because this is not a protocol
> violation, but a socket problem related to forwarded remote server connection.
> Please, can you comment about this issue ?
> Follow an excerpt of the traces :
> {quote}
> 2018-01-23 10:30:10,017 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-2 ]
> [Nio2Session.handleWriteCycleFailure]
> handleWriteCycleFailure(Nio2Session[local=/192.168.180.70:38957,
> remote=/192.168.10.31:36228]) failed (IOException) to write 32768 bytes:
> Broken pipe
> 2018-01-23 10:30:10,017 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-3 ]
> [Window.waitForSpace]
> waitForSpace(Window[server/remote](TcpipServerChannel[id=662,
> recipient=11]-ServerSessionImpl[circessh@/192.168.190.2:14840])) available:
> 1146880
> 2018-01-23 10:30:10,017 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-2 ]
> [TcpipServerChannel.handleWriteDataFailure]
> handleWriteDataFailure(TcpipServerChannel[id=662,
> recipient=11]-ServerSessionImpl[circessh@/192.168.190.2:14840])[SSH_MSG_CHANNEL_DATA]
> failed (IOException) to write len=32768: Broken pipe
> 2018-01-23 10:30:10,018 WARN [sshd-SshServer[1786f9d5]-nio2-thread-2 ]
> [AbstractSession.exceptionCaught]
> exceptionCaught(ServerSessionImpl[circessh@/192.168.190.2:14840])[state=Opened]
> IOException: Broken pipe
> 2018-01-23 10:30:10,018 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-3 ]
> [Window.waitAndConsume]
> waitAndConsume(Window[server/remote](TcpipServerChannel[id=662,
> recipient=11]-ServerSessionImpl[circessh@/192.168.190.2:14840])) -
> requested=32768, available=1146880
> 2018-01-23 10:30:10,018 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-2 ]
> [AbstractSession.exceptionCaught]
> exceptionCaught(ServerSessionImpl[circessh@/192.168.190.2:14840])[state=Opened]
> details
> java.io.IOException: Broken pipe
> at sun.nio.ch.FileDispatcherImpl.write0(Native Method)
> at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:47)
> at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:93)
> at sun.nio.ch.IOUtil.write(IOUtil.java:65)
> at
> sun.nio.ch.UnixAsynchronousSocketChannelImpl.finishWrite(UnixAsynchronousSocketChannelImpl.java:582)
> at
> sun.nio.ch.UnixAsynchronousSocketChannelImpl.finish(UnixAsynchronousSocketChannelImpl.java:195)
> at
> sun.nio.ch.UnixAsynchronousSocketChannelImpl.onEvent(UnixAsynchronousSocketChannelImpl.java:213)
> at sun.nio.ch.EPollPort$EventHandlerTask.run(EPollPort.java:293)
> at java.lang.Thread.run(Thread.java:745)
> 2018-01-23 10:30:10,023 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-1 ]
> [Nio2Session.writePacket]
> writePacket(Nio2Session[local=/192.168.180.70:45470,
> remote=/192.168.10.31:22]) Writing 24780 bytes
> 2018-01-23 10:30:10,025 DEBUG [sshd-SshServer[1786f9d5]-nio2-thread-2 ]
> [SessionTimeoutListener.sessionException]
> sessionException(ServerSessionImpl[circessh@/192.168.190.2:14840])
> IOException: Broken pipe
> {quote}
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)