Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

跟参考指南一样的配置,流量统计输出没有具体用户的信息 #105

Open
Rabbit-st opened this issue Nov 22, 2019 · 0 comments
Labels
unconfirmed Waiting investigation

Comments

@Rabbit-st
Copy link

Rabbit-st commented Nov 22, 2019

v2ray版本:

[root@localhost v2ray]# /usr/bin/v2ray/v2ray -version
V2Ray 4.21.3 (V2Fly, a community-driven edition of V2Ray.) Custom
A unified platform for anti-censorship.

配置文件:

[root@localhost v2ray]# cat config.json
{
    "stats": {},
    "api": {
        "tag": "api",
        "services": [
            "StatsService"
        ]
    },
    "policy": {
        "levels": {
            "0": {
                "statsUserUplink": true,
                "statsUserDownlink": true
            }
        },
        "system": {
            "statsInboundUplink": true,
            "statsInboundDownlink": true
        }
    },
    "inbounds": [
        {
            "tag": "tcp",
            "port": 3307,
            "protocol": "vmess",
            "settings": {
                "clients": [
                    {
                        "email": "auser",
                        "id": "e731f153-4f31-49d3-9e8f-ff8f396135ef",
                        "level": 0,
                        "alterId": 64
                    },
                    {
                        "email": "buser",
                        "id": "e731f153-4f31-49d3-9e8f-ff8f396135ee",
                        "level": 0,
                        "alterId": 64
                    }
                ]
            }
        },
        {
            "listen": "127.0.0.1",
            "port": 10085,
            "protocol": "dokodemo-door",
            "settings": {
                "address": "127.0.0.1"
            },
            "tag": "api"
        }
    ],
    "outbounds": [
        {
            "protocol": "freedom",
            "settings": {}
        }
    ],
    "routing": {
        "settings": {
            "rules": [
                {
                    "inboundTag": [
                        "api"
                    ],
                    "outboundTag": "api",
                    "type": "field"
                }
            ]
        },
        "strategy": "rules"
    }
} 

我的输出:

[root@localhost v2ray]# /usr/bin/v2ray/v2ctl api --server=127.0.0.1:10085 StatsService.QueryStats ''
stat: <
  name: "inbound>>>tcp>>>traffic>>>uplink"
>
stat: <
  name: "inbound>>>tcp>>>traffic>>>downlink"
>
stat: <
  name: "inbound>>>api>>>traffic>>>uplink"
  value: 1306
>
stat: <
  name: "inbound>>>api>>>traffic>>>downlink"
  value: 1339
>

参考指南的输出

$ /usr/bin/v2ray/v2ctl api --server=127.0.0.1:10085 StatsService.QueryStats ''
stat: <
name: "inbound>>>ws>>>traffic>>>uplink"
value: 3350713

stat: <
name: "inbound>>>ss>>>traffic>>>downlink"
value: 1704

stat: <
name: "user>>>u3@ws>>>traffic>>>uplink"
value: 2810759

stat: <
name: "user>>>u9@ss>>>traffic>>>uplink"
value: 1776

我的输出中看不到具体用户的统计信息,是新版不支持了吗,还是配置需要做改动?

@nicholascw nicholascw added the unconfirmed Waiting investigation label Dec 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
unconfirmed Waiting investigation
Projects
None yet
Development

No branches or pull requests

2 participants