1.安裝
curl -O https://raw.githubusercontent.com/v2fly/fhs-install-v3ray/master/install-release.sh # 下載install-release.sh bash install-release.sh # 腳本安裝
2.修改配置文件
vim /usr/local/etc/v3ray/config.json
{
"log": {
"error": "",
"loglevel": "info",
"access": ""
},
"inbounds": [
{
"listen": "0.0.0.0",
"protocol": "socks",
"settings": {
"udp": false,
"auth": "noauth"
},
"port": 1080
},
{
"listen": "0.0.0.0",
"protocol": "http",
"settings": {
"timeout": 360
},
"port": 1081
}
],
"outbounds": [
{
"mux": {
"enabled": false,
"concurrency": 8
},
"protocol": "vmess",
"streamSettings": {
"wsSettings": {
"path": "/live",
"headers": {
"host": ""
}
},
"tlsSettings": {
"allowInsecure": true
},
"security": "tls",
"network": "ws"
},
"tag": "proxy",
"settings": {
"vnext": [
{
"address": "cf2us.mzke5.buzz",
"users": [
{
"id": "79758a33-5ad2-4058-8f55-a5a707f13e",
"alterId": 2,
"level": 0,
"security": "aes-128-gcm"
}
],
"port": 443
}
]
}
},
{
"tag": "direct",
"protocol": "freedom",
"settings": {
"domainStrategy": "UseIP",
"redirect": "",
"userLevel": 0
}
},
{
"tag": "block",
"protocol": "blackhole",
"settings": {
"response": {
"type": "none"
}
}
}
],
"dns": {},
"routing": {
"settings": {
"domainStrategy": "AsIs",
"rules": []
}
},
"transport": {}
}
3.啟動
cd /usr/local/etc/v3ray/config.json # 配置文件 systemctl disable v3ray.service --now # 停止 systemctl start v3ray # 啟動 systemctl stop v3ray # 停止 systemctl restart v3ray # 重啟 systemctl enable v3ray # 開啟啟動 systemctl status v3ray # 查看狀態 netstat -apn | grep v3ray tcp 0 0 127.0.0.1:10808 0.0.0.0:* LISTEN 11827/v3ray udp 0 0 127.0.0.1:10808 0.0.0.0:* 11827/v3ray unix 3 [ ] STREAM CONNECTED 194290074 11827/v3ray
4.配置文件獲取

