致命:无法访问 <link> getaddrinfo() 线程未能启动
fatal: unable to access <link> getaddrinfo() thread failed to start
当我输入:git push origin master
错误:
fatal: unable to access 'https://github.com/<github-username>/<repository-name>.git/': getaddrinfo() thread failed to start
我该怎么办?
我遇到了同样的问题,我尝试了多种解决方案,直到发现在我的情况下是防火墙问题。我的是 "Free Firewall",我注意到即使授权软件和连接,仍然无法连接到远程存储库。我禁用了也没有解决,只有卸载了才解决问题,可以正常使用了Git
如果您的系统中安装了任何防病毒软件或防火墙,请关闭 git 访问或完全卸载并重新启动。我遇到了同样的问题并卸载了防火墙。效果很好。
我的机器上有同样的问题(git 版本 2.28.0.windows.1)。
问题似乎与 HTTP-requests:
的 DNS 解析有关
这是我原来的遥控器url:
git remote set-url origin http://<FQDN>:<http_port>/<repository>.git
与问题相同的结果:
$ git pull
fatal: unable to access 'http://<FQDN>:<http_port>/<repository>.git/': getaddrinfo() thread failed to start
将 URL 更改为解析的 IP 时:
$ ahost <FQDN>
<FQDN> <IP>
$ git remote set-url origin http://<IP>:<http_port>/<repository>.git
Git 连接没有问题:
$ git pull
Already up to date.
此外,当使用 SSH 而不是 HTTP 时,分辨率没有问题:
$ git remote set-url origin ssh://<username>@<FQDN>:<ssh_port>/<repository>.git
$ git pull
Already up to date.
Curl 在我的 MINGW64 环境中也不起作用:
$ ahost www.google.com
www.google.com 172.217.2.100
$ adig www.google.com
id: 64322
flags: qr rd ra
opcode: QUERY
rcode: NOERROR
Questions:
www.google.com . A
Answers:
www.google.com . 49 A 172.217.2.100
NS records:
Additional records:
$ curl www.google.com -v
* getaddrinfo() thread failed to start
* Couldn't resolve host 'www.google.com'
* Closing connection 0
curl: (6) getaddrinfo() thread failed to start
fatal: unable to access <link> getaddrinfo() thread failed to start
显示此错误表示您的电脑防火墙不允许进行此类操作
所以只需从您的系统和防病毒软件中禁用它,然后正常使用您的 git。
希望对你有用。
当我输入:git push origin master
错误:
fatal: unable to access 'https://github.com/<github-username>/<repository-name>.git/': getaddrinfo() thread failed to start
我该怎么办?
我遇到了同样的问题,我尝试了多种解决方案,直到发现在我的情况下是防火墙问题。我的是 "Free Firewall",我注意到即使授权软件和连接,仍然无法连接到远程存储库。我禁用了也没有解决,只有卸载了才解决问题,可以正常使用了Git
如果您的系统中安装了任何防病毒软件或防火墙,请关闭 git 访问或完全卸载并重新启动。我遇到了同样的问题并卸载了防火墙。效果很好。
我的机器上有同样的问题(git 版本 2.28.0.windows.1)。 问题似乎与 HTTP-requests:
的 DNS 解析有关这是我原来的遥控器url:
git remote set-url origin http://<FQDN>:<http_port>/<repository>.git
与问题相同的结果:
$ git pull
fatal: unable to access 'http://<FQDN>:<http_port>/<repository>.git/': getaddrinfo() thread failed to start
将 URL 更改为解析的 IP 时:
$ ahost <FQDN>
<FQDN> <IP>
$ git remote set-url origin http://<IP>:<http_port>/<repository>.git
Git 连接没有问题:
$ git pull
Already up to date.
此外,当使用 SSH 而不是 HTTP 时,分辨率没有问题:
$ git remote set-url origin ssh://<username>@<FQDN>:<ssh_port>/<repository>.git
$ git pull
Already up to date.
Curl 在我的 MINGW64 环境中也不起作用:
$ ahost www.google.com
www.google.com 172.217.2.100
$ adig www.google.com
id: 64322
flags: qr rd ra
opcode: QUERY
rcode: NOERROR
Questions:
www.google.com . A
Answers:
www.google.com . 49 A 172.217.2.100
NS records:
Additional records:
$ curl www.google.com -v
* getaddrinfo() thread failed to start
* Couldn't resolve host 'www.google.com'
* Closing connection 0
curl: (6) getaddrinfo() thread failed to start
fatal: unable to access <link> getaddrinfo() thread failed to start
显示此错误表示您的电脑防火墙不允许进行此类操作 所以只需从您的系统和防病毒软件中禁用它,然后正常使用您的 git。 希望对你有用。