I have
a compressed block that was compressed as per the lz4 algorithm. But it doesn't
have the Frame/Header at the beginning or the footer that contains the content
checksum at the end. I have the original file that was compressed.
I would like to use the "./lz4 -d" command to check the correctness of the compression. My questions are
Thanks a lot Yann, for pointing to the xxhsum.
But I have some other confusion now. Following is the xxd of a compressed file that I compressed using ./lz4 command.
0000000: 0422 4D18 6440 A747 ."M.d@.G
0000008: 0000 8030 3031 3132 ...00112
0000010: 3233 3334 3435 3536 23344556
0000018: 3637 3738 3861 6162 67788aab
0000020: 6263 6364 6465 6566 bccddeef
0000028: 6667 6768 6869 696A fgghhiij
0000030: 6A6B 6B6C 6C6D 6D6E jkkllmmn
0000038: 6E6F 6F70 7071 7172 nooppqqr
0000040: 7273 7374 7475 7576 rssttuuv
0000048: 7677 7778 7879 797A vwwxxyyz
0000050: 7A0A 0000 0000 1864 z......d
0000058: AB40 .@
I believe A7 is the header checksum for this file.
To see if I am using the xxhsum correctly , I grabbed the first 6 bytes of the compressed .lz4 file and dumped it into a file
. So I now have the frame descriptor only without the header checksum. Now when I run the xxhsum on this 6 byte file this is what I see
%xxhsum -H0 myfile.1.lz4.frame.no_HC
7c920c9b myfile.1.lz4.frame.no_HC
The second byte should be a7 but it is 0c . Am I doing something wrong?
Regards.