"Please make sure you have the correct access rights
and the repository exists.
git did not exit cleanly (exit code 128) (1313 ms @ 2022/03/28 14:32:58)"
I get an error like this and can't clone.
Hi @hayato_nasu and welcome to the community.
I would like to ask a few questions so we can better help you:
1. Is the repo you are trying to clone hosted in Bitbucket Cloud (https://bitbucket.org/) or in Bitbucket Server (self-hosted instance)?
2. Are you cloning from a terminal application or from a Git GUI client?
3. What is the version of Git on this machine and also the operating system?
4. Are you able to clone any other Bitbucket repo you have access to or do you get the same error when cloning other Bitbucket repos as well? (This is to narrow down if the problem seems to be repo specific or not)
5. Could you please try cloning with the following command and attach the full output here?
GIT_TRACE_PACKET=1 GIT_TRACE=1 GIT_SSH_COMMAND="ssh -vvv" git clone <repo-url-here>
This command should give more verbose output. Please make sure to remove any private/sensitive data from the output prior to sharing.
Kind regards,
Theodora
Hi Theodora-san
Thank you for support.
I answer the questions.
1.I am trying to clone host in Bitbucket Cloud.
2.I am cloning from Git GUI client.
3.The version of Git is 2.8.0.
4.I get the same error with clones of other bitbucket repositories.
5.I don't know how to check this.
When I try to clone the repository I want to clone, I get the following error:
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
git did not exit cleanly (exit code 128) (1750 ms @ 2022/03/31 10:02:23)
Thank you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @hayato_nasu,
Thank you for the info.
My suggestions would be:
1. First, upgrade Git on your machine to the latest version
2. Then, navigate to the ~/.ssh directory on your machine. Create there a file named config and add the following in the file (if the file already exists, just add the following lines):
Host bitbucket.org
HostName bitbucket.org
PreferredAuthentications publickey
IdentityFile /Users/myUser/.ssh/id_rsa
Replace /Users/myUser/.ssh/id_rsa with the path to the private SSH key you are using for Bitbucket
3. Afterwards, use a command line application to clone a Bitbucket repository via SSH (e.g. the Terminal application in Linux/MacOS, or if you're on Windows you can use Git Bash).
Please let me know if this succeeds or fails
(this is to narrow down whether the problem is specific to the Git GUI client or not).
4. If the clone still fails, please clone again from the same command line application using the following command and attach the full output here (after removing any sensitive data from the output)
GIT_TRACE_PACKET=1 GIT_TRACE=1 GIT_SSH_COMMAND="ssh -vvv" git clone <repo-url-here>
Replace <repo-url-here> with the SSH URL of your repo.
Please feel free to let me know if you have any questions.
Kind regards,
Theodora
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.