233boy / v2ray

最好用的 V2Ray 一键安装脚本 & 管理脚本
https://233boy.com/v2ray/v2ray-script/
GNU General Public License v3.0
24.3k stars 16.06k forks source link

一键脚本配置V2Ray+ws+tls,无法正常工作 #468

Closed zzhjiyin closed 1 year ago

zzhjiyin commented 4 years ago

客户端版本:4.21.3,服务器:4.22.1

希望以下提供的文档有用,谢谢你的帮忙。

客户端配置文件

{
  "policy": null,
  "log": {
    "access": "",
    "error": "",
    "loglevel": "warning"
  },
  "inbounds": [
    {
      "tag": "proxy",
      "port": 10808,
      "listen": "127.0.0.1",
      "protocol": "socks",
      "sniffing": {
        "enabled": true,
        "destOverride": [
          "http",
          "tls"
        ]
      },
      "settings": {
        "auth": "noauth",
        "udp": true,
        "ip": null,
        "address": null,
        "clients": null
      },
      "streamSettings": null
    }
  ],
  "outbounds": [
    {
      "tag": "proxy",
      "protocol": "vmess",
      "settings": {
        "vnext": [
          {
            "address": "zzhjiyin.cf",
            "port": 443,
            "users": [
              {
                "id": "bd0ea3dc-fe6a-4e09-a2aa-***",
                "alterId": 233,
                "email": "t@t.tt",
                "security": "auto"
              }
            ]
          }
        ],
        "servers": null,
        "response": null
      },
      "streamSettings": {
        "network": "ws",
        "security": null,
        "tlsSettings": null,
        "tcpSettings": null,
        "kcpSettings": null,
        "wsSettings": {
          "connectionReuse": true,
          "path": "/ns",
          "headers": {
            "Host": "zzhjiyin.cf"
          }
        },
        "httpSettings": null,
        "quicSettings": null
      },
      "mux": {
        "enabled": true
      }
    },
    {
      "tag": "direct",
      "protocol": "freedom",
      "settings": {
        "vnext": null,
        "servers": null,
        "response": null
      },
      "streamSettings": null,
      "mux": null
    },
    {
      "tag": "block",
      "protocol": "blackhole",
      "settings": {
        "vnext": null,
        "servers": null,
        "response": {
          "type": "http"
        }
      },
      "streamSettings": null,
      "mux": null
    }
  ],
  "stats": null,
  "api": null,
  "dns": null,
  "routing": {
    "domainStrategy": "IPIfNonMatch",
    "rules": [
      {
        "type": "field",
        "port": null,
        "inboundTag": "api",
        "outboundTag": "api",
        "ip": null,
        "domain": null
      },
      {
        "type": "field",
        "port": null,
        "inboundTag": null,
        "outboundTag": "proxy",
        "ip": null,
        "domain": [
          "zzhjiyin.tktorrentkitty.tv"
        ]
      }
    ]
  }
}

服务器配置文件2(/etc/v2ray/233blog_v2ray_config.json)

