mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[GH-ISSUE #4984] [Bug]: Incorrect node mapping for clients in nested/chained multi-node setup (Node 1 -> Node 2 -> Node 3) #3504
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#3504
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 @zetrock1 on GitHub (Jun 5, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/4984
Describe the bug
In a nested/chained multi-node setup (where Node 1 manages Node 2, and Node 2 manages Node 3), the online status of clients is displayed incorrectly on the primary Master panel (Node 1). Clients that are active on Node 3 are incorrectly shown on Node 1 as if they are online on Node 2.
How to reproduce the problem
Expected behavior
The primary Master panel (Node 1) should correctly map and display which downstream node a client is active on. If a client is connected to Node 3, the Node 1 panel should show them as online on Node 3, instead of flattening and mapping all cascaded clients to Node 2.
Actual behavior
All active clients from Node 3 are incorrectly displayed on Node 1 as if they are online on Node 2. This happens because Node 2 merges the online clients of Node 3 into its own list, and Node 1 (having no direct relationship with Node 3 in its direct database mapping) associates all of them with Node 2.
Relevant logs
Screenshots
No response
3x-ui version
3.2.8
Xray-core version
26.6.1
How did you install 3x-ui?
install.sh script
Operating system
Arch linux
Which parts of the panel are affected?
Frontend (UI / panel pages), Backend (API endpoints, login, settings), Multi-node (sub-nodes)
Browser (only if it is a UI bug)
No response
Is the panel behind a reverse proxy or CDN?
None
Before submitting
@github-actions[bot] commented on GitHub (Jun 5, 2026):
This appears to be a duplicate of #4983, submitted by the same author ~13 seconds earlier. Closing this copy in favour of #4983.
For anyone finding this via search: the bug has been verified in the source. Root cause summary:
The multi-node online-status tracking is designed for a flat star topology (one master to many leaf nodes). It does not handle a chained topology (Node 1 to Node 2 to Node 3).
The panel/api/clients/onlinesByNode endpoint already exists (web/controller/client.go:420) and returns a per-sub-node breakdown. Using it in FetchTrafficSnapshot would help, but Node 1 still has no Node 3 entry in its own database, so a deeper mapping solution would be needed.
Please continue the discussion on #4983.