From ecf62d926ed6b6d66bf07939a742adee15de09ed Mon Sep 17 00:00:00 2001 From: David Sterba Date: Thu, 20 Mar 2025 17:29:52 +0100 Subject: [PATCH] btrfs-progs: docs: various fixups and updates [ci skip] Signed-off-by: David Sterba --- Documentation/btrfs-filesystem.rst | 12 ++++++++++-- Documentation/btrfs-inspect-internal.rst | 6 +++--- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/Documentation/btrfs-filesystem.rst b/Documentation/btrfs-filesystem.rst index 92303202..8b99df82 100644 --- a/Documentation/btrfs-filesystem.rst +++ b/Documentation/btrfs-filesystem.rst @@ -12,7 +12,7 @@ DESCRIPTION :command:`btrfs filesystem` is used to perform several whole filesystem level tasks, including all the regular filesystem operations like resizing, space stats, label setting/getting, and defragmentation. There are other whole filesystem -tasks like scrub or balance that are grouped in separate commands. +tasks like scrub or balance that are grouped in separate commands (:doc:`btrfs-scrub`, :doc:`btrfs-balance`). SUBCOMMAND ---------- @@ -83,7 +83,7 @@ df [options] defragment [options] | [|...] Defragment file data on a mounted filesystem. Requires kernel 2.6.33 and newer. - If *-r* is passed, files in dir will be defragmented recursively (not + If *-r* is passed, files in *dir* will be defragmented recursively (not descending to subvolumes, mount points and directory symlinks). The start position and the number of bytes to defragment can be specified by start and length using *-s* and *-l* options below. @@ -117,6 +117,13 @@ defragment [options] | [|...] algorithm, *zlib* (default), *lzo* or *zstd*. Currently it's not possible to select no compression. See also section *EXAMPLES*. + -L|--level + Since kernel 6.14 the compresison can also take the level parameter which will be used + only for the defragmentation and overrides the eventual mount option compression level. + Valid levels depend on the compression algorithms: *zlib* + 1..9, *lzo* does not have any levels, *zstd* the standard levels 1..15 and also the + realtime -1..-15. + -r defragment files recursively in given directories, does not descend to subvolumes or mount points @@ -143,6 +150,7 @@ defragment [options] | [|...] Perform defragmentation in the range in SIZE steps and flush (*-f*) after each one. The range is default (the whole file) or given by *-s* and *-l*, split into the steps or done in one go if the step is larger. Minimum range size is 256KiB. + With verbosity options the progress of defragmentation will be also printed. -v (deprecated) alias for global *-v* option diff --git a/Documentation/btrfs-inspect-internal.rst b/Documentation/btrfs-inspect-internal.rst index df759a77..d9257b04 100644 --- a/Documentation/btrfs-inspect-internal.rst +++ b/Documentation/btrfs-inspect-internal.rst @@ -164,7 +164,7 @@ logical-resolve [-Pvo] [-s ] to be obtained by other means. -s set internal buffer for storing the file names to *bufsize*, default is 64KiB, - maximum 16MiB. Buffer sizes over 64Kib require kernel support for the V2 ioctl + maximum 16MiB. Buffer sizes over 64KiB require kernel support for the V2 ioctl (added in 4.15). -v (deprecated) alias for global *-v* option @@ -225,7 +225,7 @@ list-chunks [options] --sort MODE sort by a column (ascending): - MODE is a coma separated list of: + MODE is a comma separated list of: *devid* - by device id (default, with pstart) @@ -272,7 +272,7 @@ map-swapfile [options] ``Options`` -r|--resume-offset - print only the value suitable as resume offset for file */sys/power/resume_offset* + print only the value suitable as resume offset for file :file:`/sys/power/resume_offset` min-dev-size [options] (needs root privileges)