Magisk-Modules-Repo / v2ray

v2ray core
328 stars 86 forks source link

国内访问正常,国外无法访问 #6

Open freerhine opened 5 years ago

freerhine commented 5 years ago

以下是我的配置和日志 我只更改了outbound部分 如果用v2rayng访问是正常的 "outbounds": [{ "protocol": "vmess", "settings": { "vnext": [ { "address": "自己的ip", "port": 17845, "users": [ { "id": “自己的uid", "alterId": 64 } ] } ] }, "streamSettings": { "network": "mkcp", "kcpSettings": { "uplinkCapacity": 5, "downlinkCapacity": 100, "congestion": true, "header": { "type": "none" } } }, "tag": "proxy" },

以下是service.log V2Ray 4.18.0 (Po) 20190228 A unified platform for anti-censorship. Configuration OK. [Info]: Starting v2ray service. [Info]: v2ray service is running. ( PID: 9608 ) [Info]: Clean nat proxy iptables rules. [Info]: Create proxy iptables chains. [Info]: Proxy all APP's TCP network. [Info]: Proxy softap0 WiFi guest's TCP network. [Info]: Block illegal visit.

以下是debug

sjz123321 commented 5 years ago

同样的问题 我观察到日志中有 2019/05/22 00:51:08 [Info] v2ray.com/core/app/proxyman/outbound: failed to process outbound traffic > v2ray.com/core/proxy/freedom: connection ends > context canceled 2019/05/22 00:51:08 [Info] v2ray.com/core/transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe 日志时间较系统时间慢8h 服务端日志 2019/05/21 20:50:29 [Info] [4273901811] v2ray.com/core/app/proxyman/inbound: connection ends > v2ray.com/core/proxy/vmess/inbound: connection ends > io: read/write on closed pipe 2019/05/21 20:50:29 [Info] [4273901811] v2ray.com/core/app/proxyman/inbound: failed to close connection > v2ray.com/core/transport/internet/kcp: Connection closed. 2019/05/21 20:50:29 [Info] [4181378400] v2ray.com/core/app/proxyman/outbound: failed to process outbound traffic > v2ray.com/core/proxy/freedom: connection ends > context canceled 2019/05/21 20:50:29 [Info] [4181378400] v2ray.com/core/app/proxyman/inbound: connection ends > v2ray.com/core/proxy/vmess/inbound: connection ends > io: read/write on closed pipe 2019/05/21 20:50:29 [Info] [4181378400] v2ray.com/core/app/proxyman/inbound: failed to close connection > v2ray.com/core/transport/internet/kcp: Connection closed. 2019/05/21 20:50:29 [Info] [1059110459] v2ray.com/core/app/proxyman/outbound: failed to process outbound traffic > v2ray.com/core/proxy/freedom: connection ends > context canceled 2019/05/21 20:50:29 [Info] [1059110459] v2ray.com/core/app/proxyman/inbound: connection ends > v2ray.com/core/proxy/vmess/inbound: connection ends > io: read/write on closed pipe 2019/05/21 20:50:29 [Info] [1059110459] v2ray.com/core/app/proxyman/inbound: failed to close connection > v2ray.com/core/transport/internet/kcp: Connection closed. 是否是因为系统时间问题导致v2ray close the pipe?

whyou commented 5 years ago

@sjz123321 我的log也是GMT时间,不是这个问题。看这个log,你这是频繁的连接断开啊。

chendefine commented 5 years ago

我做代理的iptables规则的时候,只考虑了outbound用tcp连接的情况,kcp用的是udp连接,可能跟这个有关,有空我再想办法看看

whyou commented 5 years ago

我做代理的iptables规则的时候,只考虑了outbound用tcp连接的情况,kcp用的是udp连接,可能跟这个有关,有空我再想办法看看

我感觉你记错了。你的iptables做透明代理,只代理了tcp没代理udp。outbound根本就没用iptables做限制啊。

经过我这里测试,使用mKCP+动态端口成功。

chendefine commented 5 years ago

我做代理的iptables规则的时候,只考虑了outbound用tcp连接的情况,kcp用的是udp连接,可能跟这个有关,有空我再想办法看看

我感觉你记错了。你的iptables做透明代理,只代理了tcp没代理udp。outbound根本就没用iptables做限制啊。

经过我这里测试,使用mKCP+动态端口成功。

是的,透明代理只代理了tcp协议,udp协议的代理搞不出来。

whyou commented 5 years ago

我做代理的iptables规则的时候,只考虑了outbound用tcp连接的情况,kcp用的是udp连接,可能跟这个有关,有空我再想办法看看

我感觉你记错了。你的iptables做透明代理,只代理了tcp没代理udp。outbound根本就没用iptables做限制啊。 经过我这里测试,使用mKCP+动态端口成功。

是的,透明代理只代理了tcp协议,udp协议的代理搞不出来。

我改了改试了一下,不知道为什么老说failed to handle UDP input。大概是我没写对吧。

RezaFeng commented 5 years ago

请问如何绕过中国大陆的地址呢,就是用PAC模式来连接

whyou commented 5 years ago

@RezaFeng v2ray自带了这个功能。具体请参考 v2ray.com 提供的说明。