{
    "log": {
        "access": "/var/log/v2ray/access.log",
        "error": "/var/log/v2ray/error.log",
        "loglevel": "warning"
    },
    "inbounds": [
        {
            "port": 21888,
            "protocol": "vmess",
            "settings": {
                "clients": [
                    {
                        "id": "bd0ea3dc-fe6a-4e09-a2aa-5***",
                        "level": 1,
                        "alterId": 233
                    }
                ]
            },
            "streamSettings": {
                "network": "ws"
            },
            "sniffing": {
                "enabled": true,
                "destOverride": [
                    "http",
                    "tls"
                ]
            }
        }
        //include_ss
        //include_socks
        //include_mtproto
        //include_in_config
        //
    ],
    "outbounds": [
        {
            "protocol": "freedom",
            "settings": {
                "domainStrategy": "UseIP"
            },
            "tag": "direct"
        },
        {
            "protocol": "blackhole",
            "settings": {},
            "tag": "blocked"
        },
        {
            "protocol": "mtproto",
            "settings": {},
            "tag": "tg-out"
        }
        //include_out_config
        //
    ],
    "dns": {
        "servers": [
            "https+local://1.1.1.1/dns-query",
            "1.1.1.1",
            "1.0.0.1",
            "8.8.8.8",
            "8.8.4.4",
            "localhost"
        ]
    },
    "routing": {
        "domainStrategy": "IPOnDemand",
        "rules": [
            {
                "type": "field",
                "ip": [
                    "0.0.0.0/8",
                    "10.0.0.0/8",
                    "100.64.0.0/10",
                    "127.0.0.0/8",
                    "169.254.0.0/16",
                    "172.16.0.0/12",
                    "192.0.0.0/24",
                    "192.0.2.0/24",
                    "192.168.0.0/16",
                    "198.18.0.0/15",
                    "198.51.100.0/24",
                    "203.0.113.0/24",
                    "::1/128",
                    "fc00::/7",
                    "fe80::/10"
                ],
                "outboundTag": "blocked"
            },
            {
                "type": "field",
                "inboundTag": ["tg-in"],
                "outboundTag": "tg-out"
            }
            ,
            {
                "type": "field",
                "domain": [
                    "domain:epochtimes.com",
                    "domain:epochtimes.com.tw",
                    "domain:epochtimes.fr",
                    "domain:epochtimes.de",
                    "domain:epochtimes.jp",
                    "domain:epochtimes.ru",
                    "domain:epochtimes.co.il",
                    "domain:epochtimes.co.kr",
                    "domain:epochtimes-romania.com",
                    "domain:erabaru.net",
                    "domain:lagranepoca.com",
                    "domain:theepochtimes.com",
                    "domain:ntdtv.com",
                    "domain:ntd.tv",
                    "domain:ntdtv-dc.com",
                    "domain:ntdtv.com.tw",
                    "domain:minghui.org",
                    "domain:renminbao.com",
                    "domain:dafahao.com",
                    "domain:dongtaiwang.com",
                    "domain:falundafa.org",
                    "domain:wujieliulan.com",
                    "domain:ninecommentaries.com",
                    "domain:shenyun.com"
                ],
                "outboundTag": "blocked"
            }           ,
                {
                    "type": "field",
                    "protocol": [
                        "bittorrent"
                    ],
                    "outboundTag": "blocked"
                }
            //include_ban_ad
            //include_rules
            //
        ]
    },
    "transport": {
        "kcpSettings": {
            "uplinkCapacity": 100,
            "downlinkCapacity": 100,
            "congestion": true
        }
    }
}

服务器配置文件(/etc/v2ray/conf.json)

