summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlek P <[email protected]>2017-09-29 15:58:52 -0700
committerBrian Behlendorf <[email protected]>2017-09-29 15:58:52 -0700
commit01ff0d7540b21c461c19b90b1e715df26cba3ff2 (patch)
tree72ba39c82ee2a232b878d9edf51bb2812fbe467f
parente71cade67d48495db46fb6eed29b88b895bcb2d8 (diff)
Update the default for zfs_txg_history
It's often useful to have access to txg history for debugging purposes. This patch changes the default from 0 to 100 TXGs worth of history preserved. Reviewed by: Matthew Ahrens <[email protected]> Reviewed-by: Giuseppe Di Natale <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Reviewed by: Richard Elling <[email protected]> Reviewed by: Prakash Surya <[email protected]> Reviewed-by: George Melikov <[email protected]> Signed-off-by: Alek Pinchuk <[email protected]> Closes #6691
-rw-r--r--man/man5/zfs-module-parameters.54
-rw-r--r--module/zfs/spa_stats.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/man/man5/zfs-module-parameters.5 b/man/man5/zfs-module-parameters.5
index 6e04b4977..19ecde4f4 100644
--- a/man/man5/zfs-module-parameters.5
+++ b/man/man5/zfs-module-parameters.5
@@ -12,7 +12,7 @@
.\" CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your
.\" own identifying information:
.\" Portions Copyright [yyyy] [name of copyright owner]
-.TH ZFS-MODULE-PARAMETERS 5 "Nov 16, 2013"
+.TH ZFS-MODULE-PARAMETERS 5 "Sept 28, 2017"
.SH NAME
zfs\-module\-parameters \- ZFS module parameters
.SH DESCRIPTION
@@ -1766,7 +1766,7 @@ Default value: \fB32\fR.
Historical statistics for the last N txgs will be available in
\fB/proc/spl/kstat/zfs/<pool>/txgs\fR
.sp
-Default value: \fB0\fR.
+Default value: \fB100\fR.
.RE
.sp
diff --git a/module/zfs/spa_stats.c b/module/zfs/spa_stats.c
index 8c4dba29e..3eeb83a50 100644
--- a/module/zfs/spa_stats.c
+++ b/module/zfs/spa_stats.c
@@ -34,9 +34,9 @@ int zfs_read_history = 0;
int zfs_read_history_hits = 0;
/*
- * Keeps stats on the last N txgs, disabled by default.
+ * Keeps stats on the last 100 txgs by default.
*/
-int zfs_txg_history = 0;
+int zfs_txg_history = 100;
/*
* Keeps stats on the last N MMP updates, disabled by default.