zfsonlinux/zfs — pull request #2542 by dweeezil (2014-07-26 16:16:33+00:00)
Title: Illumos 3835

Illumos 3835 zfs need not store 2 copies of all metadata

Reviewed by: George Wilson
Reviewed by: Adam Leventhal
Reviewed by: Dan McDonald
Approved by: Richard Lowe
Ported by: Tim Chase

Description from Matt Ahrens's bug report at Delphix:

Add a new zfs property, "redundant_metadata" which can have values
"all" or "most". The default will be "all", which is the current
behavior. Setting to "most" will cause us to only store 1 copy of
level-1 indirect blocks of user data files.

Additional notes:

The new man page section for this property states

"The exact behavior of which metadata blocks
are stored redundantly may change in future releases."

and:

"When set to most, ZFS stores an extra copy of most types of
metadata. This can improve performance of random writes,
because less metadata must be written."

The current implementation is as described above in Matt's blog.
It is controlled by a new global integer
"zfs_redundant_metadata_most_ditto_level", currently initialized
to 2. When "redundant_metadata" is set to "most", only indirect
blocks of the specified level and higher will have additional ditto
blocks created.