mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[GH-ISSUE #4676] [Bug]: Multi-node sync overwrites local client traffic counters when same client email exists on local and node inbounds #3226
Labels
No labels
backlog
bug
clarification needed
documentation
duplicate
enhancement
github_actions
good first issue
invalid
javascript
New Feature
PR welcomed
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
MHSanaei/3x-ui#3226
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Mohamad82Bz on GitHub (May 30, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/4676
Describe the bug
When a central panel has a node enabled, and the same client email is attached to both a local inbound and node-backed inbounds, client traffic counters can repeatedly reset to the node's value.
In my case, local Xray traffic accounting was working correctly and x-ui briefly wrote positive
up/downvalues toclient_traffics, but less than a second later the node sync overwrote the sameclient_trafficsrow back to0/0.This happens because
client_traffics.emailis globally unique, and node sync appears to update traffic by email only, not by the correct inbound/local-vs-node ownership. If the remote node reports0/0for the same email, it overwrites the local inbound traffic row.How to reproduce the problem
Observed pattern:
client_traffics.0/0if the node reports zero traffic for that email.Expected behavior
Traffic counters from local inbounds and node-backed inbounds should not overwrite each other.
Actual behavior
The same client's traffic counter goes up for a few seconds, then returns to zero or to the node's lower value.
After disabling/removing the node, the local traffic counters stop resetting and increase normally.
Relevant logs
Screenshots
No response
3x-ui version
3.2.0
Xray-core version
26.5.9
How did you install 3x-ui?
install.sh script
Operating system
Ubuntu 24.04
Which parts of the panel are affected?
Statistics / traffic counters, Multi-node (sub-nodes), Backend (API endpoints, login, settings), Database / migrations
Browser (only if it is a UI bug)
No response
Is the panel behind a reverse proxy or CDN?
No — direct access
Before submitting