Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,637,580
Community Members
 
Community Events
196
Community Groups

Suddenly unable to push to my Bitbucket repo

Hi there,

I have suddenly been unable to push changes to my Bitbucket repo. I get the following error:

```

git push origin dev
The requested repository either does not exist or you do not have access. If you believe this repository exists and you have access, make sure you're authenticated.
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

```

The repository exists and I am an admin on the repo.

I last successfully pushed to it on September 1st.

The correct SSH key is in my ssh agent. The same key that is added to my Bitbucket account.

`git config user.name` returns the correct Bitbucket user name.

`git remote -v` returns the correct SSH origin.

SSH test connection command returns successful.

```

ssh -T git@bitbucket.org
authenticated via ssh key.

You can use git to connect to Bitbucket. Shell access is disabled

```

I have restarted my IDE and terminal multiple times to try and fix it but I still get this error.

I have also killed my ssh-agent and restarted it, adding only the key I use for this repo. It still isn't working.

Is there anything else I can check to see what is wrong?

1 answer

1 accepted

1 vote
Answer accepted

I figured it out. Somehow the core.sshCommand config that held the SSH key that is used with this repo got wiped from the repo config. I don't know how that happened.

Running this command returned no output:

```

git config core.sshCommand

```

So I added the key back to the repo, setting the SSH config file option to /dev/null since I don't have any GIT related host entries in my ~/.ssh/config file.

 

```

git config core.sshCommand "ssh -i ~/.ssh/the-bitbucket-key -F /dev/null"

```

After that I was able to successfully push and pull again.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events