[2/8] man: document the xfs_db btheight command
diff mbox series

Message ID 157982500443.2765410.17401149852075835578.stgit@magnolia
State Accepted
Headers show
  • xfsprogs: random fixes
Related show

Commit Message

Darrick J. Wong Jan. 24, 2020, 12:16 a.m. UTC
From: Darrick J. Wong <darrick.wong@oracle.com>

Document the btheight command in xfs_db.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
 man/man8/xfs_db.8 |   39 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)


Christoph Hellwig Jan. 25, 2020, 11:16 p.m. UTC | #1
Looks good,

Reviewed-by: Christoph Hellwig <hch@lst.de>

diff mbox series

diff --git a/man/man8/xfs_db.8 b/man/man8/xfs_db.8
index a1ee3514..53e34983 100644
--- a/man/man8/xfs_db.8
+++ b/man/man8/xfs_db.8
@@ -346,6 +346,45 @@  If the cursor points at an inode, dump the extended attribute block mapping btre
 Dump all keys and pointers in intermediate btree nodes, and all records in leaf btree nodes.
+.BI "btheight [\-b " blksz "] [\-n " recs "] [\-w " max "|\-w " min "] btree types..."
+For a given number of btree records and a btree type, report the number of
+records and blocks for each level of the btree, and the total number of blocks.
+The btree type must be given after the options.
+A raw btree geometry can be provided in the format
+"record_bytes:key_bytes:ptr_bytes:header_type", where header_type is one of
+"short", "long", "shortcrc", or "longcrc".
+The supported btree types are:
+.IR bnobt ,
+.IR cntbt ,
+.IR inobt ,
+.IR finobt ,
+.IR bmapbt ,
+.IR refcountbt ,
+.IR rmapbt .
+Options are as follows:
+.RS 1.0i
+.TP 0.4i
+.B \-b
+is used to override the btree block size.
+The default is the filesystem block size.
+.B \-n
+is used to specify the number of records to store.
+This argument is required.
+.B \-w max
+shows only the best case scenario, which is when the btree blocks are
+maximally loaded.
+.B \-w min
+shows only the worst case scenario, which is when the btree blocks are
+half full.
 .B check
 See the
 .B blockget