Skip to content
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

RAFS V6 update #242

Merged
merged 9 commits into from
Dec 15, 2021
Merged

RAFS V6 update #242

merged 9 commits into from
Dec 15, 2021

Conversation

hsiangkao
Copy link
Contributor

A patchset addresses v6 implementation regression.

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>

liubogithub and others added 9 commits December 15, 2021 17:32
Commit 58be14a ("storage: fix data corruption when blob's ci
compressor is none") fixed a bug which can be reproduced by this unit
test.

Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
BlobMetaState has a 'chunks' which borrows memory from the mmaped
range over the "${blob_id}.blob.meta" file, since it's created with
ManuallyDrop, we need to munmap explicitly.

Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
It's possible that self.s_meta_blkaddr == 0 and
self.s_xattr_blkaddr != 0 for shared xattr use as RAFS v6 images.

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
If per-file timestamp is no needed, 32-byte inodes can be used
instead as long as the file sizes are smaller than 4GiB and has
16-bit uid, gid.

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
By design, uuid and blob_id in the same union. uuid is not directly
used by RAFS v6. Drop it instead.

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
The encoded sha256 has been used as blobid to locate blob cache files,
this fixes the 32 bytes blobid in RafsV6Device so that we can find the
correct blob files.

Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
Nydus v6 needs "aligned chunk" to make sure kernel fs can read blob
cache files correctly.

Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
Commit b434a3e ("Storage/meta: add munmap for mmaped range")
introduced the regression.

Since the name is quite confusing, this is to clarify it a little bit,
BlobMetaState's [un]compressed_size is used by
get_chunk_[un]compressed() and is considered as file length of a blob,
NOT a blob's ondisk chunk info's size.

Given the above, we are not able to get correct unmap length from
uncompressed_size, this adds a 'unmap_len' for Drop.

Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
Since it's synchronous, the caller needs to be aware of the error if
any.

Signed-off-by: Liu Bo <bo.liu@linux.alibaba.com>
Copy link
Collaborator

@imeoer imeoer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@imeoer imeoer merged commit 488b3fa into dragonflyoss:master Dec 15, 2021
@hsiangkao hsiangkao deleted the v6_update branch December 15, 2021 10:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants