阿基米东 2022-05-27 17:04 采纳率: 100%
浏览 234
已结题

GitHub 无法读取远程仓库,port 443: Connection refused

~/.ssh/config 关于 GitHub 的配置如下:

Host github.com
    User luhuadong
    HostName ssh.github.com
    PreferredAuthentications publickey
    IdentityFile ~/.ssh/id_ed25519
    Port 443

之前一直可以用的,这几天突然就连接不了,fetch 和 push 都不行,如下:

$ git push origin main 
ssh: connect to host ssh.github.com port 443: Connection refused
fatal: 无法读取远程仓库。

请确认您有正确的访问权限并且仓库存在。

面是测试通过 HTTPS 端口的 SSH 是否可行的结果:

$ ssh -vT git@github.com
OpenSSH_8.2p1 Ubuntu-4ubuntu0.4, OpenSSL 1.1.1f  31 Mar 2020
debug1: Reading configuration data /home/rudy/.ssh/config
debug1: /home/rudy/.ssh/config line 15: Applying options for github.com
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug1: Connecting to ssh.github.com [::1] port 443.
debug1: connect to address ::1 port 443: Connection refused
debug1: Connecting to ssh.github.com [127.0.0.1] port 443.
debug1: connect to address 127.0.0.1 port 443: Connection refused
ssh: connect to host ssh.github.com port 443: Connection refused

请问是哪里的问题呢?有其他小伙伴遇到吗?

  • 写回答

2条回答 默认 最新

  • 阿基米东 嵌入式领域优质创作者 2022-05-30 14:40
    关注

    解决了,DNS 地址污染造成的!参考这里:https://segmentfault.com/a/1190000041909858

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

问题事件

  • 系统已结题 6月7日
  • 已采纳回答 5月30日
  • 创建了问题 5月27日

悬赏问题

  • ¥15 Stata链式中介效应代码修改
  • ¥15 latex投稿显示click download
  • ¥15 请问读取环境变量文件失败是什么原因?
  • ¥15 在若依框架下实现人脸识别
  • ¥15 网络科学导论,网络控制
  • ¥100 安卓tv程序连接SQLSERVER2008问题
  • ¥15 利用Sentinel-2和Landsat8做一个水库的长时序NDVI的对比,为什么Snetinel-2计算的结果最小值特别小,而Lansat8就很平均
  • ¥15 metadata提取的PDF元数据,如何转换为一个Excel
  • ¥15 关于arduino编程toCharArray()函数的使用
  • ¥100 vc++混合CEF采用CLR方式编译报错