Re: RFC MR: Update btrfs mount options
On 18/05/2025 at 00:23, Nicholas D Steeves wrote:
Pascal Hambourg <pascal@plouf.fr.eu.org> writes:
Mount option descriptions should be added as
partman-basicfilesystems/text/<option> debconf templates, so that they
can be translated. FWIW, `noatime` and `nodiratime` already have
description templates.
Do you mean
partman-basicfilesystems/debian/partman-basicfilesystems.templates which
has this:
Template: partman-basicfilesystems/text/noatime
Type: text
# :sl2:
# Note to translators: Please keep your translations of this string below
# a 65 columns limit (which means 65 characters in single-byte languages)
_Description: noatime - do not update inode access times at each access
?
Yes.
I didn't think that was correct, because this looks like the translation
template that generates the po files (and mount option annotations) for
`partman-basicfilesystems` and not for partman-btrfs.
Currently mount options descriptions for all filesystems are defined in
partman-basicfilesystem templates. Btrfs-specific mount option
descriptions could be added to partman-btrfs templates, but then it
could be troublesome if such option is later implemented in another
filesystem.
It would be best if partman-btrfs can override partman-basicfilesystems's
definitions with a mechanism like `partman-btrfs/debian/partman-btrfs.templates`.
I don't know how cdebconf would deal with multiple definitions of the
same item. Maybe use the first or latest definition ? In either case it
would depend on udebs installation order, so unreliable.
Alternatively, select_mountoptions could be updated to look for
filesystem-specific descriptions first and fallback to
partman-basicfilesystems generic ones.
The problem is that some of the basicfilesystems annotations don't make
sense in a btrfs context. For example, "noatime", which tends to be
essential for btrfs, because btrfs COWs the file rather than updating a
real inode.
IIUC btrfs(5), atime update causes COW only in specific conditions such
as snapshotted or deduplicated files. (Disclaimer: my knwoledge of btrfs
internals is very limited)
Anyway "*atime" are generic mount options and I am not sure that d-i is
the right place to advertise such implementation details.
Will creating a `partman-btrfs/debian/partman-btrfs.templates` just work
or does partman-basicfilesystems need work to have support added?
As I wrote above with a caveat, btrfs-specific mount option descriptions
could be defined in partman-btrfs templates.
If it needs to have support added, is implementing this for trixie a
hard NACK?
I am not the one who can answer to this.
Reply to: