Windows client ssh connection error

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

Windows client ssh connection error

Jérôme Godbout

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB384483F6CB81201CD366EDFDCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.
Reply | Threaded
Open this post in threaded view
|

Re: Windows client ssh connection error

Ivan Fernandez Calvo
Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.
Reply | Threaded
Open this post in threaded view
|

Re: Windows client ssh connection error

Ivan Fernandez Calvo
when you enter on that Windows machine though SSH manually, Do you have a long banner at the beginning that you do not have in the other machine?

El martes, 1 de septiembre de 2020 a las 18:04:53 UTC+2, Ivan Fernandez Calvo escribió:
Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/1af4931f-cd2f-4688-8925-df4c194d6f8fn%40googlegroups.com.
Reply | Threaded
Open this post in threaded view
|

RE: Windows client ssh connection error

Jérôme Godbout

No nothing

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:20 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

when you enter on that Windows machine though SSH manually, Do you have a long banner at the beginning that you do not have in the other machine?

El martes, 1 de septiembre de 2020 a las 18:04:53 UTC+2, Ivan Fernandez Calvo escribió:

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/1af4931f-cd2f-4688-8925-df4c194d6f8fn%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38445F44149ADC2E83756325CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.
Reply | Threaded
Open this post in threaded view
|

RE: Windows client ssh connection error

Jérôme Godbout
In reply to this post by Ivan Fernandez Calvo

Yes, I created the folder and give the user (I made a local user for this called Jenkins). The user has full control over that folder. Does it require the user to be admin?

The following are created:

c:\JenkinsSlave\

                remoting.jar

                remoting\

                                jarCache\

                                                (empty)

                                logs\

                                                remoting.log.0

                                                …

                                                remoting.log.4 (all 0 kb file empty)

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:05 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38443935F4521E20F9BC52FFCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.
Reply | Threaded
Open this post in threaded view
|

RE: Windows client ssh connection error

Jérôme Godbout

Hi,

 

Is there any special requirements? (ssh does work from both Linux and Windows to this machine, also from the Jenkins master user account too). Seem like starting the slave fails, anything to do with firewall or something like that?

 

here the node that work (Windows 10 64 bits):

[09/01/20 09:26:41] [SSH] Checking java version of C:\Java\jdk1.8.0_261\/bin/java

[09/01/20 09:26:42] [SSH] C:\Java\jdk1.8.0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 09:26:42] [SSH] Starting sftp client.

[09/01/20 09:26:42] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 09:26:55] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\jdk1.8.0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

Sep 01, 2020 9:26:56 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 9:26:57 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>channel started

Remoting version: 4.3

This is a Windows agent

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SlaveListener call

INFO: Slave-status listener starting

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SocketHTTPListener waitForConnection

INFO: Slave-status listener ready on port 3141

[StartupTrigger] - Scanning jobs for node WindowsJG

Agent successfully connected and online

 

 

The one that doesn’t work (Windows 10 64 bits also, using the same Java jdk version):

[09/01/20 14:00:16] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java
[09/01/20 14:00:16] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.
[09/01/20 14:00:16] [SSH] Starting sftp client.
[09/01/20 14:00:16] [SSH] Copying latest remoting.jar...
[09/01/20 14:00:19] [SSH] Copied 1,522,833 bytes.
Expanded the channel window size to 4MB
[09/01/20 14:00:19] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache
<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir
INFO: Using c:\JenkinsSlave\remoting as a remoting work directory
Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager setupLogging
INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting
<===[JENKINS REMOTING CAPACITY]===>ERROR: Connection terminated
ERROR: java.io.IOException: Unexpected termination of the channel
java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
Caused: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.Request.abort(Request.java:340)
        at hudson.remoting.Channel.terminate(Channel.java:1081)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)
        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris
               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)
               at hudson.remoting.Request.call(Request.java:202)
               at hudson.remoting.Channel.call(Channel.java:997)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)
               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)
               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)
               at java.util.concurrent.FutureTask.run(FutureTask.java:266)
               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
               at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
Caused by: java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
[09/01/20 14:00:21] Launch failed - cleaning up connection
[09/01/20 14:00:21] [SSH] Connection closed.

 

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 12:40 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Yes, I created the folder and give the user (I made a local user for this called Jenkins). The user has full control over that folder. Does it require the user to be admin?

The following are created:

c:\JenkinsSlave\

                remoting.jar

                remoting\

                                jarCache\

                                                (empty)

                                logs\

                                                remoting.log.0

                                                …

                                                remoting.log.4 (all 0 kb file empty)

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:05 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38443935F4521E20F9BC52FFCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB3844B56E21C3BDE329CD79D5CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.
Reply | Threaded
Open this post in threaded view
|

RE: Windows client ssh connection error

Jérôme Godbout

Did try without the firewall and it doesn’t work either, !?!? Anyone got an idea what it is actually doing that might not work?!? Both machine are on the same network, no ip conflict. If I delete the remoting.jar and the folders into c:\JenkinsSlave it get created again, so the connection is happening and it can transfer the file.

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:05 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Hi,

 

Is there any special requirements? (ssh does work from both Linux and Windows to this machine, also from the Jenkins master user account too). Seem like starting the slave fails, anything to do with firewall or something like that?

 

here the node that work (Windows 10 64 bits):

[09/01/20 09:26:41] [SSH] Checking java version of C:\Java\jdk1.8.0_261\/bin/java

[09/01/20 09:26:42] [SSH] C:\Java\jdk1.8.0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 09:26:42] [SSH] Starting sftp client.

[09/01/20 09:26:42] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 09:26:55] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\jdk1.8.0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

Sep 01, 2020 9:26:56 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 9:26:57 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>channel started

Remoting version: 4.3

This is a Windows agent

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SlaveListener call

INFO: Slave-status listener starting

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SocketHTTPListener waitForConnection

INFO: Slave-status listener ready on port 3141

[StartupTrigger] - Scanning jobs for node WindowsJG

Agent successfully connected and online

 

 

The one that doesn’t work (Windows 10 64 bits also, using the same Java jdk version):

[09/01/20 14:00:16] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java
[09/01/20 14:00:16] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.
[09/01/20 14:00:16] [SSH] Starting sftp client.
[09/01/20 14:00:16] [SSH] Copying latest remoting.jar...
[09/01/20 14:00:19] [SSH] Copied 1,522,833 bytes.
Expanded the channel window size to 4MB
[09/01/20 14:00:19] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache
<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir
INFO: Using c:\JenkinsSlave\remoting as a remoting work directory
Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager setupLogging
INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting
<===[JENKINS REMOTING CAPACITY]===>ERROR: Connection terminated
ERROR: java.io.IOException: Unexpected termination of the channel
java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
Caused: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.Request.abort(Request.java:340)
        at hudson.remoting.Channel.terminate(Channel.java:1081)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)
        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris
               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)
               at hudson.remoting.Request.call(Request.java:202)
               at hudson.remoting.Channel.call(Channel.java:997)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)
               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)
               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)
               at java.util.concurrent.FutureTask.run(FutureTask.java:266)
               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
               at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
Caused by: java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
[09/01/20 14:00:21] Launch failed - cleaning up connection
[09/01/20 14:00:21] [SSH] Connection closed.

 

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 12:40 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Yes, I created the folder and give the user (I made a local user for this called Jenkins). The user has full control over that folder. Does it require the user to be admin?

The following are created:

c:\JenkinsSlave\

                remoting.jar

                remoting\

                                jarCache\

                                                (empty)

                                logs\

                                                remoting.log.0

                                                …

                                                remoting.log.4 (all 0 kb file empty)

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:05 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38443935F4521E20F9BC52FFCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB3844B56E21C3BDE329CD79D5CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38449E0F6506600BB89C8105CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.
Reply | Threaded
Open this post in threaded view
|

RE: Windows client ssh connection error

Jérôme Godbout

Maybe this unresolved issue is still there!?

https://issues.jenkins-ci.org/browse/JENKINS-48850

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:12 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Did try without the firewall and it doesn’t work either, !?!? Anyone got an idea what it is actually doing that might not work?!? Both machine are on the same network, no ip conflict. If I delete the remoting.jar and the folders into c:\JenkinsSlave it get created again, so the connection is happening and it can transfer the file.

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:05 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Hi,

 

Is there any special requirements? (ssh does work from both Linux and Windows to this machine, also from the Jenkins master user account too). Seem like starting the slave fails, anything to do with firewall or something like that?

 

here the node that work (Windows 10 64 bits):

[09/01/20 09:26:41] [SSH] Checking java version of C:\Java\jdk1.8.0_261\/bin/java

[09/01/20 09:26:42] [SSH] C:\Java\jdk1.8.0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 09:26:42] [SSH] Starting sftp client.

[09/01/20 09:26:42] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 09:26:55] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\jdk1.8.0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

Sep 01, 2020 9:26:56 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 9:26:57 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>channel started

Remoting version: 4.3

This is a Windows agent

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SlaveListener call

INFO: Slave-status listener starting

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SocketHTTPListener waitForConnection

INFO: Slave-status listener ready on port 3141

[StartupTrigger] - Scanning jobs for node WindowsJG

Agent successfully connected and online

 

 

The one that doesn’t work (Windows 10 64 bits also, using the same Java jdk version):

[09/01/20 14:00:16] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java
[09/01/20 14:00:16] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.
[09/01/20 14:00:16] [SSH] Starting sftp client.
[09/01/20 14:00:16] [SSH] Copying latest remoting.jar...
[09/01/20 14:00:19] [SSH] Copied 1,522,833 bytes.
Expanded the channel window size to 4MB
[09/01/20 14:00:19] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache
<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir
INFO: Using c:\JenkinsSlave\remoting as a remoting work directory
Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager setupLogging
INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting
<===[JENKINS REMOTING CAPACITY]===>ERROR: Connection terminated
ERROR: java.io.IOException: Unexpected termination of the channel
java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
Caused: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.Request.abort(Request.java:340)
        at hudson.remoting.Channel.terminate(Channel.java:1081)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)
        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris
               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)
               at hudson.remoting.Request.call(Request.java:202)
               at hudson.remoting.Channel.call(Channel.java:997)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)
               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)
               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)
               at java.util.concurrent.FutureTask.run(FutureTask.java:266)
               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
               at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
Caused by: java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
[09/01/20 14:00:21] Launch failed - cleaning up connection
[09/01/20 14:00:21] [SSH] Connection closed.

 

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 12:40 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Yes, I created the folder and give the user (I made a local user for this called Jenkins). The user has full control over that folder. Does it require the user to be admin?

The following are created:

c:\JenkinsSlave\

                remoting.jar

                remoting\

                                jarCache\

                                                (empty)

                                logs\

                                                remoting.log.0

                                                …

                                                remoting.log.4 (all 0 kb file empty)

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:05 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38443935F4521E20F9BC52FFCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB3844B56E21C3BDE329CD79D5CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38449E0F6506600BB89C8105CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB3844AD97075B0C398930F903CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.
Reply | Threaded
Open this post in threaded view
|

Re: Windows client ssh connection error

Ivan Fernandez Calvo
>Does it require the user to be admin?

no, a regular user should work if has access to the workdir 

>Maybe this unresolved issue is still there!?

this issue has a different stack trace and fails in another place. 

The issue here happens after the SSH connection when the remoting process tries to read from the stdin, there is nothing to read, and the remoting process exits. 

Do you have an antivirus enabled in that machine?

Did you check the SSHD service logs on your agent? try to increase the verbosity by setting LogLevel VERBOSE or LogLevel DEBUG1 on your /etc/ssh/sshd_config file and see Logging_and_Troubleshooting
Could you try to run the remoting commands manually from the Jenkins instance and see if the remoting process stars? 
ssh user@jenkins_agent "cd c:\JenkinsSlave && C:\Java\1_8_0_261\bin\java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave\remoting\jarCache"


El martes, 1 de septiembre de 2020 a las 20:26:20 UTC+2, Jérôme Godbout escribió:

Maybe this unresolved issue is still there!?

https://issues.jenkins-ci.org/browse/JENKINS-48850

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:12 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Did try without the firewall and it doesn’t work either, !?!? Anyone got an idea what it is actually doing that might not work?!? Both machine are on the same network, no ip conflict. If I delete the remoting.jar and the folders into c:\JenkinsSlave it get created again, so the connection is happening and it can transfer the file.

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:05 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Hi,

 

