I have a problem with my git, when I pull or push to repository of bitbucket. I always get this error:
fatal: unable to access ' https://myrepo@bitbucket.org/ ****/**': Failed to connect to bitbucket.org port 443: Connection timed out
I tried all solution but it can not resolved.
UPDATE: 28-08-2020
This is Temp fix but at least working for me after bitbucket new IP changed
Note:- hosts
file can be found in windows at C:\Windows\System32\drivers\etc
and in Linux it exists at /etc/hosts
. make sure you edit with admin rights ie in windows open notepad as administrator and then open host file. In Linux sudo gedit /etc/hosts
from the terminal from any location:)
just add the below line in hosts file
18.205.93.0 bitbucket.org
For all existing users who previously edited etc/hosts
file and now stopped working just replace the old IP address of bitbucket with new one ie in etc/hosts
REPLACE 104.192.143.3(old IP whatever) bitbucket.org
with
18.205.93.0 bitbucket.org
Happy Coding!
Recommendation 1: Just you need to remove your origin and set the origin again, then try to pull/push. Hopefully, it will work for you.
git remote -v
git remote remove origin
git remote add origin https://habibbd@bitbucket.org/softwarebd/mida-oss.git
Recommendation 2: Remove those of lines from Windows/System32/drivers/etc/hosts
file if anyone of these lines is available.
104.192.143.1 bitbucket.org
104.192.143.2 bitbucket.org
18.205.93.0 bitbucket.org
Recommendation 3: Change your network connection/provider. Sometimes your network provider causes this kind of issue.
Recommendation 4: Check firewall settings. Sometimes it was the issue for showing this kind of message.
Try upgrading git if you have the old version.
Check your git version:
$ git --version
Run the following to upgrade:
sudo add-apt-repository ppa:git-core/ppa
sudo apt-get update
sudo apt-get install git
Check if you require VPN and reconnect. That was the reason for me. After I reconnected to the VPN everything worked as normal.
First, you are not pushing to GitHub , but BitBucket .
Second, since BitBucket status seems OK, there must be a network or proxy or firewall issue on your side.
Regarding the proxy specifically:
~/gitconfig
file contentset a proxy in your environment variables:
export http_proxy=http://someuser:somepassword@192.168.1.1:80
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.