Open hsanjuan opened 1 year ago
It seems that the CID is part of receipts hanging from: bafy2bzacecjkbtzobezlbh2lzqgqlrmxnsh2qqbg6qjy47pl2ybfj7s2desre
$ lotus chain getblock bafy2bzacecjkbtzobezlbh2lzqgqlrmxnsh2qqbg6qjy47pl2ybfj7s2desre
...
"ParentReceipts": [
...
{
"ExitCode": 0,
"Return": "QA==",
"GasUsed": 20218807,
"EventsRoot": {
"/": "bafy2bzacecdlvh4udaxpx3motumzj46nms32atnmuxuhusfxcaqzazdrskoso"
}
},
What is EventsRoot ?
Yes. We should be filtering those from the snapshot. I'll take a look.
Ah, I think the difference here is that you're including receipts. Yeah, I'll add another flag there for including events.
Blocks are not decoded though. Is there a way that Lotus stores events so that these links are resolvable? It sounds like events would be a thing to "archive".
Is there a way that Lotus stores events so that these links are resolvable? It sounds like events would be a thing to "archive".
We don't by default because we don't charge for storing them (unlike receipts).
Yeah, I'll add another flag there for including events.
I made an attempt but it required manually decoding the receipts AMT which turned out to be kind of annoying and likely a performance issue. I'd prefer to just say "exporting receipts requires storing events for now.
Hm. Yeah, it would require re-architecting the export system.
I enabled the ETHRPC API and the problematic CID is now there (block on height 2684164.
root@filcryo:~# lotus chain read-obj bafy2bzacecdlvh4udaxpx3motumzj46nms32atnmuxuhusfxcaqzazdrskoso
840500018344010000008081821a001f806684840362743118555820ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef840362743218555820000000000000000000000000000000000000000000000000000000000000000084036274331855582000000000000000000000000049ea66943431c59e57b0e15c40080a34d76593218403627434185558200000000000000000000000000000000000000000000000000000000000000285
However there are others a few epochs later that are not, and things keep failing (height 2685714):
$ lotus chain getblock bafy2bzacec2yagsbtnmq4mvt5rvvtx6sqing6somajskofkp4xc5ifrdouzng
...
{
"ExitCode": 0,
"Return": "WIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADeC2s6dkAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD5a1w==",
"GasUsed": 68158461,
"EventsRoot": {
"/": "bafy2bzacebooa7l2gvwsgi26ban7xxhnx7rvjkqzzfvokowifvrbwhjpybw4c"
}
},
...
$ root@filcryo:~# lotus chain read-obj bafy2bzacebooa7l2gvwsgi26ban7xxhnx7rvjkqzzfvokowifvrbwhjpybw4c
ERROR: blockstore get: ipld: could not find bafy2bzacebooa7l2gvwsgi26ban7xxhnx7rvjkqzzfvokowifvrbwhjpybw4c
Why?
Checklist
Latest release
, the most recent RC(release canadiate) for the upcoming release or the dev branch(master), or have an issue updating to any of these.Lotus component
Lotus Version
Repro Steps
Describe the Bug
Running Lotus on the commit where the 1.20 branch was merged to master, as the
export-range
functionality becomes available then.After many days running fine, on the day next to that of the network upgrade (2023-03-14), performing archival snapshots started failing with unretrievable blocks (that hasn't happened in the history of the chain).
The export process traverses and tries to save all blocks and every DagCBOR Cid referenced from those block.Messages, block.ParentMessageReceipts and blocks.ParentStateRoots (when the blocks are among the specified heights).
Apparently
bafy2bzacecdlvh4udaxpx3motumzj46nms32atnmuxuhusfxcaqzazdrskoso
that is nowhere to be found in the Lotus datastore, despite being referenced from somewhere.Can someone shed some light as to what that might be?
Logging Information