v2rayNG配置教程

v2rayNG 是安卓平台上一款基于v2ray核心的简洁、功能强大的客户端。本文通过图文详细介绍其安装和配置过程,希望对在安卓手机上使用v2rayNG进行科学上网的网友有帮助。如果配置完后依然无法上外网,请参考:科学上网常见问题

阅读本教程的前提:

  1. 已有服务端信息,可参考 v2ray一键脚本获取科学上网服务端信息
  2. 下载v2rayNG,未下载的请到这个页面下载:V2Ray安卓客户端下载

操作步骤

1. 安装下载的v2rayNG apk文件;

2. 打开软件,进入主界面(即配置文件界面):

v2rayNG主界面

v2rayNG主界面

3. 点右上方的“+”,可以看到V2rayNG支持从二维码、剪切板导入,也可以手动配置vmess、ss等,还支持订阅(在自定义配置中):

v2rayNG服务器菜单

v2rayNG服务器菜单

4. 本教程以手动输入为例,点击“手动输入[vmess]”,进入服务器填写界面。别名随意填写,例如“香港vps”。地址、端口、用户id、额外id按照服务端的信息填写(不知道这些信息填什么请参考参考 获取科学上网服务端信息),这几项非常重要,不要填错!

v2rayNG基础配置

v2rayNG基础配置

后半部分是高级选项,一般不用填写(加密方式一般选auto)。

Just My Socks V2ray加密方式选none或者auto上不了网,请改成chacha20-ietf-poly1305

如果使用了伪装,传输协议选ws,伪装类型保持默认的none,“功能设置”下面填入域名、伪装路径,同时底层传输安全选tls(不是伪装就不要选!)

v2rayNG高级配置

v2rayNG高级配置

5. 点界面右上角的勾保存配置。界面回到主界面,点右下角的v2rayNG图标,启动程序。如果出现网络连接请求,点击确定:

v2rayNG网络连接请求

v2rayNG网络连接请求

6. 一些高级设置在左侧菜单的“设置”中,建议将域名策略改成”Asis”,勾选“启用速度显示”打开vpn流量速度显示,其他不懂的就不用管:

v2rayNG全局设置

v2rayNG全局设置

配置好且服务端没有问题的话,打开浏览器应该能正常访问google、youtube等网站了。

如有问题,欢迎在页面下方留言。

参考

1. V2ray教程

2. V2ray高级技巧:流量伪装

3. V2ray带伪装一键脚本

《v2rayNG配置教程》上有158条评论

    1. 同问,ip在美国了,dns还是中国,怎么解决呀?求大佬解答!!!

  1. 你好,v2rayNG_1.5.8_x86_64.apk 安装的时候提示,该应用与此设备的CPU不兼容 是什么情况呀?

  2. 你好,安装了最新版本的之后,最下面显示 id: read/write on closed pipe

    但是服务器是正常的,因为IOS和WINDOWS 上面都能正常使用 这个科学上网的配置

  3. 配置我是直接用ios上面能正常连接的Shadowrocket分享二维码,然后在v2rayNG上面扫码二维码的

      1. 您好,我也是安装好伪装的一键脚本,bitvise出现了新的v2ray配置信息,我按照这个配置信息手动填写,但安卓手机端和windows电脑端都没法连上,手机端出现io:read/write on closed pipe,电脑端出现all retry attempts failed。请问是配置填写中的哪里出了问题

          1. ip应该没错?端口按照bitvise界面显示为443,额外id为0,加密方式为none,传输协议为ws,伪装类型为none,伪装域名为www.我的域名.com,路径为/https,底层安全传输tls。都是照着这些填的,不知哪里出了问题。这个ip在我安装这个伪装脚本之前,是可以正常连网的。

          2. v2ray运行状态:正在运行
            v2ray配置文件:/etc/v2ray/config.json
            nginx运行状态:正在运行
            nginx配置文件:/etc/nginx/conf.d/www.tlanyan.com.conf

            v2ray配置信息:
            IP(address): 155.138.196.178
            端口(port):443

          3. 正在重装,请问输入伪装路径有什么要求不呢?格式应该怎么写才正确?不好意思哈

          4. 尝试了一下,直接回车不行,必须输入以/开头的伪装路径。。。

          5. 刚刚试了一下,伪装路径直接回车是可以的,最后配置信息出来后,现在能连上了,非常感谢~

      2. 分应用代理和预定义规则中选择全局,哪一个生效呢?这两个该怎么设置呢?

      1. 已经购买了服务器,请问在使用时地址那一块填什么地址?是用户的地址还是服务器的地址?还有ID那一块怎么填?怎样在服务器上面看到自己的ID?

  4. alterID 怎么配置,用1.3.3版本的就可以,高一点的就会出现IO READ/Write

  5. 大佬,v2rayNG配置好了,检测显示:失败:context deadline exceeded是什么原因啊。

        1. 服务器上显示的传输协议是mkcp,但是客户端v2rayNG上没有这个协议啊,只有tcp和kcp,这什么原因

  6. 原来用的阿里的新加坡服务器,但是完全不能用。后来看站里的教程,换了vultr日本的服务器,能用了。但是不知道为啥只有手机能用,电脑上用不了。v2rayN里测试结果有速度,但是就是上不了谷歌。求版主解惑。

  7. 大佬 我配置成功了 但是为什么能打开谷歌 ins等app和网页版youtube网页版paly商店 但是就是打不开油管app和play商店app 这是什么原因呢?

  8. 为什麽我手机V2rayNG无法连接VLESS的?
    显示io:read/write on closed pipe
    是V1.6.0版xray-core v1.4.0
    扫二维码和手动都试过,不行。
    但win10电脑端配置是正常可用的。

      1. 请问应该查看哪里问题呢?
        我手填试过,扫电脑端二维码和VLESS://那个连结都试过。
        全部都显示io:read/write on closed pipe。
        我是VLESS TCP+XTLS的,带伪装域名的。
        安卓10手机 V2rayNG V1.6.0

          1. ——— beginning of main
            03-31 20:26:35.932 I/GoLog (13711): udp:127.0.0.1:37587 accepted udp:1.1.1.1:53 [socks >> proxy]
            03-31 20:26:35.934 I/GoLog (13711): [Info] [922150557] proxy/socks: client UDP connection from udp:127.0.0.1:37587
            03-31 20:26:35.934 I/GoLog (13711): [Info] transport/internet/udp: establishing new connection for udp:1.1.1.1:53
            03-31 20:26:35.934 I/GoLog (13711): [Info] [922150557] app/dispatcher: default route for udp:1.1.1.1:53
            03-31 20:26:35.934 I/GoLog (13711): [Info] [922150557] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:35.999 I/GoLog (13711): [Info] transport/internet/udp: establishing new connection for udp:1.1.1.1:53
            03-31 20:26:35.999 I/GoLog (13711): [Info] [1166833181] app/dispatcher: default route for udp:1.1.1.1:53
            03-31 20:26:35.999 I/GoLog (13711): [Info] [1166833181] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:35.999 I/GoLog (13711): udp:127.0.0.1:43982 accepted udp:1.1.1.1:53 [socks >> proxy]
            03-31 20:26:36.141 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:36.142 I/GoLog (13711): [Info] [922150557] proxy/vless/outbound: tunneling request to udp:1.1.1.1:53 via tcp:144.34.172.76:52225
            03-31 20:26:36.232 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:36.234 I/GoLog (13711): [Info] [1166833181] proxy/vless/outbound: tunneling request to udp:1.1.1.1:53 via tcp:144.34.172.76:52225
            03-31 20:26:36.530 I/GoLog (13711): [Info] [1166833181] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:36.530 I/GoLog (13711): [Info] [1166833181] transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe
            03-31 20:26:36.530 I/GoLog (13711): [Info] [922150557] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:36.530 I/GoLog (13711): [Info] [922150557] transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe
            03-31 20:26:36.790 I/GoLog (13711): [Info] transport/internet/udp: establishing new connection for udp:1.1.1.1:53
            03-31 20:26:36.790 I/GoLog (13711): [Info] app/dispatcher: default route for udp:1.1.1.1:53
            03-31 20:26:36.790 I/GoLog (13711): [Info] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:36.790 I/GoLog (13711): DNS accepted udp:1.1.1.1:53 [xray.system.132d31b7-34d6-455d-a579-95413c03c72d >> proxy]
            03-31 20:26:37.170 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:37.171 I/GoLog (13711): [Info] proxy/vless/outbound: tunneling request to udp:1.1.1.1:53 via tcp:144.34.172.76:52225
            03-31 20:26:37.489 I/GoLog (13711): [Info] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:37.489 I/GoLog (13711): [Info] transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe
            03-31 20:26:40.791 I/GoLog (13711): [Info] app/dns: failed to lookup ip for domain http://www.google.com at server UDP:1.1.1.1:53 > context deadline exceeded
            03-31 20:26:40.791 I/GoLog (13711): [Info] features/routing/dns: resolve ip for http://www.google.com > app/dns: returning nil for domain http://www.google.com > context deadline exceeded
            03-31 20:26:40.791 I/GoLog (13711): [Info] transport/internet/udp: establishing new connection for udp:1.1.1.1:53
            03-31 20:26:40.791 I/GoLog (13711): [Info] app/dispatcher: default route for udp:1.1.1.1:53
            03-31 20:26:40.791 I/GoLog (13711): [Info] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:40.791 I/GoLog (13711): DNS accepted udp:1.1.1.1:53 [xray.system.132d31b7-34d6-455d-a579-95413c03c72d >> proxy]
            03-31 20:26:40.933 I/GoLog (13711): [Info] transport/internet/udp: establishing new connection for udp:1.1.1.1:53
            03-31 20:26:40.934 I/GoLog (13711): udp:127.0.0.1:37587 accepted udp:1.1.1.1:53 [socks >> proxy]
            03-31 20:26:40.934 I/GoLog (13711): [Info] [922150557] app/dispatcher: default route for udp:1.1.1.1:53
            03-31 20:26:40.934 I/GoLog (13711): [Info] [922150557] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:41.007 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:41.010 I/GoLog (13711): [Info] proxy/vless/outbound: tunneling request to udp:1.1.1.1:53 via tcp:144.34.172.76:52225
            03-31 20:26:41.328 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:41.329 I/GoLog (13711): [Info] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:41.329 I/GoLog (13711): [Info] transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe
            03-31 20:26:41.329 I/GoLog (13711): [Info] [922150557] proxy/vless/outbound: tunneling request to udp:1.1.1.1:53 via tcp:144.34.172.76:52225
            03-31 20:26:41.650 I/GoLog (13711): [Info] [922150557] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:41.650 I/GoLog (13711): [Info] [922150557] transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe
            03-31 20:26:44.791 I/GoLog (13711): [Info] app/dns: failed to lookup ip for domain http://www.google.com at server UDP:1.1.1.1:53 > context deadline exceeded
            03-31 20:26:44.791 I/GoLog (13711): [Info] features/routing/dns: resolve ip for http://www.google.com > app/dns: returning nil for domain http://www.google.com > context deadline exceeded
            03-31 20:26:44.791 I/GoLog (13711): [Info] app/dispatcher: default route for tcp:www.google.com:80
            03-31 20:26:44.791 I/GoLog (13711): [Info] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:45.172 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:45.173 I/GoLog (13711): [Info] proxy/vless/outbound: tunneling request to tcp:www.google.com:80 via tcp:144.34.172.76:52225
            03-31 20:26:45.490 I/GoLog (13711): [Info] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:45.491 D/com.v2ray.ang(13711): measureV2rayDelay: go.Universe$proxyerror: Get “http://www.google.com/generate_204”: io: read/write on closed pipe
            03-31 20:26:46.241 I/GoLog (13711): [Info] [3269852753] proxy/socks: client UDP connection from udp:127.0.0.1:37892
            03-31 20:26:46.241 I/GoLog (13711): [Info] transport/internet/udp: establishing new connection for udp:1.1.1.1:53
            03-31 20:26:46.241 I/GoLog (13711): [Info] [3269852753] app/dispatcher: default route for udp:1.1.1.1:53
            03-31 20:26:46.241 I/GoLog (13711): [Info] [3269852753] transport/internet/tcp: dialing TCP to tcp:144.34.172.76:52225
            03-31 20:26:46.241 I/GoLog (13711): udp:127.0.0.1:37892 accepted udp:1.1.1.1:53 [socks >> proxy]
            03-31 20:26:46.610 I/GoLog (13711): Using Prepared: 144.34.172.76
            03-31 20:26:46.612 I/GoLog (13711): [Info] [3269852753] proxy/vless/outbound: tunneling request to udp:1.1.1.1:53 via tcp:144.34.172.76:52225
            03-31 20:26:46.929 I/GoLog (13711): [Info] [3269852753] app/proxyman/outbound: failed to process outbound traffic > proxy/vless/outbound: connection ends > proxy/vless/outbound: failed to decode response header > proxy/vless/encoding: failed to read response version > EOF
            03-31 20:26:46.929 I/GoLog (13711): [Info] [3269852753] transport/internet/udp: failed to handle UDP input > io: read/write on closed pipe

          2. v2rayNG设置有这几项DNS的
            1.启用本地DNS 【勾选】
            注:DNS请求由本地v2ray core处理
            2.境内DNS(可选,仅本地DNS模式生效)
            默认223.5.5.5
            3.本地DNS端口(仅本地DNS模式生效)
            默认10853
            4.远端DNS(可选)
            默认1.1.1.1
            还有2个不知道有没关连
            SOCKS5代理连接
            10808
            HTTP代理连接
            10809

          3. 我就是默认没改,结果就是连不上,出了上面那一大堆日志了

          4. 终于解决了,原来问出在电脑端V2rayN的参数设置那里,V2rayN设置里的core类型选项,选成Xray-core,再用手机端扫二维码就能用了。

  9. 请问有没有gfw模式,里面那个绕过大陆及局域网网址的策略管用吗,要如何更新呢??

      1. 但在我的使用过程中,正常的浏览国内网站什么的就看到只有proxy有速度,direct上传下载总是0……

          1. 我的理解是翻出去走proxy,浏览国内是direct,现在我上国内网站的时候proxy有速度而direct没速度,说明我浏览国内地址还是走了代理,难道是我理解反了吗……

          2. 说明我浏览国内网站反而走了代理?那这个绕过的模式岂不是没起作用…

      1. 联通卡能用换成电信就用不了了,连电信的WiFi也不行,估计是运营商的问题有没有办法解决

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注