我有一台Vox3.0v
Vodafone 路由器。它似乎一直运行良好,直到我尝试在网络上使用树莓派。我可以通过 SSH 进入树莓派,但似乎无法从它访问任何 Web 服务器。特别是,我根本无法访问这个apt-get update
结果
sudo apt update -y
Err:1 http://archive.raspberrypi.org/debian bullseye InRelease
Could not connect to 145.239.85.58:9300 (145.239.85.58), connection timed out
Err:2 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
Could not connect to 145.239.85.58:9300 (145.239.85.58), connection timed out
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.
W: Failed to fetch http://raspbian.raspberrypi.org/raspbian/dists/bullseye/InRelease Could not connect to 145.239.85.58:9300 (145.239.85.58), connection timed out
W: Failed to fetch http://archive.raspberrypi.org/debian/dists/bullseye/InRelease Could not connect to 145.239.85.58:9300 (145.239.85.58), connection timed out
W: Some index files failed to download. They have been ignored, or old ones used instead.
使用curl
和进行调试时wget
,我发现必须https
在 url 中指定它才能工作(即google.com
超时而https://google.com
工作正常)。
DNS服务器设置为8.8.8.8
在路由器上,并在本地设备上。
dig
也没有提供更多细节
dig google.com
; <<>> DiG 9.16.33-Raspbian <<>> google.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 65524
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 512
;; QUESTION SECTION:
;google.com. IN A
;; ANSWER SECTION:
google.com. 175 IN A 142.250.187.206
;; Query time: 19 msec
;; SERVER: 8.8.8.8#53(8.8.8.8)
;; WHEN: Mon Oct 10 08:48:05 BST 2022
;; MSG SIZE rcvd: 55
但是,只要我添加我的桌面privoxy
作为代理服务器,它就可以正常工作。这就是为什么我相信是路由器与 pi 存在问题:
sudo apt update -y
Hit:1 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
Hit:2 http://archive.raspberrypi.org/debian bullseye InRelease
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.
http_proxy="http://192.168.1.19:8118" curl google.com
<HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8">
<TITLE>301 Moved</TITLE></HEAD><BODY>
<H1>301 Moved</H1>
The document has moved
<A HREF="http://www.google.com/">here</A>.
</BODY></HTML>
我可以进行其他调试来缩小这个问题吗?
====
编辑:tcpdump -i any not port 22
,然后复制/粘贴一个 TCP 流,从中wget google.com
以RST
... 结束,执行相同操作wget https://google.com
仍可成功完成。
No. Time Source Destination Protocol Length Info
137 73.203180 192.168.1.192 142.250.200.46 TCP 80 59346 → 80 [SYN] Seq=0 Win=64240 Len=0 MSS=1460 SACK_PERM TSval=1623844333 TSecr=0 WS=128
138 73.204775 142.250.200.46 192.168.1.192 TCP 80 80 → 59346 [SYN, ACK] Seq=0 Ack=1 Win=28960 Len=0 MSS=1460 SACK_PERM TSval=1140247999 TSecr=1623844333 WS=64
139 73.204826 192.168.1.192 142.250.200.46 TCP 72 59346 → 80 [ACK] Seq=1 Ack=1 Win=64256 Len=0 TSval=1623844335 TSecr=1140247999
140 73.205189 192.168.1.192 142.250.200.46 HTTP 195 GET / HTTP/1.1
141 73.423754 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623844554 TSecr=1140247999
142 73.643749 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623844774 TSecr=1140247999
143 74.073747 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623845204 TSecr=1140247999
144 74.204798 142.250.200.46 192.168.1.192 TCP 80 [TCP Retransmission] 80 → 59346 [SYN, ACK] Seq=0 Ack=1 Win=28960 Len=0 MSS=1460 SACK_PERM TSval=1140248999 TSecr=1623845204 WS=64
145 74.204839 192.168.1.192 142.250.200.46 TCP 72 [TCP Dup ACK 139#1] 59346 → 80 [ACK] Seq=124 Ack=1 Win=64256 Len=0 TSval=1623845335 TSecr=1140247999
146 74.983732 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623846114 TSecr=1140247999
147 76.204841 142.250.200.46 192.168.1.192 TCP 80 [TCP Retransmission] 80 → 59346 [SYN, ACK] Seq=0 Ack=1 Win=28960 Len=0 MSS=1460 SACK_PERM TSval=1140250999 TSecr=1623846114 WS=64
148 76.204881 192.168.1.192 142.250.200.46 TCP 72 [TCP Dup ACK 139#2] 59346 → 80 [ACK] Seq=124 Ack=1 Win=64256 Len=0 TSval=1623847335 TSecr=1140247999
149 76.743729 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623847874 TSecr=1140247999
155 80.183741 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623851314 TSecr=1140247999
156 80.204722 142.250.200.46 192.168.1.192 TCP 80 [TCP Retransmission] 80 → 59346 [SYN, ACK] Seq=0 Ack=1 Win=28960 Len=0 MSS=1460 SACK_PERM TSval=1140254999 TSecr=1623851314 WS=64
157 80.204764 192.168.1.192 142.250.200.46 TCP 72 [TCP Dup ACK 139#3] 59346 → 80 [ACK] Seq=124 Ack=1 Win=64256 Len=0 TSval=1623851335 TSecr=1140247999
159 87.553743 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623858684 TSecr=1140247999
160 88.204963 142.250.200.46 192.168.1.192 TCP 80 [TCP Retransmission] 80 → 59346 [SYN, ACK] Seq=0 Ack=1 Win=28960 Len=0 MSS=1460 SACK_PERM TSval=1140262999 TSecr=1623858684 WS=64
161 88.205022 192.168.1.192 142.250.200.46 TCP 72 [TCP Dup ACK 139#4] 59346 → 80 [ACK] Seq=124 Ack=1 Win=64256 Len=0 TSval=1623859335 TSecr=1140247999
167 101.623755 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623872754 TSecr=1140247999
189 104.244772 142.250.200.46 192.168.1.192 TCP 80 [TCP Retransmission] 80 → 59346 [SYN, ACK] Seq=0 Ack=1 Win=28960 Len=0 MSS=1460 SACK_PERM TSval=1140278999 TSecr=1623872754 WS=64
190 104.244831 192.168.1.192 142.250.200.46 TCP 72 [TCP Dup ACK 139#5] 59346 → 80 [ACK] Seq=124 Ack=1 Win=64256 Len=0 TSval=1623875375 TSecr=1140247999
204 129.143750 192.168.1.192 142.250.200.46 TCP 195 [TCP Retransmission] 59346 → 80 [PSH, ACK] Seq=1 Ack=1 Win=64256 Len=123 TSval=1623900274 TSecr=1140247999
211 165.074469 192.168.1.192 142.250.200.46 TCP 72 59346 → 80 [FIN, ACK] Seq=124 Ack=1 Win=64256 Len=0 TSval=1623936204 TSecr=1140247999
212 165.075820 142.250.200.46 192.168.1.192 TCP 66 80 → 59346 [RST] Seq=1 Win=0 Len=0
答案1
很高兴不是我遇到了沃达丰路由器的问题,它们实在太糟糕了!
我在 ISP 路由器的 DHCP 方面遇到了问题,大约 2 周前不得不重置。这个周末又出现了,所以我去了 Argos 并买了一个 TP-Link 路由器/调制解调器……功能更多,至少允许您访问默认 ssh 端口 22(被沃达丰的路由器阻止 - 为什么???)。似乎已经感觉好 10 倍了 - 我在扁平的 1gb 有线网络上使用 Unifi Lite 6 作为网状 Wi-Fi 系统。
您需要向他们请求 PPPOE 信息,这可以通过他们的在线聊天来完成。
值得一提的是,我有一个 Orange Pi(Mysterium Node)和运行 Unifi Controller 的 Raspberry pi(无法让 DHCP 正常工作),直到 Vodafone 路由器上出现 DHCP 问题之前都没有出现任何问题。
我认为如果保留默认设置,沃达丰路由器可能没有问题,但除此之外的任何设置,我认为他们没有能力应对。
如果这没有任何帮助,我很抱歉。