Hello, I would like to know if the ssh-slave plugin is supposed to work to run the slave agent on a Windows 10 node with Open SSH (Microsoft port)? I tried but I got some issues: 1/ the plugin assumes a command named *true* exists for the shell being executed (ok for bash but not for cmd, the shell being launched on Windows). A workaround is to create a true.bat file having the expected behaviour, e.g. @%COMSPEC% /C exit 1 >nul 2/ the plugin then tries to run the java command to determine Java version but, even if the java executable is in the Windows PATH, the plugin does not find it. Same workaround here: create a java.bat file that runs jave with an absolute path. 3/ The last problem I’m not able to solve is an exception during the launch of the slave agent (stacktrace below):
java.io.IOException: Unexpected termination of the channel Any idea of what could be wrong? Best regards, Christophe. StackTrace: [09/25/18 20:45:55] [SSH] Checking java version of java [09/25/18 20:45:56] [SSH] java -version returned 1.8.0_181. [09/25/18 20:45:56] [SSH] Starting sftp client. [09/25/18 20:45:56] [SSH] Copying latest slave.jar... [09/25/18 20:45:56] [SSH] Copied 745,674 bytes. Expanded the channel window size to 4MB [09/25/18 20:45:56] [SSH] Starting slave process: cd "c:\builds" && java -jar slave.jar <===[JENKINS REMOTING CAPACITY]===> ci@DESKTOP-IG838MJ c:\builds>"C:\Program Files (x86)\Common Files\Oracle\Java\javapath\java.exe" -jar slave.jar <===[JENKINS REMOTING CAPACITY]===>ERROR: Connection terminated ERROR: Unexpected error in launching a slave. This is probably a bug in Jenkins. hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected termination of the channel at hudson.remoting.Request.abort(Request.java:329) at hudson.remoting.Channel.terminate(Channel.java:992) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:96) Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to win10 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1693) at hudson.remoting.Request.call(Request.java:192) at hudson.remoting.Channel.call(Channel.java:907) at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:546) at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:413) at hudson.plugins.sshslaves.SSHLauncher.startSlave(SSHLauncher.java:1110) at hudson.plugins.sshslaves.SSHLauncher.access$500(SSHLauncher.java:148) at hudson.plugins.sshslaves.SSHLauncher$2.call(SSHLauncher.java:845) at hudson.plugins.sshslaves.SSHLauncher$2.call(SSHLauncher.java:820) 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 java.io.EOFException at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2675) at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3150) at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:859) at java.io.ObjectInputStream.<init>(ObjectInputStream.java:355) at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:48) 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) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:77) Caused by: java.io.EOFException at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2675) at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3150) at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:859) at java.io.ObjectInputStream.<init>(ObjectInputStream.java:355) at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:48) at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35) at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:63) -- 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 jenkinsci-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/4e0d62e3-e9d4-4393-a8a1-4e4db5938898%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.