title: jenkins complains host key verification failure although the key was generated
body: <pre><code>Error:
  Fetching upstream changes from git@github.com:....../.........git
      ERROR: Problem fetching from origin / origin - could be unavailable. Continuing anyway
      hudson.plugins.git.GitException: Error performing command: git fetch -t git@github.com:....../......git +refs/heads/*:refs/remotes/origin/*
      Command "git fetch -t git@github.com:...../......git +refs/heads/*:refs/remotes/origin/*" returned status code 128: Host key verification failed.
      fatal: The remote end hung up unexpectedly
  </code></pre>
  
  <p>My comments:</p>
  
  <ol>
  <li><p>I found that jenkins build fails when it executes </p>
  
  <pre><code>git fetch -t git@github.com:...../......git +refs/heads/*:refs/remotes/origin/*
  </code></pre></li>
  <li><p>I then pasted the same command on the command line it executes it successfully, weird!</p></li>
  <li><p>Executed the following to ensure the key works:</p>
  
  <pre><code>ssh -T git@github.com
  Hi [username]! You've successfully authenticated, but GitHub does not provide shell access.
  </code></pre>
  
  <p>Suggested in <a href="http://help.github.com/ssh-issues/" rel="nofollow noreferrer">http://help.github.com/ssh-issues/</a></p></li>
  <li><p>I did try to copy the generated private ssh key into the .ssh folder beneath Jenkins</p>
  
  <pre><code>cp -rf /root/.ssh /var/lib/jenkins/.ssh
  </code></pre>
  
  <p>and also copied the .gitconfig file into /var/lib/jenkins </p>
  
  <p>Suggested in: <a href="https://stackoverflow.com/questions/6103684/jenkins-fails-with-github-git-clone">Jenkins fails with github &quot;git clone&quot;</a></p></li>
  </ol>