[JIRA] (JENKINS-36841) ERROR: CVS Authentication failed: null. But selected ssh as protocol

41 views
Skip to first unread message

preejith@ubq.in (JIRA)

unread,
Jul 21, 2016, 3:02:01 AM7/21/16
to jenkinsc...@googlegroups.com
preejith vv created an issue
 
Jenkins / Bug JENKINS-36841
ERROR: CVS Authentication failed: null. But selected ssh as protocol
Issue Type: Bug Bug
Assignee: Unassigned
Components: cvs-plugin
Created: 2016/Jul/21 7:01 AM
Environment: Windows7
Priority: Major Major
Reporter: preejith vv

Repository url configured in project
CVSROOT=:ssh:pree...@172.16.0.2:22/repository
CVS root given in configure system (CVS section): :ssh:@172.16.0.2:22/repository
CVS server is Redhat Linux.

Building in workspace C:\Program Files (x86)\Jenkins\workspace\new test
Using globally configured password for connection to ':ext:172.16.0.2:22/repository' with username 'preejith'
cvs checkout -P -r outreach-ep-motherdairy-phase2-dev -d outreachEnterprise-proj-MD outreachEnterprise-proj
ERROR: CVS Authentication failed: null
org.netbeans.lib.cvsclient.connection.AuthenticationException: SSH connection failed.
at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:141)
at org.netbeans.lib.cvsclient.Client$1.run(Client.java:374)
at java.lang.Thread.run(Unknown Source)
Caused by: com.jcraft.jsch.JSchException: java.io.FileNotFoundException: C:\Windows\System32\config\systemprofile\ssh\id_rsa (The system cannot find the path specified)
at com.jcraft.jsch.KeyPair.load(KeyPair.java:524)
at com.jcraft.jsch.IdentityFile.newInstance(IdentityFile.java:40)
at com.jcraft.jsch.JSch.addIdentity(JSch.java:389)
at com.jcraft.jsch.JSch.addIdentity(JSch.java:370)
at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:135)
... 2 more
Caused by: java.io.FileNotFoundException: C:\Windows\System32\config\systemprofile\ssh\id_rsa (The system cannot find the path specified)
at java.io.FileInputStream.open0(Native Method)
at java.io.FileInputStream.open(Unknown Source)
at java.io.FileInputStream.<init>(Unknown Source)
at java.io.FileInputStream.<init>(Unknown Source)
at com.jcraft.jsch.Util.fromFile(Util.java:492)
at com.jcraft.jsch.KeyPair.load(KeyPair.java:521)
... 6 more
ERROR: Cvs task failed
Finished: FAILURE

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

preejith@ubq.in (JIRA)

unread,
Jul 21, 2016, 3:05:01 AM7/21/16
to jenkinsc...@googlegroups.com
preejith vv commented on Bug JENKINS-36841
 
Re: ERROR: CVS Authentication failed: null. But selected ssh as protocol

CVS Client (Plugin) : Version 2.12
Jenkin version : 2.6
JDK : 7

mikhirev@gmail.com (JIRA)

unread,
Aug 31, 2016, 11:57:01 AM8/31/16
to jenkinsc...@googlegroups.com

I experience the same issue on linux. I use 'yet another docker plugin' to provision slaves.

Using locally configured password for connection to :ext:user@chost:/CVS
cvs checkout -P -N -D 31 Aug 2016 15:35:06 +0000 project
ERROR: CVS Authentication failed: null
org.netbeans.lib.cvsclient.connection.AuthenticationException: SSH connection failed.
	at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:141)
	at org.netbeans.lib.cvsclient.Client$1.run(Client.java:374)
	at java.lang.Thread.run(Thread.java:745)
Caused by: com.jcraft.jsch.JSchException: java.io.FileNotFoundException: /var/jenkins_home/.ssh/id_rsa (No such file or directory)
	at com.jcraft.jsch.KeyPair.load(KeyPair.java:524)
	at com.jcraft.jsch.IdentityFile.newInstance(IdentityFile.java:40)
	at com.jcraft.jsch.JSch.addIdentity(JSch.java:389)
	at com.jcraft.jsch.JSch.addIdentity(JSch.java:370)
	at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:135)
	... 2 more
Caused by: java.io.FileNotFoundException: /var/jenkins_home/.ssh/id_rsa (No such file or directory)
	at java.io.FileInputStream.open0(Native Method)
	at java.io.FileInputStream.open(FileInputStream.java:195)
	at java.io.FileInputStream.<init>(FileInputStream.java:138)
	at java.io.FileInputStream.<init>(FileInputStream.java:93)
	at com.jcraft.jsch.Util.fromFile(Util.java:492)
	at com.jcraft.jsch.KeyPair.load(KeyPair.java:521)
	... 6 more