Is there any special requirements? (ssh does work from both Linux and Windows to this machine, also from the Jenkins master user account too). Seem like starting the slave fails, anything to do with firewall or something like that?

 

here the node that work (Windows 10 64 bits):

[09/01/20 09:26:41] [SSH] Checking java version of C:\Java\jdk1.8.0_261\/bin/java

[09/01/20 09:26:42] [SSH] C:\Java\jdk1.8.0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 09:26:42] [SSH] Starting sftp client.

[09/01/20 09:26:42] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 09:26:55] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\jdk1.8.0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

Sep 01, 2020 9:26:56 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 9:26:57 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>channel started

Remoting version: 4.3

This is a Windows agent

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SlaveListener call

INFO: Slave-status listener starting

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SocketHTTPListener waitForConnection

INFO: Slave-status listener ready on port 3141

[StartupTrigger] - Scanning jobs for node WindowsJG

Agent successfully connected and online

 

 

The one that doesn’t work (Windows 10 64 bits also, using the same Java jdk version):

[09/01/20 14:00:16] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java
[09/01/20 14:00:16] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.
[09/01/20 14:00:16] [SSH] Starting sftp client.
[09/01/20 14:00:16] [SSH] Copying latest remoting.jar...
[09/01/20 14:00:19] [SSH] Copied 1,522,833 bytes.
Expanded the channel window size to 4MB
[09/01/20 14:00:19] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache
<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir
INFO: Using c:\JenkinsSlave\remoting as a remoting work directory
Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager setupLogging
INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting
<===[JENKINS REMOTING CAPACITY]===>ERROR: Connection terminated
ERROR: java.io.IOException: Unexpected termination of the channel
java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
Caused: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.Request.abort(Request.java:340)
        at hudson.remoting.Channel.terminate(Channel.java:1081)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)
        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris
               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)
               at hudson.remoting.Request.call(Request.java:202)
               at hudson.remoting.Channel.call(Channel.java:997)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)
               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)
               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)
               at java.util.concurrent.FutureTask.run(FutureTask.java:266)
               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
               at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
Caused by: java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
[09/01/20 14:00:21] Launch failed - cleaning up connection
[09/01/20 14:00:21] [SSH] Connection closed.

 

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 12:40 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Yes, I created the folder and give the user (I made a local user for this called Jenkins). The user has full control over that folder. Does it require the user to be admin?

The following are created:

c:\JenkinsSlave\

                remoting.jar

                remoting\

                                jarCache\

                                                (empty)

                                logs\

                                                remoting.log.0

                                                …

                                                remoting.log.4 (all 0 kb file empty)

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:05 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38443935F4521E20F9BC52FFCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB3844B56E21C3BDE329CD79D5CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/3783f7bc-15ba-443b-ae8a-8bce89120a4fn%40googlegroups.com.
Reply | Threaded
Open this post in threaded view
|

RE: Windows client ssh connection error

Jérôme Godbout

Hi, for some obscure reason, the machine Window update were not totally up to date. Performing the all the update seem to have fix the issue. So it seem like old Windows 10 build aren’t working. Sorry for all the noise. Did try with and without the anti-virus, no difference. There was nothing meaningful into the master ssh.

 

Sorry could not test the manual ssh command since the machine was already into the process to perform the windows update…

 

Hope this help others, if they face the issue.

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 3:17 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

>Does it require the user to be admin?

 

no, a regular user should work if has access to the workdir 

 

>Maybe this unresolved issue is still there!?

 

this issue has a different stack trace and fails in another place. 

The issue here happens after the SSH connection when the remoting process tries to read from the stdin, there is nothing to read, and the remoting process exits. 

 

Do you have an antivirus enabled in that machine?

 

Did you check the SSHD service logs on your agent? try to increase the verbosity by setting LogLevel VERBOSE or LogLevel DEBUG1 on your /etc/ssh/sshd_config file and see Logging_and_Troubleshooting

Could you try to run the remoting commands manually from the Jenkins instance and see if the remoting process stars? 

ssh user@jenkins_agent "cd c:\JenkinsSlave && C:\Java\1_8_0_261\bin\java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave\remoting\jarCache"

 

 

