diff options
author | Brian Behlendorf <[email protected]> | 2016-01-11 13:52:17 -0800 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2016-01-11 14:10:31 -0800 |
commit | ab5cbbd1078bf007b50b084bb31fd58c7c5652f4 (patch) | |
tree | 2634570f62c9d3612d61640f5847b8309c0a309b | |
parent | 4d6369c1678d94422cb2fe92c333eb3083191f33 (diff) |
Illumos 6293 - ztest failure: error == 28 (0xc == 0x1c) in ztest_tx_assign()
6293 ztest failure: error == 28 (0xc == 0x1c) in ztest_tx_assign()
Reviewed by: George Wilson <[email protected]>
Reviewed by: Prakash Surya <[email protected]>
Reviewed by: Richard Elling <[email protected]>
Approved by: Richard Lowe <[email protected]>
References:
https://www.illumos.org/issues/6293
https://github.com/illumos/illumos-gate/commit/8fe00bf
Ported-by: Brian Behlendorf <[email protected]>
-rw-r--r-- | module/zfs/arc.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/module/zfs/arc.c b/module/zfs/arc.c index 074163369..c3d88679f 100644 --- a/module/zfs/arc.c +++ b/module/zfs/arc.c @@ -5343,8 +5343,18 @@ arc_init(void) arc_need_free = 0; #endif - /* Set min cache to allow safe operation of arc_adapt() */ + /* + * In userland, there's only the memory pressure that we artificially + * create (see arc_available_memory()). Don't let arc_c get too + * small, because it can cause transactions to be larger than + * arc_c, causing arc_tempreserve_space() to fail. + */ +#ifndef _KERNEL + arc_c_min = arc_c_max / 2; +#else arc_c_min = 2ULL << SPA_MAXBLOCKSHIFT; +#endif + /* Set max to 1/2 of all memory */ arc_c_max = allmem / 2; |