How to configure SSH keys for GIT version control viewer?

I am unable to configure GIT version control viewer.

I am getting the following exception in the logs

2012-09-24 19:10:38,397 QuartzWorker-1 WARN ServiceRunner GitRevisionIndexerJob [xiplink.jira.git.GitManagerImpl]

org.eclipse.jgit.errors.TransportException: git@192.168.1.21:chandu: UnknownHostKey: 192.168.1.21. RSA key fingerprint is 00:35:ce:fd:b4:63:55:4b:fb:b0:9c:49:5b:22:38:3c

at org.eclipse.jgit.transport.JschConfigSessionFactory.getSession(JschConfigSessionFactory.java:141)

at org.eclipse.jgit.transport.SshTransport.getSession(SshTransport.java:121)

at org.eclipse.jgit.transport.TransportGitSsh$SshFetchConnection.<init>(TransportGitSsh.java:248)

at org.eclipse.jgit.transport.TransportGitSsh.openFetch(TransportGitSsh.java:147)

at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:127)

at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:113)

at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1062)

at com.xiplink.jira.git.GitManagerImpl.fetch(GitManagerImpl.java:457)

at com.xiplink.jira.git.revisions.RevisionIndexer.updateIndex(RevisionIndexer.java:282)

at com.xiplink.jira.git.revisions.RevisionIndexer.access$000(RevisionIndexer.java:49)

at com.xiplink.jira.git.revisions.RevisionIndexer$1.run(RevisionIndexer.java:191)

at com.xiplink.jira.git.revisions.RevisionIndexer.runAndCollectCounters(RevisionIndexer.java:170)

at com.xiplink.jira.git.revisions.RevisionIndexer.updateIndex(RevisionIndexer.java:200)

at com.xiplink.jira.git.revisions.RevisionIndexJob.execute(RevisionIndexJob.java:19)

at com.atlassian.sal.jira.scheduling.JiraPluginSchedulerService.run(JiraPluginSchedulerService.java:94)

at com.atlassian.jira.service.JiraServiceContainerImpl.run(JiraServiceContainerImpl.java:61)

at com.atlassian.jira.service.ServiceRunner.execute(ServiceRunner.java:47)

at org.quartz.core.JobRunShell.run(JobRunShell.java:195)

at com.atlassian.multitenant.quartz.MultiTenantThreadPool$MultiTenantRunnable.run(MultiTenantThreadPool.java:72)

at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)

Caused by: com.jcraft.jsch.JSchException: UnknownHostKey: 192.168.1.21. RSA key fingerprint is 00:35:ce:fd:b4:63:55:4b:fb:b0:9c:49:5b:22:38:3c

at com.jcraft.jsch.Session.checkHost(Session.java:757)

at com.jcraft.jsch.Session.connect(Session.java:321)

at org.eclipse.jgit.transport.JschConfigSessionFactory.getSession(JschConfigSessionFactory.java:116)

How can I resolve this?

3 answers

1 accepted

That's strange

Can you do these steps to provide me more information to solve your problem:

1. Add:

log4j.logger.com.xiplink.jira.git = DEBUG, console, file

to log4j.properties (this file is somewhere under you jira installation)

2. Restart Jira

3. Collect errors and send log file to support@bigbrassband.com

4. Also please add your Jira version, Git plugin version and OS used to run jira

Thanks

Try to do the following

  1. log as user which is used to run jira
  2. cd to git repository
  3. try to run git pull origin master
  4. answer yes to the prompts appear
  5. also make sure that no password is set for ssh keys

I tried git pull origin master in my GIT repository logging in as the user used to run Jira and it worked fine.

But when I am running reindex from GIT version control viewer,I am getting the same error (Unknown HOST key error).

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Bridget Sauer
Published Thursday in Marketplace Apps

Calling all developers––You're invited to Atlas Camp 2018

 Atlas Camp   is our developer event which will take place in Barcelona, Spain  from the 6th -7th of   September . This is a great opportunity to meet other developers and get n...

77 views 0 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you