{
    "outbounds": [
        {
            "protocol": "vmess",
            "settings": {
                "vnext": [
                    {
                        "address": "zzhjiyin.cf",
                        "port": 443,
                        "users": [
                            {
                                "id": "bd0ea3dc-fe6a-4e09-a2aa-***",
                                "alterId": 233,
                                "security": "auto"
                            }
                        ]
                    }
                ]
            },
            "streamSettings": {
                "network": "ws",
                "security": "tls",
                "tlsSettings": {
                    "serverName": "zzhjiyin.cf"
                },
                "wsSettings": {
                    "path": "/ns",
                    "headers": {
                        "Host": "zzhjiyin.cf"
                    }
                }
            },
            "mux": {
                "enabled": true
            }
        },
        {
            "protocol": "freedom",
            "settings": {},
            "tag": "direct"
        },
        {
            "protocol": "blackhole",
            "settings": {},
            "tag": "blocked"
        },
        {
            "protocol": "dns",
            "tag": "dns-out"
        }
    ],
    "inbounds": [
        {
            "port": "1099",
            "protocol": "dokodemo-door",
            "settings": {
              "network": "tcp,udp",
              "timeout": 0,
              "followRedirect": true
            },
            "sniffing": {
              "enabled": true,
              "destOverride": ["http", "tls"]
            }
        },
        {
            "port": 2133,
            "tag": "dns-in",
            "protocol": "dokodemo-door",
            "settings": {
                "address": "119.29.29.29",
                "port": 53,
                "timeout": 0,
                "network": "tcp,udp"
            }
        },
        {
            "port": 2333,
            "protocol": "socks",
            "settings": {
                "auth": "noauth",
                "udp": true
            }
        },
        {
            "port": 6666,
            "protocol": "http",
            "settings": {
                "auth": "noauth",
                "udp": true
            }
        }
    ],
    "dns": {
        "servers": [
            {
                "address": "119.29.29.29",
                "port": 53,
                "domains": [
                  "geosite:cn"
                ],
                "expectIPs": [
                  "geoip:cn"
                ]
              },
              {
                "address": "1.1.1.1",
                "port": 53,
                "domains": [
                  "geosite:geolocation-!cn"
                ]
            },
            "8.8.8.8",
            "localhost"
        ]
    },
    "routing": {
        "domainStrategy": "IPOnDemand", 
        "rules": [
            {
                "type": "field",
                "inboundTag": [
                    "dns-in"
                ],
                "outboundTag": "dns-out"
            },
            {
                "type": "field",
                "ip": [
                    "geoip:private"
                ],
                "outboundTag": "blocked"
            },
            {
                "type": "field",
                "ip": [
                    "geoip:cn"
                ],
                "outboundTag": "direct"
            },
            {
                "type": "field",
                "domain": [
                    "geosite:cn"
                ],
                "outboundTag": "direct"
            }
        ]
    }
}

Nginx配置文件(443 part)

server
    {
        listen 443 ssl http2;
        #listen [::]:443 ssl http2;
        server_name zzhjiyin.tk zzhjiyin.cf;
        index index.html index.htm index.php default.html default.htm default.php;
        root  /home/wwwroot/zzhjiyin.tk;

        ssl_certificate /usr/local/nginx/conf/ssl/zzhjiyin.tk/fullchain.cer;
        ssl_certificate_key /usr/local/nginx/conf/ssl/zzhjiyin.tk/zzhjiyin.tk.key;
        ssl_session_timeout 5m;
        ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3;
        ssl_prefer_server_ciphers on;
        ssl_ciphers "TLS13-AES-256-GCM-SHA384:TLS13-CHACHA20-POLY1305-SHA256:TLS13-AES-128-GCM-SHA256:TLS13-AES-128-CCM-8-SHA256:TLS13-AES-128-CCM-SHA256:EECDH+CHACHA20:EECDH+CHACHA20-draft:EECDH+AES128:RSA+AES128:EECDH+AES256:RSA+AES256:EECDH+3DES:RSA+3DES:!MD5";
        ssl_session_cache builtin:1000 shared:SSL:10m;
        # openssl dhparam -out /usr/local/nginx/conf/ssl/dhparam.pem 2048
        ssl_dhparam /usr/local/nginx/conf/ssl/dhparam.pem;

        include rewrite/none.conf;
        #error_page   404   /404.html;

        # Deny access to PHP files in specific directory
        #location ~ /(wp-content|uploads|wp-includes|images)/.*\.php$ { deny all; }

        include enable-php.conf;

        location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
        {
            expires      30d;
        }

        location ~ .*\.(js|css)?$
        {
            expires      12h;
        }

        location ~ /.well-known {
            allow all;
        }

        location ~ /\.
        {
            deny all;
        }

        access_log off;
  location /ns {   
             proxy_redirect off;
             proxy_pass http://127.0.0.1:21888; 
             proxy_http_version 1.1;
             proxy_set_header Upgrade $http_upgrade;
             proxy_set_header Connection "upgrade";
             proxy_set_header Host $http_host;   
    }
}

V2ray error log

