-
Notifications
You must be signed in to change notification settings - Fork 646
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
Trie refcount bug #2568
Comments
The plan is to fix this by separating trie nodes from different shards in storage - this will also |
Turns out separating shards is not quite enough, because gc code wants to delete multiple blocks in one StoreUpdate. |
I don't understand why this cannot happen on a single shard. It seems that
is not related to the number of shards. |
On betanet I have observed a couple times that rpc nodes crashed on this line https://github.com/nearprotocol/nearcore/blob/b2d469e3da338bf933219ef351cc050075febcd0/neard/src/runtime.rs#L883 However, I have not observed crashing of validator nodes myself, even though one such incident was reported to me by one of the validators. |
@bowenwang1996 TrieUpdate is created for a chunk. Multiple chunks means either multiple shards (fixed by separating tries) or a multi-block StoreUpdate (#2613) |
@mikhailOK is it true that #2613 is possible in a single shard? |
Separate tries from different shards. Each shard has a Trie with its own prefix in storage and its own cache. Fixes #2568 Test plan --------- debug_assert in StoreUpdate::commit
* fix(storage): fix refcount bug Separate tries from different shards. Each shard has a Trie with its own prefix in storage and its own cache. Fixes #2568 Test plan --------- debug_assert in StoreUpdate::commit * rename trie -> tries * gc tests with 1 or 2 shards * get_shard_id_and_hash * refactoring * some renames
This is most likely what causes #2500 #2544 #2556
The text was updated successfully, but these errors were encountered: