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

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日

悬赏问题

  • ¥100 三相直流充电模块对数字电源芯片在物理上它必须具备哪些功能和性能?
  • ¥30 数字电源对DSP芯片的具体要求
  • ¥20 antv g6 折线边如何变为钝角
  • ¥30 如何在Matlab或Python中 设置饼图的高度
  • ¥15 nginx中的CORS策略应该如何配置
  • ¥30 信号与系统实验:采样定理分析
  • ¥100 我想找人帮我写Python 的股票分析代码,有意请加mathtao
  • ¥20 Vite 打包的 Vue3 组件库,图标无法显示
  • ¥15 php 同步电商平台多个店铺增量订单和订单状态
  • ¥17 pro*C预编译“闪回查询”报错SCN不能识别