Connection refused error upon running GIT SSH operations after migrating or upgrading Bitbucket

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

  

要約

After upgrading and/or migrating Bitbucket, users cannot do GIT SSH operations (clone, push, etc) against Bitbucket.

環境

  • Bitbucket 7+
  • A reverse proxy in front of Bitbucket.

診断

The issue occurs for all users that use SSH. When connecting from another server a message that the connection is refused is thrown:

Connecting to bitbucketserver.com [192.168.1.2] port 7999.debug3: set_sock_tos: set socket 3 IP_TOS 0x48debug1: connect to address 192.168.1.2 port 7999: Connection refusedssh: connect to host bitbucketserver.com port 7999: Connection refusedfatal: Could not read from remote repository.Please make sure you have the correct access rightsand the repository exists.''

You may check the connection between the machine in which you are trying to GIT SSH and Bitbucket's server by running from the client machine:

telnet bitbucketserver.com 7999

The telnet tests the ability of the client to communicate with the Bitbucket server on the correct port and the output should be something like:

Trying <bitbucket_ssh_address>...
Connected to <bitbucket_ssh_address>.
Escape character is '^]'.

原因

An intermediary element such as a firewall is blocking the requests to the Bitbucket host server since that traffic is not allowed to that hostname/port from the client machine.

ソリューション

Consult your system admin/network team to ensure that communications out to Bitbcuket's IP/port are allowed and that there is no kind of networking/firewall-level block preventing traffic from going between Bitbucket and your client.

最終更新日 2022 年 4 月 17 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.