hudson.util.IOException2: [ssh-agent] Unable to start agent

Jenkins JIRA | Allan BURDAJEWICZ | 6 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    h3. Issue Running Jenkins on PowerPC (ppc64le), when trying to use SSH-Agent we are getting below error: {code} [ssh-agent] Caused by: java.lang.UnsatisfiedLinkError: could not locate stub library in jar file. Tried [jni/unknown-Linux/libjffi-1.2.so, /jni/unknown-Linux/libjffi-1.2.so] [ssh-agent] at com.kenai.jffi.internal.StubLoader.getStubLibraryStream(StubLoader.java:353) [ssh-agent] at com.kenai.jffi.internal.StubLoader.loadFromJar(StubLoader.java:300) [ssh-agent] at com.kenai.jffi.internal.StubLoader.load(StubLoader.java:235) [ssh-agent] at com.kenai.jffi.internal.StubLoader.<clinit>(StubLoader.java:403) [ssh-agent] at java.lang.Class.forName0(Native Method) [ssh-agent] at java.lang.Class.forName(Class.java:348) [ssh-agent] at com.kenai.jffi.Init.load(Init.java:68) [ssh-agent] at com.kenai.jffi.Foreign$InstanceHolder.getInstanceHolder(Foreign.java:49) [ssh-agent] at com.kenai.jffi.Foreign$InstanceHolder.<clinit>(Foreign.java:45) [ssh-agent] ... 38 more FATAL: [ssh-agent] Unable to start agent hudson.util.IOException2: [ssh-agent] Unable to start agent at com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper.createSSHAgentEnvironment(SSHAgentBuildWrapper.java:253) at com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper.preCheckout(SSHAgentBuildWrapper.java:223) at jenkins.scm.SCMCheckoutStrategy.preCheckout(SCMCheckoutStrategy.java:76) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:528) at hudson.model.Run.execute(Run.java:1738) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:410) Caused by: java.lang.RuntimeException: [ssh-agent] Could not find a suitable ssh-agent provider. at com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper$SSHAgentEnvironment.<init>(SSHAgentBuildWrapper.java:371) at com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper.createSSHAgentEnvironment(SSHAgentBuildWrapper.java:246) {code} h3. Resolution It looks like version 2.0.3+ of _jnr-iff_ is where _ppc64le_ adds compatibility: * https://github.com/jnr/jnr-ffi/commit/6d8cdc0ce1a5d6dcfbec5c3b635bfe3232088273 So compatibility could be provided by upgrading the following dependencies: * https://github.com/cloudbees/jnr-unixsocket-nodep/blob/master/pom.xml#L83 * https://github.com/jenkinsci/ssh-agent-plugin/blob/master/pom.xml#L112

    Jenkins JIRA | 6 months ago | Allan BURDAJEWICZ
    hudson.util.IOException2: [ssh-agent] Unable to start agent

    Root Cause Analysis

    1. java.lang.RuntimeException

      [ssh-agent] Could not find a suitable ssh-agent provider.

      at com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper$SSHAgentEnvironment.<init>()
    2. com.cloudbees.jenkins
      SSHAgentBuildWrapper.createSSHAgentEnvironment
      1. com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper$SSHAgentEnvironment.<init>(SSHAgentBuildWrapper.java:371)
      2. com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper.createSSHAgentEnvironment(SSHAgentBuildWrapper.java:246)
      2 frames