El martes, 1 de septiembre de 2020 a las 20:26:20 UTC+2, Jérôme Godbout escribió:

Maybe this unresolved issue is still there!?

https://issues.jenkins-ci.org/browse/JENKINS-48850

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:12 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Did try without the firewall and it doesn’t work either, !?!? Anyone got an idea what it is actually doing that might not work?!? Both machine are on the same network, no ip conflict. If I delete the remoting.jar and the folders into c:\JenkinsSlave it get created again, so the connection is happening and it can transfer the file.

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 2:05 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Hi,

 

Is there any special requirements? (ssh does work from both Linux and Windows to this machine, also from the Jenkins master user account too). Seem like starting the slave fails, anything to do with firewall or something like that?

 

here the node that work (Windows 10 64 bits):

[09/01/20 09:26:41] [SSH] Checking java version of C:\Java\jdk1.8.0_261\/bin/java

[09/01/20 09:26:42] [SSH] C:\Java\jdk1.8.0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 09:26:42] [SSH] Starting sftp client.

[09/01/20 09:26:42] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 09:26:55] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\jdk1.8.0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

Sep 01, 2020 9:26:56 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 9:26:57 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>channel started

Remoting version: 4.3

This is a Windows agent

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SlaveListener call

INFO: Slave-status listener starting

Sep 01, 2020 9:27:00 AM com.youdevise.hudson.slavestatus.SocketHTTPListener waitForConnection

INFO: Slave-status listener ready on port 3141

[StartupTrigger] - Scanning jobs for node WindowsJG

Agent successfully connected and online

 

 

The one that doesn’t work (Windows 10 64 bits also, using the same Java jdk version):

[09/01/20 14:00:16] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java
[09/01/20 14:00:16] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.
[09/01/20 14:00:16] [SSH] Starting sftp client.
[09/01/20 14:00:16] [SSH] Copying latest remoting.jar...
[09/01/20 14:00:19] [SSH] Copied 1,522,833 bytes.
Expanded the channel window size to 4MB
[09/01/20 14:00:19] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache
<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir
INFO: Using c:\JenkinsSlave\remoting as a remoting work directory
Sep 01, 2020 2:00:19 PM org.jenkinsci.remoting.engine.WorkDirManager setupLogging
INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting
<===[JENKINS REMOTING CAPACITY]===>ERROR: Connection terminated
ERROR: java.io.IOException: Unexpected termination of the channel
java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
Caused: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.Request.abort(Request.java:340)
        at hudson.remoting.Channel.terminate(Channel.java:1081)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)
        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris
               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)
               at hudson.remoting.Request.call(Request.java:202)
               at hudson.remoting.Channel.call(Channel.java:997)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)
               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)
               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)
               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)
               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)
               at java.util.concurrent.FutureTask.run(FutureTask.java:266)
               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
               at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Unexpected termination of the channel
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)
Caused by: java.io.EOFException
        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)
        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)
        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)
        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)
        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)
        at hudson.remoting.Command.readFrom(Command.java:142)
        at hudson.remoting.Command.readFrom(Command.java:128)
        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)
[09/01/20 14:00:21] Launch failed - cleaning up connection
[09/01/20 14:00:21] [SSH] Connection closed.

 

 

From: [hidden email] <[hidden email]> On Behalf Of Jérôme Godbout
Sent: September 1, 2020 12:40 PM
To: [hidden email]
Subject: RE: Windows client ssh connection error

 

Yes, I created the folder and give the user (I made a local user for this called Jenkins). The user has full control over that folder. Does it require the user to be admin?

The following are created:

c:\JenkinsSlave\

                remoting.jar

                remoting\

                                jarCache\

                                                (empty)

                                logs\

                                                remoting.log.0

                                                …

                                                remoting.log.4 (all 0 kb file empty)

 

From: [hidden email] <[hidden email]> On Behalf Of Ivan Fernandez Calvo
Sent: September 1, 2020 12:05 PM
To: Jenkins Users <[hidden email]>
Subject: Re: Windows client ssh connection error

 

Has the user that connect permissions on c:\JenkinsSlave? Is the folder c:\JenkinsSlave\remoting created? Are there some err_pid* files or log files in c:\JenkinsSlave folder?

El martes, 1 de septiembre de 2020 a las 17:48:39 UTC+2, Jérôme Godbout escribió:

Hi,

 

I did solve my issue with the ssh agent I had earlier, but when I try to do the same on another Windows client machine I get this weird error below. The log on the slave are empty (c:\JenkinsSlave\remoting). The error is a bit vague and I have no clue what is wrong. I can connect with ssh, I also did it on the master node to approve the address to ensure it was not an issue. Seem like the exchange stream are breaking down!?! what is going on?

 

[09/01/20 11:33:18] [SSH] Checking java version of C:\Java\1_8_0_261\/bin/java

[09/01/20 11:33:19] [SSH] C:\Java\1_8_0_261\/bin/java -version returned 1.8.0_261.

[09/01/20 11:33:19] [SSH] Starting sftp client.

[09/01/20 11:33:19] [SSH] Copying latest remoting.jar...

Source agent hash is E5FEC468D6F172BF394E1F2571EA686C. Installed agent hash is E5FEC468D6F172BF394E1F2571EA686C

Verified agent jar. No update is necessary.

Expanded the channel window size to 4MB

[09/01/20 11:33:35] [SSH] Starting agent process: cd "c:\JenkinsSlave" && C:\Java\1_8_0_261\/bin/java  -jar remoting.jar -workDir c:\JenkinsSlave -jar-cache c:\JenkinsSlave/remoting/jarCache

<===[JENKINS REMOTING CAPACITY]===>Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir

INFO: Using c:\JenkinsSlave\remoting as a remoting work directory

Sep 01, 2020 11:33:35 AM org.jenkinsci.remoting.engine.WorkDirManager setupLogging

INFO: Both error and output logs will be printed to c:\JenkinsSlave\remoting

<===[JENKINS REMOTING CAPACITY]===>Exception in thread "main" java.io.EOFException: unexpected stream termination

        at hudson.remoting.ChannelBuilder.negotiate(ChannelBuilder.java:415)

        at hudson.remoting.ChannelBuilder.build(ChannelBuilder.java:360)

        at hudson.remoting.Launcher.main(Launcher.java:770)

        at hudson.remoting.Launcher.runWithStdinStdout(Launcher.java:718)

        at hudson.remoting.Launcher.run(Launcher.java:398)

        at hudson.remoting.Launcher.main(Launcher.java:298)

ERROR: ERROR: Connection terminated

java.io.IOException: Unexpected termination of the channel

java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

Caused: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.Request.abort(Request.java:340)

        at hudson.remoting.Channel.terminate(Channel.java:1081)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:94)

        Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to KeilDellGris

               at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1788)

               at hudson.remoting.Request.call(Request.java:202)

               at hudson.remoting.Channel.call(Channel.java:997)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:642)

               at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:424)

               at hudson.plugins.sshslaves.SSHLauncher.startAgent(SSHLauncher.java:623)

               at hudson.plugins.sshslaves.SSHLauncher.access$400(SSHLauncher.java:112)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:457)

               at hudson.plugins.sshslaves.SSHLauncher$1.call(SSHLauncher.java:422)

               at java.util.concurrent.FutureTask.run(FutureTask.java:266)

               at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)

               at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)

               at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: Unexpected termination of the channel

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77)

Caused by: java.io.EOFException

        at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2681)

        at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3156)

        at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:862)

        at java.io.ObjectInputStream.<init>(ObjectInputStream.java:358)

        at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:49)

        at hudson.remoting.Command.readFrom(Command.java:142)

        at hudson.remoting.Command.readFrom(Command.java:128)

        at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)

        at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63)

[09/01/20 11:33:37] Launch failed - cleaning up connection

[09/01/20 11:33:37] [SSH] Connection closed.

 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/0dc7e0f8-a8c3-42b7-8822-5b2da5bcf9a2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB38443935F4521E20F9BC52FFCD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB3844B56E21C3BDE329CD79D5CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/3783f7bc-15ba-443b-ae8a-8bce89120a4fn%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/QB1PR01MB384469C1D1A20C1325D125E7CD2E0%40QB1PR01MB3844.CANPRD01.PROD.OUTLOOK.COM.