[lustre-devel] [EXTERNAL] Re: Inquiry Regarding Checksum Support for Lustre Extended Attributes
Andreas Dilger
adilger at whamcloud.com
Tue Jun 25 13:35:39 PDT 2024
As you have seen, it is *not* possible to enable metadata_csum on the MDT because this feature interacts poorly with another feature that Lustre needs (dirdata) on the MDT. It _may_ be possible to enable metadata_csum on OSTs since it does not need the dirdata feature, though we haven't tested this. There is an older ticket open in Jira LU-13650<https://jira.whamcloud.com/browse/LU-13650> that relates to enabling the metadata_csum feature, but I see that it is quite sparse on details of what is not working and what is needed to fix it.
If this is something that you would be interested to fix, then I think we could work together with the appropriate developers to understand the details and update the ldiskfs dirdata patch to work properly with metadata_csum, and you could make a lasting contribution to Lustre that will (eventually) also make its way into ext4. Probably LU-13650<https://jira.whamcloud.com/browse/LU-13650> would be the right forum for this, rather than getting into the gritty details of the code on this list. If you could create a Jira account and add yourself as a watcher on this ticket, please post the details (error messages, symptoms) into Jira.
Thanks for your interest in Lustre.
Cheers, Andreas
On Jun 25, 2024, at 05:38, Saisha Kamat <skamat1 at charlotte.edu<mailto:skamat1 at charlotte.edu>> wrote:
Hello,
Thank you for your previous response.
I have a question regarding the integration of ext4 metadata checksumming with Lustre. Specifically, I am interested in enabling metadata check summing on a Lustre file system backed by ldiskfs.
For context, I have a Lustre filesystem on /dev/sda, which is formatted as ldiskfs (MDS). I used the command tune2fs -O metadata_csum /dev/sda to enable metadata checksumming. However, after enabling this feature, I am unable to mount the Lustre filesystem (MDS node).
Could you please advise if there is a way to enable metadata check summing on the underlying ext4 filesystem and successfully mount the Lustre MDS or OSS nodes on the same device? Are there specific steps or configurations required to achieve this?
Thank you for your assistance and time.
Thanks and regards,
Saisha
On Wed, Jun 12, 2024 at 6:27 PM Andreas Dilger <adilger at whamcloud.com<mailto:adilger at whamcloud.com>> wrote:
[Caution: Email from External Sender. Do not click or open links or attachments unless you know this sender.]
On Jun 12, 2024, at 12:35, Saisha Kamat via lustre-devel <lustre-devel at lists.lustre.org<mailto:lustre-devel at lists.lustre.org>> wrote:
Hello,
I hope this email finds you well.
My name is Saisha, and I am currently pursuing my Ph.D. at UNC-Charlotte, with a focus on research related to the Lustre File System. As part of my project, I am exploring the possibility of utilizing checksums to verify Lustre extended attributes.
My understanding is that the ext4 file system supports checksums for extended attributes (xattrs). However, I am interested in whether this functionality extends to Lustre as well.
Yes, the ext4 (and ZFS) xattr values have checksums. No, the xattr checksums are neither managed or verified by Lustre, and only come into effect when they are passed on to the backing filesystem. Conceivably, it would be possible to have a checksum (e.g. crc32c) for the xattr values in the MDS_GETXATTR and MDS_SETXATTR RPCs, if this is something you are interested to contribute.
This could probably be done by overloading one of the 32-bit fields in the mdt_body for getxattr, and one in mdt_rec_reint for setxattr, but there is also "opportunistic" xattr prefetching done in the lookup RPC, so that would need to be covered as well.
Also, the checksum would also need to be kept with the xattrs in cache and verified on access, otherwise they could become corrupted in memory after the RPC processing had completed.
Finally, there is no interface to specify or verify the xattr checksum in the syscall interface, so there can be no guarantee that the data supplied in the setxattr is correct, or remains correct after supplied to getxattr, but the window there is very small.
Cheers, Andreas
I would greatly appreciate it if you could provide some insights or direct me to relevant documentation on this matter. Any information or guidance you can offer would be invaluable to my research.
Thank you very much for your time and assistance.
Thanks and Regards,
Saisha
_______________________________________________
lustre-devel mailing list
lustre-devel at lists.lustre.org<mailto:lustre-devel at lists.lustre.org>
http://lists.lustre.org/listinfo.cgi/lustre-devel-lustre.org
Cheers, Andreas
--
Andreas Dilger
Lustre Principal Architect
Whamcloud
Cheers, Andreas
--
Andreas Dilger
Lustre Principal Architect
Whamcloud
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lustre.org/pipermail/lustre-devel-lustre.org/attachments/20240625/c6a57eb7/attachment-0001.htm>
More information about the lustre-devel
mailing list