-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Retrieval truncates car file causing - ERROR: given data does not match expected commP - on import #8663
Comments
can you maybe reformat your message, its really hard to read like this |
Hey @scaseye Thank you for your detailed report. As @RobQuistNL mentioned, this is now rather difficult to make sense of. Can you please either reformat the original post or create a new ticket. Many thanks! |
i have no idea how the strike through text formatting is there... i tried to clean up hope that helps |
Wrap it in backticks; ` |
@RobQuistNL happy? :) |
Oops, seems like we needed more information for this issue, please comment with more details or this issue will be closed in 24 hours. |
I see the same issue with EverGreen generated deals:
From
|
@ribasushi also reported this: I ran the exact command you gave me from f01345523 above, the result matches all CommPCid: baga6ea4seaqorn5ftgybsjgworvsrzwr5pzmgpyidwdakdrbliasjoe6b6y5mpi CARv1 detected in stream: |
What @stuberman and I ran/downloaded are:
I ran only the first one and got the correct car ( @stuberman ran both and got a corrupted file both times I suspect (only suspect) a corrupted blockstore with the hash verification somehow not firing, always resulting in the incorrect output, since the local bad block is reused. |
@ribasushi I was able to download the file without any problems and md5sum is the same as above. I used only first method. Let me know if you want me to test the second as well. |
Relevant thread in slack: https://filecoinproject.slack.com/archives/C0377FJCG1L/p1657019175554179 Observation:
|
Thanks @jacobheun for connecting the dots to this issue. Over @ filecoin-project/boost#715 (comment) I outlined a scenario that could cause this problem—retrieving an entire piece and not getting a byte-perfect CAR that can generate the same CommP that was used to store it in the first place. The fix should be to add
The big problem here is that it's not actually obvious what the "right" behaviour is. But we do know what the historical precedent is so we should probably just follow that and bake it into well-documented specs. |
Closing this ticket as the Legacy Lotus/Lotus-Miner Markets sub-system reached EOL at the end of the 31st January 2023, and is being completely removed from the code here: |
Checklist
Latest release
, or 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
Describe the Bug
lotus client retrieve --provider f09848 --maxPrice 0 --allow-local --car 'QmSEQBHK9n52iZUFYRWs95bUbbd4o8dftUWMGYgE8wW2fc'
$(pwd)/baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
downloads a car file that does not match the original car file, and thus generates the mismatched commP.
This is what lotus retrieved...
$
ls -l baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
-rw-r--r-- 1 scaseye scaseye 6436657574 May 16 11:47 baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
$
sha256sum baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
1a09d2a3703da1dc47920bf293924ac67e0dcb9e48f23ece7799d1f589cae2f2 baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
$
go/bin/stream-commp < baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
$
lotus-miner storage-deals import-data bafyreihvlxsjvaxlye3ugtaz4q4zuejpddu4u2uuhwr7nmwoqrodbqufbu $(pwd)/baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
ERROR: given data does not match expected commP (got: baga6ea4seaqlxgfjrxftuymz4khfpyrnpp6korwssctvnbnpp62ng4v6adlp4ba, expected baga6ea4seaqarmfjs4i554ghukgg6dqwp7vrpinxqtdn7oyupbiqjkltqzeo2ji)
$
tail -c 16 baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car | hexdump -C
$
head -c 128 baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car | hexdump -C
This is what it should have been
$
ls -l baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
-rw-r--r-- 1 lotus lotus 6436657579 May 16 17:15 baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
$
sha256sum baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
bfdacf77179631286a48c8eb8f62b33596404ae42b7dab752ec825b2d92b1025 baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
$
go/bin/stream-commp < baga6e~tqzeo2ji__QmSEQB~gE8wW2fc.car
Logging Information
Repo Steps
...
The text was updated successfully, but these errors were encountered: