设置V2Ray节点的步骤如下

  1. 安装V2Ray

    • 使用Wget下载DEB安装包:
      wget https://github.com/v2ray/v2ray/releases/download/v4.30./v2ray-deb-4.30.-x86_64.deb
    • 安装:
      sudo apt install ./v2ray-deb-4.30.-x86_64.deb
  2. 生成配置文件

    • 生成默认配置:
      v2ctl generate
    • 打开配置文件,添加订阅地址:
      nano ~/.v2ray/config.json

      outbound部分添加:

      "outbound": {
        "http": "127...1:108",
        "https": "127...1:1081"
      }
  3. 设置代理规则

    • 添加HTTP和HTTPS规则:
      v2ctl add http://127...1:108
      v2ctl add https://127...1:1081
  4. 配置防火墙

    • 清空防火墙:
      sudo iptables -P
    • 允许V2Ray的出站流量:
      sudo iptables -A OUTPUT -p tcp --dport 108,1081 -j ACCEPT
    • 返回默认规则:
      sudo iptables -P
  5. 启动V2Ray

    • 启动服务:
      sudo systemctl start v2ray@default
    • 确保服务随系统重启:
      sudo systemctl enable v2ray@default

完成以上步骤后,可以通过浏览器访问配置文件的URL,其他设备即可连接到你的V2Ray节点,记得确保网络环境的合法性,遵守相关法律法规。

设置V2Ray节点的步骤如下

扫码添加安易加速器官方微信

扫码添加安易加速器官方微信

021-64387251
扫码添加安易加速器官方微信

扫码添加安易加速器官方微信

网站地图