2020/02/06 20:46:04 [Warning] v2ray.com/core: V2Ray 4.22.1 started
2020/02/06 21:08:42 [Warning] v2ray.com/core: V2Ray 4.22.1 started
2020/02/06 21:47:22 [Warning] v2ray.com/core: V2Ray 4.22.1 started

V2ray acess log

2020/02/06 21:09:19 tcp:219.133.172.34:38445 accepted tcp:www.youtube.com:443 [direct] 
2020/02/06 21:09:20 tcp:219.133.172.34:38445 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:09:20 tcp:219.133.172.34:38445 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:09:20 tcp:219.133.172.34:38445 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:09:20 tcp:219.133.172.34:38445 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:09:20 tcp:219.133.172.34:38445 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:09:21 tcp:219.133.172.34:38445 accepted tcp:www.gstatic.com:443 [direct] 
2020/02/06 21:09:21 tcp:219.133.172.34:38445 accepted tcp:lh3.googleusercontent.com:443 [direct] 
2020/02/06 21:09:21 tcp:219.133.172.34:38445 accepted tcp:lh3.googleusercontent.com:443 [direct] 
2020/02/06 21:09:21 tcp:219.133.172.34:38445 accepted tcp:lh3.googleusercontent.com:443 [direct] 
2020/02/06 21:09:40 tcp:219.133.172.34:38445 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:09:43 tcp:219.133.172.34:38445 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:09:48 tcp:219.133.172.34:38450 accepted tcp:history.google.com:443 [direct] 
2020/02/06 21:09:48 tcp:219.133.172.34:38445 accepted tcp:history.google.com:443 [direct] 
2020/02/06 21:10:01 tcp:219.133.172.34:38450 accepted tcp:fleeming.disqus.com:443 [direct] 
2020/02/06 21:10:01 tcp:219.133.172.34:38450 accepted tcp:disqus.com:443 [direct] 
2020/02/06 21:10:02 tcp:219.133.172.34:38450 accepted tcp:disqus.com:443 [direct] 
2020/02/06 21:10:02 tcp:219.133.172.34:38450 accepted tcp:clients1.google.com:443 [direct] 
2020/02/06 21:10:09 tcp:219.133.172.34:38450 accepted tcp:apis.google.com:443 [direct] 
2020/02/06 21:10:09 tcp:219.133.172.34:38450 accepted tcp:connect.facebook.net:443 [direct] 
2020/02/06 21:10:09 tcp:219.133.172.34:38450 accepted tcp:connect.facebook.net:443 [direct] 
2020/02/06 21:10:10 tcp:219.133.172.34:38450 accepted tcp:accounts.google.com:443 [direct] 
2020/02/06 21:10:11 tcp:219.133.172.34:39049 accepted tcp:www.facebook.com:443 [direct] 
2020/02/06 21:10:13 tcp:219.133.172.34:39049 accepted tcp:links.services.disqus.com:443 [direct] 
2020/02/06 21:10:14 tcp:219.133.172.34:38450 accepted tcp:links.services.disqus.com:443 [direct] 
2020/02/06 21:10:14 tcp:219.133.172.34:39049 accepted tcp:links.services.disqus.com:443 [direct] 
2020/02/06 21:10:14 tcp:219.133.172.34:38450 accepted tcp:links.services.disqus.com:443 [direct] 
2020/02/06 21:10:47 tcp:219.133.172.34:39049 accepted tcp:r2---sn-nx5e6nez.googlevideo.com:443 [direct] 
2020/02/06 21:10:47 tcp:219.133.172.34:39049 accepted tcp:r2---sn-nx5e6nez.googlevideo.com:443 [direct] 
2020/02/06 21:10:47 tcp:219.133.172.34:39049 accepted tcp:r2---sn-nx5e6nez.googlevideo.com:443 [direct] 
2020/02/06 21:10:47 tcp:219.133.172.34:39049 accepted tcp:r2---sn-nx5e6nez.googlevideo.com:443 [direct] 
2020/02/06 21:12:09 tcp:219.133.172.34:39049 accepted tcp:mtalk.google.com:5228 [direct] 
2020/02/06 21:12:23 tcp:219.133.172.34:38450 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:13:10 tcp:219.133.172.34:39049 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:13:53 tcp:219.133.172.34:38450 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:13:57 tcp:219.133.172.34:38445 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:17:44 tcp:219.133.172.34:38450 accepted tcp:mtalk.google.com:443 [direct] 
2020/02/06 21:19:33 tcp:219.133.172.34:39049 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:21:49 tcp:219.133.172.34:38450 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:21:51 tcp:219.133.172.34:39049 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:21:51 tcp:219.133.172.34:38450 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:21:54 tcp:219.133.172.34:39049 accepted tcp:t0.gstatic.com:443 [direct] 
2020/02/06 21:22:45 tcp:219.133.172.34:38450 accepted tcp:mtalk.google.com:5228 [direct] 
2020/02/06 21:28:29 tcp:183.13.212.16:34044 accepted tcp:mtalk.google.com:443 [direct] 
2020/02/06 21:28:54 tcp:183.13.212.16:34044 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:28:54 tcp:183.13.212.16:34044 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:28:54 tcp:183.13.212.16:34044 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:28:54 tcp:183.13.212.16:34044 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:28:55 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:29:17 tcp:183.13.212.16:34044 accepted tcp:ogs.google.com:443 [direct] 
2020/02/06 21:29:38 tcp:183.13.212.16:34044 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:30:18 tcp:183.13.212.16:34044 accepted tcp:clients1.google.com:443 [direct] 
2020/02/06 21:30:39 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:30:47 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:31:09 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:31:15 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:45 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:52 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:53 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:53 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:53 tcp:183.13.212.16:33699 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:53 tcp:183.13.212.16:33699 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:54 tcp:183.13.212.16:33699 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:54 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:54 tcp:183.13.212.16:33699 accepted tcp:zzhjiyin.tk:80 [direct] 
2020/02/06 21:31:57 tcp:183.13.212.16:33699 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:31:58 tcp:183.13.212.16:34044 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:39:36 tcp:183.13.212.16:35577 accepted tcp:www.youtube.com:443 [direct] 
2020/02/06 21:39:36 tcp:183.13.212.16:35577 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:39:36 tcp:183.13.212.16:35577 accepted tcp:www.youtube.com:443 [direct] 
2020/02/06 21:39:44 tcp:183.13.212.16:35577 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:39:45 tcp:183.13.212.16:35577 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:39:45 tcp:183.13.212.16:35577 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:39:45 tcp:183.13.212.16:35577 accepted tcp:www.gstatic.com:443 [direct] 
2020/02/06 21:39:45 tcp:183.13.212.16:35577 accepted tcp:lh3.googleusercontent.com:443 [direct] 
2020/02/06 21:39:46 tcp:183.13.212.16:35577 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:39:46 tcp:183.13.212.16:35580 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:39:46 tcp:183.13.212.16:35580 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:39:46 tcp:183.13.212.16:35580 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:39:46 tcp:183.13.212.16:35580 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:39:46 tcp:183.13.212.16:35580 accepted tcp:lh3.googleusercontent.com:443 [direct] 
2020/02/06 21:39:57 tcp:183.13.212.16:35577 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:39:57 tcp:183.13.212.16:35580 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:39:58 tcp:183.13.212.16:35580 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:39:58 tcp:183.13.212.16:35577 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:40:02 tcp:183.13.212.16:35580 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:40:02 tcp:183.13.212.16:35577 accepted tcp:yt3.ggpht.com:443 [direct] 
2020/02/06 21:40:05 tcp:183.13.212.16:35580 accepted tcp:www.gstatic.com:443 [direct] 
2020/02/06 21:40:13 tcp:183.13.212.16:36225 accepted tcp:www.youtube.com:443 [direct] 
2020/02/06 21:40:13 tcp:183.13.212.16:36225 accepted tcp:www.youtube.com:443 [direct] 
2020/02/06 21:40:13 tcp:183.13.212.16:36225 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:40:13 tcp:183.13.212.16:36225 accepted tcp:i.ytimg.com:443 [direct] 
2020/02/06 21:40:13 tcp:183.13.212.16:36225 accepted tcp:speedtest-sfo2.digitalocean.com:80 [direct] 
2020/02/06 21:40:23 tcp:183.13.212.16:36225 accepted tcp:clients1.google.com:443 [direct] 
2020/02/06 21:40:23 tcp:183.13.212.16:36225 accepted tcp:s.ytimg.com:443 [direct] 
2020/02/06 21:40:25 tcp:183.13.212.16:36225 accepted tcp:www.youtube.com:443 [direct] 
2020/02/06 21:40:44 tcp:183.13.212.16:36225 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:41:33 tcp:183.13.212.16:36225 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:41:33 tcp:183.13.212.16:36225 accepted tcp:www.google.com:443 [direct] 
2020/02/06 21:41:35 tcp:183.13.212.16:36225 accepted tcp:zzhjiyin.tk:443 [direct] 
2020/02/06 21:41:36 tcp:183.13.212.16:36225 accepted tcp:fonts.gstatic.com:443 [direct] 
2020/02/06 21:41:38 tcp:183.13.212.16:36225 accepted tcp:secure.gravatar.com:443 [direct] 
2020/02/06 21:41:39 tcp:183.13.212.16:36227 accepted tcp:s1.hdslb.com:443 [direct] 
2020/02/06 21:41:39 tcp:183.13.212.16:36227 accepted tcp:player.bilibili.com:443 [direct] 
2020/02/06 21:41:39 tcp:183.13.212.16:36227 accepted tcp:player.bilibili.com:443 [direct] 
2020/02/06 21:41:52 tcp:183.13.212.16:36232 accepted tcp:speedtest-sfo2.digitalocean.com:80 [direct] 
2020/02/06 21:42:03 tcp:183.13.212.16:36232 accepted tcp:mtalk.google.com:5228 [direct] 
2020/02/06 21:42:04 tcp:183.13.212.16:36232 accepted tcp:github.com:443 [direct] 
2020/02/06 21:42:04 tcp:183.13.212.16:36232 accepted tcp:github.com:443 [direct] 
2020/02/06 21:42:04 tcp:183.13.212.16:36232 accepted tcp:github.githubassets.com:443 [direct] 
2020/02/06 21:42:04 tcp:183.13.212.16:36232 accepted tcp:sec.cmbchina.com:80 [direct] 
2020/02/06 21:42:28 tcp:183.13.212.16:36232 accepted tcp:clients4.google.com:443 [direct] 
2020/02/06 21:42:34 tcp:183.13.212.16:36232 accepted tcp:github.com:443 [direct] 
2020/02/06 21:42:34 tcp:183.13.212.16:36232 accepted tcp:github.com:443 [direct] 
2020/02/06 21:42:34 tcp:183.13.212.16:36232 accepted tcp:github.githubassets.com:443 [direct] 

