mirror of
https://github.com/snail007/goproxy.git
synced 2026-04-27 00:15:51 +03:00
[GH-ISSUE #422] HTTP代理访问Github会经常出现 Fastly error: unknown domain: github.com. #330
Labels
No labels
TODO
bug
duplicate
enhancement
good first issue
help wanted
helpful
invalid
need-confirm
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/goproxy#330
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @QLeelulu on GitHub (Apr 6, 2021).
Original GitHub issue: https://github.com/snail007/goproxy/issues/422
启动参数
访问 Github经常出现 :
访问 MongoDB 相关网站经常出现 :
从Chrome的控制台看出问题的都是 http2 请求:
当出现以上问题时,在Chrome里执行以下
Close idle sockets操作就可以暂时正常访问:@snail007 commented on GitHub (Apr 6, 2021):
反向代理不支持http2
@QLeelulu commented on GitHub (Apr 20, 2021):
@snail007 相当于正向代理用法,从我们的使用情况来看,是支持http2的,只是有几个网站(例如 github.com、mongodb.com)会出现这种情况
@mistyworm commented on GitHub (Jun 23, 2021):
我用socks代理,最近也出现github无法访问的情况,其它网站可以
@peasoft commented on GitHub (Jul 15, 2024):
出现这个问题的原因是
HTTP/2的多路复用将github.com这一未托管在 Fastly 上的网站传到了某个在 Fastly 上的子域名里。@snail007 说得对,直到目前仍没有一个反向代理是完美支持
HTTP/2的多路复用的。具体可以看 https://github.com/haproxy/haproxy/issues/2636我有一种很 Hacky 的做法能解决这个问题但是我先留着不说因为正好只有这些网站是使用泛域名证书的(github.com 主站没有用,但是子域名用了),而多路复用仅在多个网站证书相同时被使用。
Close idle sockets本质上就是强行让下一个请求“换一路”,所以那个上面那个 issue 给出的解决办法(也是最正常的解决办法)就是让反代检测到数据传输结束时不要keep-alive,而是立即断开连接。