diff options
author | Brian Behlendorf <[email protected]> | 2012-01-20 10:58:57 -0800 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2012-02-27 08:59:10 -0800 |
commit | 570827e129ed81e066e894530bbe24642f473154 (patch) | |
tree | 90e9128a73735df10392a24280ade08031051b68 /module/zfs/dsl_pool.c | |
parent | 13be560d89e9de63bdf63e8187af2ceb90cf094d (diff) |
Add 'dmu_tx' kstats entry
Keep counters for the various reasons that a thread may end up
in txg_wait_open() waiting on a new txg. This can be useful
when attempting to determine why a particular workload is
under performing.
Signed-off-by: Brian Behlendorf <[email protected]>
Diffstat (limited to 'module/zfs/dsl_pool.c')
-rw-r--r-- | module/zfs/dsl_pool.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/module/zfs/dsl_pool.c b/module/zfs/dsl_pool.c index ba42f0bdd..d428b7ad7 100644 --- a/module/zfs/dsl_pool.c +++ b/module/zfs/dsl_pool.c @@ -517,8 +517,10 @@ dsl_pool_tempreserve_space(dsl_pool_t *dp, uint64_t space, dmu_tx_t *tx) reserved = dp->dp_space_towrite[tx->tx_txg & TXG_MASK] + dp->dp_tempreserved[tx->tx_txg & TXG_MASK] / 2; - if (reserved && reserved > write_limit) + if (reserved && reserved > write_limit) { + DMU_TX_STAT_BUMP(dmu_tx_write_limit); return (ERESTART); + } } atomic_add_64(&dp->dp_tempreserved[tx->tx_txg & TXG_MASK], space); |