ERROR: Cvs task failed

Of course there's no /var/jenkins_home directory on slave.

mikhirev@gmail.com (JIRA)

unread,
Aug 31, 2016, 11:58:02 AM8/31/16
to jenkinsc...@googlegroups.com
Dmitry Mikhirev edited a comment on Bug JENKINS-36841
I experience the same issue on linux. I use 'yet another docker plugin' to provision slaves.

{noformat}
Using locally configured password for connection to :ext:user@
chost host :/CVS

cvs checkout -P -N -D 31 Aug 2016 15:35:06 +0000 project
ERROR: CVS Authentication failed: null
org.netbeans.lib.cvsclient.connection.AuthenticationException: SSH connection failed.
at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:141)
at org.netbeans.lib.cvsclient.Client$1.run(Client.java:374)
at java.lang.Thread.run(Thread.java:745)
Caused by: com.jcraft.jsch.JSchException: java.io.FileNotFoundException: /var/jenkins_home/.ssh/id_rsa (No such file or directory)
at com.jcraft.jsch.KeyPair.load(KeyPair.java:524)
at com.jcraft.jsch.IdentityFile.newInstance(IdentityFile.java:40)
at com.jcraft.jsch.JSch.addIdentity(JSch.java:389)
at com.jcraft.jsch.JSch.addIdentity(JSch.java:370)
at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:135)
... 2 more
Caused by: java.io.FileNotFoundException: /var/jenkins_home/.ssh/id_rsa (No such file or directory)
at java.io.FileInputStream.open0(Native Method)
at java.io.FileInputStream.open(FileInputStream.java:195)
at java.io.FileInputStream.<init>(FileInputStream.java:138)
at java.io.FileInputStream.<init>(FileInputStream.java:93)
at com.jcraft.jsch.Util.fromFile(Util.java:492)
at com.jcraft.jsch.KeyPair.load(KeyPair.java:521)
... 6 more
ERROR: Cvs task failed
{noformat}

Of course there's no /var/jenkins_home directory on slave.

mikhirev@gmail.com (JIRA)

unread,
Aug 31, 2016, 12:21:03 PM8/31/16
to jenkinsc...@googlegroups.com
Dmitry Mikhirev edited a comment on Bug JENKINS-36841
I experience the same issue on linux. I use 'yet another docker plugin' to provision slaves.

{noformat}
Using locally configured password for connection to :ext:user@host:/CVS

cvs checkout -P -N -D 31 Aug 2016 15:35:06 +0000 project
ERROR: CVS Authentication failed: null
org.netbeans.lib.cvsclient.connection.AuthenticationException: SSH connection failed.
at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:141)
at org.netbeans.lib.cvsclient.Client$1.run(Client.java:374)
at java.lang.Thread.run(Thread.java:745)
Caused by: com.jcraft.jsch.JSchException: java.io.FileNotFoundException: /var/jenkins_home/.ssh/id_rsa (No such file or directory)
at com.jcraft.jsch.KeyPair.load(KeyPair.java:524)
at com.jcraft.jsch.IdentityFile.newInstance(IdentityFile.java:40)
at com.jcraft.jsch.JSch.addIdentity(JSch.java:389)
at com.jcraft.jsch.JSch.addIdentity(JSch.java:370)
at org.netbeans.lib.cvsclient.connection.SSHConnection.open(SSHConnection.java:135)
... 2 more
Caused by: java.io.FileNotFoundException: /var/jenkins_home/.ssh/id_rsa (No such file or directory)
at java.io.FileInputStream.open0(Native Method)
at java.io.FileInputStream.open(FileInputStream.java:195)
at java.io.FileInputStream.<init>(FileInputStream.java:138)
at java.io.FileInputStream.<init>(FileInputStream.java:93)
at com.jcraft.jsch.Util.fromFile(Util.java:492)
at com.jcraft.jsch.KeyPair.load(KeyPair.java:521)
... 6 more
ERROR: Cvs task failed
{noformat}
Of course there's no /var/jenkins_home directory on slave. There's also no such a directory on master since jenkins home directory is located in another path.
The best solution would be to use jenkins credentials and do not look for id_rsa in filesystem.

mikhirev@gmail.com (JIRA)

unread,
Aug 31, 2016, 12:32:03 PM8/31/16
to jenkinsc...@googlegroups.com

mikhirev@gmail.com (JIRA)

unread,
Aug 31, 2016, 12:54:01 PM8/31/16
to jenkinsc...@googlegroups.com

Well, I figured out that this path can be changed in configuration. Although setting the default value to '~/.ssh/id_rsa' would be more robust. Also using credentials is much more convenient than looking for key in filesystem.

Reply all
Reply to author
Forward
0 new messages