aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorNed Bass <[email protected]>2014-02-27 16:32:36 -0800
committerBrian Behlendorf <[email protected]>2014-03-04 12:22:24 -0800
commit3ccab25205cc8836ceb79bbd164208021468233a (patch)
treec16c14ea1aea2c71364df3b6efa213c8ba7f4c11 /include
parent3d920a1567d550273413a741c5fbece42cea6f00 (diff)
replace nreserved with ndirty in txgs kstat
The nreserved column in the txgs kstat file always contains 0 following the write throttle restructuring of commit e8b96c6007bf97cdf34869c1ffbd0ce753873a3d. Prior to that commit, the nreserved column showed the number of bytes temporarily reserved in the pool by a transaction group at sync time. The new write throttle did away with temporary reservations and uses the amount of dirty data instead. To approximate the old output of the txgs kstat, the number of dirty bytes per-txg was passed in as the nreserved value to spa_txg_history_set_io(). This approach did not work as intended, because the per-txg dirty value is decremented as data is written out to disk, so it is zero by the time we call spa_txg_history_set_io(). To fix this, save the number of dirty bytes before calling spa_sync(), and pass this value in to spa_txg_history_set_io(). Also, since the name "nreserved" is now a misnomer, the column heading is now labeled "ndirty". Signed-off-by: Ned Bass <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Issue #1696
Diffstat (limited to 'include')
-rw-r--r--include/sys/spa.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/sys/spa.h b/include/sys/spa.h
index e7cbff806..d5a91c2d3 100644
--- a/include/sys/spa.h
+++ b/include/sys/spa.h
@@ -570,7 +570,7 @@ extern void spa_txg_history_add(spa_t *spa, uint64_t txg, hrtime_t birth_time);
extern int spa_txg_history_set(spa_t *spa, uint64_t txg,
txg_state_t completed_state, hrtime_t completed_time);
extern int spa_txg_history_set_io(spa_t *spa, uint64_t txg, uint64_t nread,
- uint64_t nwritten, uint64_t reads, uint64_t writes, uint64_t nreserved);
+ uint64_t nwritten, uint64_t reads, uint64_t writes, uint64_t ndirty);
extern void spa_tx_assign_add_nsecs(spa_t *spa, uint64_t nsecs);
/* Pool configuration locks */