1
votes

I am using Ubuntu 12.04

Kannan@Ubuntu:~/a/git pull

Permission denied (publickey).

fatal: The remote end hung up unexpectedly

How to resolve this issue. Please do let me know

2
did you register your ssh key with github?mnagel
What shows up when you do git remote -v?user2005477
Try going through this guide.user2005477

2 Answers

5
votes

I think this is due to ssh problem

Make sure whether your key is in the .ssh folder, if yes, then do the following one

Open ~/.bashrc & add

eval `ssh-agent -s`
ssh-add ~/.ssh/your_respective_key

and do bash on terminal and do git pull.I hope it will work

3
votes

You need to make sure the public key you've registered with Github is the one for the user doing the Git pull.

The Github guide for setting up keys is well laid out, and they have a linux version: https://help.github.com/articles/generating-ssh-keys#platform-linux

Make sure it's definitely the correct user's public key, and you have not included any whitespace at the end of the key - the key finishes at the end of your email address.

ssh-rsa 8f97gs89dfng746c74nyc7n478cb6ts746tb8746tbv9846cyb78
sjfghsfg43534639fb09bg0g098243hfjc0478tjwygjw85jywcyhwj9y598
dfhghuh3546ntnfgskjvgiu34b6t3== [email protected]
              That is the end of your key ----^