You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by lye <li...@gmail.com> on 2015/03/23 20:29:33 UTC

SFTP connection issue with private key

Hi, Claus, Willem, and Camel friends,

I am writing a camel route that connects to, logs into and polls files from
a SFTP location with private key file. But when the application was deployed
to server and ran for the first time, it threw the following the exception
below. But when the app ran again a few hours later, it could connect and
work without any issues. But after 1 day, the same issue repeated. The first
connection failed and threw below exceptions, but the second run a few hours
later worked. From the production server, I could connect to the SFTP
without any problems, so there shouldn't be any credential issue. 

Please let me know if you have any idea how to resolve this issue. Much
appreciated!




Caused by: java.lang.UnsatisfiedLinkError: no NativeCreds in
java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1734)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1028)
at com.ibm.security.krb5.b.run(b.java)
at java.security.AccessController.doPrivileged(Native Method)
at com.ibm.security.krb5.Credentials.b(Credentials.java:455)
at
com.ibm.security.krb5.Credentials.getDefaultNativeCreds(Credentials.java:607)
at
com.ibm.security.krb5.Credentials.acquireDefaultCreds(Credentials.java:348)
at com.ibm.security.jgss.mech.krb5.cc.b(cc.java:379)
at com.ibm.security.jgss.mech.krb5.cc.b(cc.java:264)
at com.ibm.security.jgss.mech.krb5.cc.b(cc.java:125)
at com.ibm.security.jgss.mech.krb5.cc.<init>(cc.java:489)
at
com.ibm.security.jgss.mech.krb5.Krb5MechFactory.getCredentialElement(Krb5MechFactory.java:2)
at
com.ibm.security.jgss.GSSManagerImpl.createMechCredential(GSSManagerImpl.java:13)
at com.ibm.security.jgss.GSSCredentialImpl.add(GSSCredentialImpl.java:265)
at com.ibm.security.jgss.GSSCredentialImpl.<init>(GSSCredentialImpl.java:83)
at
com.ibm.security.jgss.GSSManagerImpl.createCredential(GSSManagerImpl.java:58)
at com.ibm.security.jgss.GSSContextImpl.b(GSSContextImpl.java:157)
at com.ibm.security.jgss.GSSContextImpl.<init>(GSSContextImpl.java:44)
at
com.ibm.security.jgss.GSSManagerImpl.createContext(GSSManagerImpl.java:24)
at com.jcraft.jsch.jgss.GSSContextKrb5.create(GSSContextKrb5.java:82)
at
com.jcraft.jsch.UserAuthGSSAPIWithMIC.start(UserAuthGSSAPIWithMIC.java:125)
at com.jcraft.jsch.Session.connect(Session.java:442)
at
org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:115)
at
org.apache.camel.component.file.remote.RemoteFileConsumer.connectIfNecessary(RemoteFileConsumer.java:154)
at
org.apache.camel.component.file.remote.RemoteFileConsumer.recoverableConnectIfNecessary(RemoteFileConsumer.java:133)
at
org.apache.camel.component.file.remote.RemoteFileConsumer.prePollCheck(RemoteFileConsumer.java:55)
at
org.apache.camel.component.file.GenericFileConsumer.poll(GenericFileConsumer.java:106)
at
org.apache.camel.impl.ScheduledPollConsumer.doRun(ScheduledPollConsumer.java:187)
... 10 more



--
View this message in context: http://camel.465427.n5.nabble.com/SFTP-connection-issue-with-private-key-tp5764665.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: SFTP connection issue with private key

Posted by lye <li...@gmail.com>.
Hi, Claus and Willem.

  Do you have any ideas? Any help will be appreciated!



--
View this message in context: http://camel.465427.n5.nabble.com/SFTP-connection-issue-with-private-key-tp5764665p5764706.html
Sent from the Camel - Users mailing list archive at Nabble.com.