Need to insert new SSH keys each day

Nenad Jovanovski December 27, 2017

Something strange is going on with my Sourcetree. Each day I need to generate new ssh keys otherwise I get 'permission denied' error. I need to manually delete the old ones from the ssh folder on my mac because if I just copy the old one and try to insert it again in bitbucket I get 'key already exists' error so it's not the key that it doesn't match but it's something else. 

1 answer

0 votes
bgannin
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
December 28, 2017

What version of Sourcetree are you using?

What OS are you running?

What is the output of ssh-add -l (does it contain the identities you expect)?

Nenad Jovanovski December 28, 2017
  • I am using the latest 2.6.3 version of Sourcetree
  • Running macOS High Sierra 10.13.2
  • That command returns: The agent has no identities.

I noticed that the problem happens once I close Sourcetree and then open it again. This is the error I get:

Screen Shot 2017-12-28 at 22.10.04.png

And then I check this:

Screen Shot 2017-12-28 at 22.11.02.png

I click copy to clipboard and then go to integrations> ssh in bitbucket and after I try to insert the key I get this:

Screen Shot 2017-12-28 at 22.11.51.png

So if I try to enter the key again I get that message so everything is ok with my key, nothing is modifying it.

To be able to fix this I need to manually remove the key from my ssh folder, generate new one and then add it to bitbucket. After that it works, until I close Sourcetree, and then again.

Nenad Jovanovski December 28, 2017

Actually nevermind I found the problem here: https://apple.stackexchange.com/questions/254468/macos-sierra-doesn-t-seem-to-remember-ssh-keys-between-reboots

The problem seems to be with my OS.

Like yevgenii likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events