You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

WireGuard VPN服务器添加第二个客户端后无法访问互联网的问题求助

WireGuard VPN服务器添加第二个客户端后无法访问互联网的问题求助

大家好,我跟着不少指南总算搭好了一个可用的WireGuard VPN服务器,还成功连接了第一个客户端。但添加第二个客户端的时候遇到了麻烦——配置看起来都没问题,第一个客户端能正常访问互联网,第二个却只能和服务器完成握手,完全没有互联网流量传输。有没有大佬能帮忙分析下可能的原因?

服务器配置

[Interface]
Address = 1.1.1.1/24
SaveConfig = false
PreUp = iptables -t nat -A POSTROUTING -j MASQUERADE -o ens3
PreDown = iptables -t nat -D POSTROUTING -j MASQUERADE -o ens3
ListenPort = 49312
PrivateKey = ...

[Peer]
AllowedIPs = address.2/32
PublicKey = ...
PresharedKey = ...

[Peer]
AllowedIPs = address.3/32
PublicKey = ...
PresharedKey = ...

正常工作的Peer1配置

[Interface]
Address = address.2/32
PrivateKey = ...

[Peer]
Endpoint = my-ip:49312
AllowedIPs = 0.0.0.0/0
PublicKey = ...
PresharedKey = ...

无法访问互联网的Peer2配置

[Interface]
Address = address.3/32
PrivateKey = ...

[Peer]
Endpoint = my-ip:49312
AllowedIPs = 0.0.0.0/0
PublicKey = ...
PresharedKey = ...

我是不是哪里配置错了?还是有什么我没考虑到的细节?


备注:内容来源于stack exchange,提问作者Leteers

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.20 10:14:42