journalctl -u v2ray

-- Logs begin at Thu 2020-02-06 19:34:10 CST, end at Fri 2020-02-07 01:55:32 CST. --
Feb 06 20:46:04 69.171.72.246.16clouds.com systemd[1]: Started V2Ray Service.
Feb 06 20:46:04 69.171.72.246.16clouds.com v2ray[1227]: V2Ray 4.22.1 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.13.5 linux/amd64)
Feb 06 20:46:04 69.171.72.246.16clouds.com v2ray[1227]: A unified platform for anti-censorship.
Feb 06 21:04:10 69.171.72.246.16clouds.com systemd[1]: Stopping V2Ray Service...
Feb 06 21:04:10 69.171.72.246.16clouds.com systemd[1]: Stopped V2Ray Service.
Feb 06 21:04:10 69.171.72.246.16clouds.com systemd[1]: Started V2Ray Service.
Feb 06 21:04:10 69.171.72.246.16clouds.com v2ray[4569]: V2Ray 4.22.1 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.13.5 linux/amd64)
Feb 06 21:04:10 69.171.72.246.16clouds.com v2ray[4569]: A unified platform for anti-censorship.
Feb 06 21:04:10 69.171.72.246.16clouds.com v2ray[4569]: main: failed to read config file: /etc/v2ray/config.json > v2ray.com/core/main/json: failed to execute v2ctl to convert config file. > v2ray.com/core/common/platform/ctlcmd:
Feb 06 21:04:10 69.171.72.246.16clouds.com v2ray[4569]: > exit status 255
Feb 06 21:04:10 69.171.72.246.16clouds.com systemd[1]: v2ray.service: main process exited, code=exited, status=23/n/a
Feb 06 21:04:10 69.171.72.246.16clouds.com systemd[1]: Unit v2ray.service entered failed state.
Feb 06 21:04:10 69.171.72.246.16clouds.com systemd[1]: v2ray.service failed.
Feb 06 21:08:12 69.171.72.246.16clouds.com systemd[1]: Started V2Ray Service.
Feb 06 21:08:12 69.171.72.246.16clouds.com v2ray[4709]: V2Ray 4.22.1 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.13.5 linux/amd64)
Feb 06 21:08:12 69.171.72.246.16clouds.com v2ray[4709]: A unified platform for anti-censorship.
Feb 06 21:08:12 69.171.72.246.16clouds.com v2ray[4709]: main: failed to read config file: /etc/v2ray/config.json > v2ray.com/core/main/json: failed to execute v2ctl to convert config file. > v2ray.com/core/common/platform/ctlcmd:
Feb 06 21:08:12 69.171.72.246.16clouds.com v2ray[4709]: > exit status 255
Feb 06 21:08:12 69.171.72.246.16clouds.com systemd[1]: v2ray.service: main process exited, code=exited, status=23/n/a
Feb 06 21:08:12 69.171.72.246.16clouds.com systemd[1]: Unit v2ray.service entered failed state.
Feb 06 21:08:12 69.171.72.246.16clouds.com systemd[1]: v2ray.service failed.
Feb 06 21:08:42 69.171.72.246.16clouds.com systemd[1]: Started V2Ray Service.
Feb 06 21:08:42 69.171.72.246.16clouds.com v2ray[4772]: V2Ray 4.22.1 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.13.5 linux/amd64)
Feb 06 21:08:42 69.171.72.246.16clouds.com v2ray[4772]: A unified platform for anti-censorship.
Feb 06 21:47:22 69.171.72.246.16clouds.com systemd[1]: Stopping V2Ray Service...
Feb 06 21:47:22 69.171.72.246.16clouds.com systemd[1]: Stopped V2Ray Service.
Feb 06 21:47:22 69.171.72.246.16clouds.com systemd[1]: Started V2Ray Service.
Feb 06 21:47:22 69.171.72.246.16clouds.com v2ray[5502]: V2Ray 4.22.1 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.13.5 linux/amd64)
Feb 06 21:47:22 69.171.72.246.16clouds.com v2ray[5502]: A unified platform for anti-censorship.
ianlie commented 4 years ago

我也是一样版本号,用不了, 不过我不是用433端口,用mkcp而已,然后虽然状态显示运行,可是搜不到设置的端口,端口确认开放没问题,感觉像v2没运行似的, 要不你也试试看,端口是不是正常开放,

Prussia commented 4 years ago

今天试一键安装脚本,安装成功,有同样的问题。

ChengEast commented 4 years ago

main: failed to read config file: /etc/v2ray/config.json 提示很清楚了,你的配置文件转换不了标准JSON格式,看了一下,你的括号括得不对。