Improve GC routine #1225

Open
opened 2025-12-28 17:22:15 +00:00 by sami · 2 comments
Owner

Originally created by @carpawell on GitHub (Jun 10, 2024).

GC may be more intelligent. Currently, it only works with clear wording like "a user deleted an object" or "epoch N happened, so every object whose expiration is <= N-1 should expire too". But sometimes real garbage may appear in the storages (bad migration, shard error, bugs, configuration changes, missed meta change notification etc), and some background routine may try to monitor it.

Describe the solution you'd like

If some object without a container, lost object part, or some other object that should not exist is found, it should be GC-ed. A background routine fits well for this.

Describe alternatives you've considered

Some explicit external command like vacuum in the control service.

Additional context

https://github.com/nspcc-dev/neofs-node/issues/2858 happened and there is a fix for it :https://github.com/nspcc-dev/neofs-node/pull/2863. However, it does not solve the problem fully: if some parts are stored and no parent header is found, it will never be GC-ed now.
It should be solved carefully. Situations, when a node believes that there is no object in the network, should be proved.

Originally created by @carpawell on GitHub (Jun 10, 2024). ## Is your feature request related to a problem? Please describe. GC may be more intelligent. Currently, it only works with clear wording like "a user deleted an object" or "epoch N happened, so every object whose expiration is <= N-1 should expire too". But sometimes real garbage may appear in the storages (bad migration, shard error, bugs, configuration changes, missed meta change notification etc), and some background routine may try to monitor it. ## Describe the solution you'd like If some object without a container, lost object part, or some other object that should not exist is found, it should be GC-ed. A background routine fits well for this. ## Describe alternatives you've considered Some explicit external command like `vacuum` in the control service. ## Additional context https://github.com/nspcc-dev/neofs-node/issues/2858 happened and there is a fix for it :https://github.com/nspcc-dev/neofs-node/pull/2863. However, it does not solve the problem fully: if some parts are stored and no parent header is found, it will never be GC-ed now. It should be solved carefully. Situations, when a node believes that there is _no_ object in the network, should be proved.
Author
Owner

@roman-khimov commented on GitHub (Jun 11, 2024):

We have replicator that goes over the object list all the time, it can notice inconsistencies, it can invalidate objects (trying to replicate them is an error anyway).

@roman-khimov commented on GitHub (Jun 11, 2024): We have replicator that goes over the object list all the time, it can notice inconsistencies, it can invalidate objects (trying to replicate them is an error anyway).
Author
Owner

@roman-khimov commented on GitHub (Sep 23, 2025):

Related to #394, if we're to think of that one as a metabase-level scrubber then this one is a storage-level thing.

@roman-khimov commented on GitHub (Sep 23, 2025): Related to #394, if we're to think of that one as a metabase-level scrubber then this one is a storage-level thing.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
nspcc-dev/neofs-node#1225
No description provided.