mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[GH-ISSUE #4763] [Bug]: Deleting NODES doesn't remove connections or clients or inbounds #3301
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#3301
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 @Osairs on GitHub (Jun 1, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/4763
Describe the bug
After deleting the NODES all clients, connection and inbounds from other node still showing up in main node even so there are no connection between it anymore.
How to reproduce the problem
add node, make sure it sync and snowing all connections and clients from other node. go to NODE and delete connected node. (refresh, relog)
Expected behavior
No response
Actual behavior
No response
Relevant logs
Screenshots
No response
3x-ui version
3.2.5
Xray-core version
26.6.1
How did you install 3x-ui?
Other (please describe in the bug body)
Operating system
Unbutu 24.4
Which parts of the panel are affected?
No response
Browser (only if it is a UI bug)
Chome 148
Is the panel behind a reverse proxy or CDN?
No — direct access
Before submitting
@github-actions[bot] commented on GitHub (Jun 1, 2026):
Thanks for the detailed report!
This is a confirmed bug. When a node is deleted, the code in
web/service/node.go(NodeService.Delete) only removes the node record from the database and drops its in-memory connection — it does not cascade-delete the inbounds and clients that were synced from that node (those rows have anode_idcolumn pointing to the deleted node). As a result, those orphaned inbounds and clients remain visible on the main panel.Workaround (until a fix is released):
Before deleting a node, you can manually remove its synced inbounds from the main panel's Inbounds page. Look for inbounds that display the node's name/tag in the node column and delete them first. This ensures their associated clients are also cleaned up before the node itself is removed.
Root cause (for developers):
The fix would require
NodeService.Deleteto also delete all inbounds (and their clients) wherenode_id = <deleted node id>— similar to how the inbound service already queriesWHERE node_id IS NOT NULLin several places.We'll leave this open for a maintainer to implement the cascade cleanup. If you'd like to contribute a fix, a PR is very welcome!