Niccolò Belli posted on Mon, 28 Nov 2016 12:11:49 +0100 as excerpted: > On lunedì 28 novembre 2016 09:20:15 CET, Kai Krakow wrote: >> You can, however, use chattr to make the subvolume root directory (that >> one where it is mounted) nodatacow (chattr +C) _before_ placing any >> files or directories in there. That way, newly created files and >> directories will inherit the flag. Take note that this flag can only >> applied to directories and empty (zero-sized) files. > > Do I keep checksumming for this directory such a way?
No. Keeping checksums current on NOCOW files is racy, and compression would be complex as well because rewritten data may compress more or less well than the original so the on-filesystem size could change, so both features are disabled in the presence of NOCOW, regardless of how it is set. Put another way, btrfs assumes COW by default and many of its features depend on COW -- that's why these features don't tend to be implemented on conventional rewrite-in-place filesystems in the first place. Both checksumming and compression are among these COW-dependent features. -- Duncan - List replies preferred. No HTML msgs. "Every nonfree program has a lord, a master -- and if you use the program, he is your master." Richard Stallman -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html