]> git.proxmox.com Git - mirror_zfs.git/blob - man/man5/zfs-module-parameters.5
QAT support for AES-GCM
[mirror_zfs.git] / man / man5 / zfs-module-parameters.5
1 '\" te
2 .\" Copyright (c) 2013 by Turbo Fredriksson <turbo@bayour.com>. All rights reserved.
3 .\" Copyright (c) 2017 Datto Inc.
4 .\" The contents of this file are subject to the terms of the Common Development
5 .\" and Distribution License (the "License"). You may not use this file except
6 .\" in compliance with the License. You can obtain a copy of the license at
7 .\" usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
8 .\"
9 .\" See the License for the specific language governing permissions and
10 .\" limitations under the License. When distributing Covered Code, include this
11 .\" CDDL HEADER in each file and include the License file at
12 .\" usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this
13 .\" CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your
14 .\" own identifying information:
15 .\" Portions Copyright [yyyy] [name of copyright owner]
16 .TH ZFS-MODULE-PARAMETERS 5 "Oct 28, 2017"
17 .SH NAME
18 zfs\-module\-parameters \- ZFS module parameters
19 .SH DESCRIPTION
20 .sp
21 .LP
22 Description of the different parameters to the ZFS module.
23
24 .SS "Module parameters"
25 .sp
26 .LP
27
28 .sp
29 .ne 2
30 .na
31 \fBignore_hole_birth\fR (int)
32 .ad
33 .RS 12n
34 When set, the hole_birth optimization will not be used, and all holes will
35 always be sent on zfs send. Useful if you suspect your datasets are affected
36 by a bug in hole_birth.
37 .sp
38 Use \fB1\fR for on (default) and \fB0\fR for off.
39 .RE
40
41 .sp
42 .ne 2
43 .na
44 \fBl2arc_feed_again\fR (int)
45 .ad
46 .RS 12n
47 Turbo L2ARC warm-up. When the L2ARC is cold the fill interval will be set as
48 fast as possible.
49 .sp
50 Use \fB1\fR for yes (default) and \fB0\fR to disable.
51 .RE
52
53 .sp
54 .ne 2
55 .na
56 \fBl2arc_feed_min_ms\fR (ulong)
57 .ad
58 .RS 12n
59 Min feed interval in milliseconds. Requires \fBl2arc_feed_again=1\fR and only
60 applicable in related situations.
61 .sp
62 Default value: \fB200\fR.
63 .RE
64
65 .sp
66 .ne 2
67 .na
68 \fBl2arc_feed_secs\fR (ulong)
69 .ad
70 .RS 12n
71 Seconds between L2ARC writing
72 .sp
73 Default value: \fB1\fR.
74 .RE
75
76 .sp
77 .ne 2
78 .na
79 \fBl2arc_headroom\fR (ulong)
80 .ad
81 .RS 12n
82 How far through the ARC lists to search for L2ARC cacheable content, expressed
83 as a multiplier of \fBl2arc_write_max\fR
84 .sp
85 Default value: \fB2\fR.
86 .RE
87
88 .sp
89 .ne 2
90 .na
91 \fBl2arc_headroom_boost\fR (ulong)
92 .ad
93 .RS 12n
94 Scales \fBl2arc_headroom\fR by this percentage when L2ARC contents are being
95 successfully compressed before writing. A value of 100 disables this feature.
96 .sp
97 Default value: \fB200\fR%.
98 .RE
99
100 .sp
101 .ne 2
102 .na
103 \fBl2arc_noprefetch\fR (int)
104 .ad
105 .RS 12n
106 Do not write buffers to L2ARC if they were prefetched but not used by
107 applications
108 .sp
109 Use \fB1\fR for yes (default) and \fB0\fR to disable.
110 .RE
111
112 .sp
113 .ne 2
114 .na
115 \fBl2arc_norw\fR (int)
116 .ad
117 .RS 12n
118 No reads during writes
119 .sp
120 Use \fB1\fR for yes and \fB0\fR for no (default).
121 .RE
122
123 .sp
124 .ne 2
125 .na
126 \fBl2arc_write_boost\fR (ulong)
127 .ad
128 .RS 12n
129 Cold L2ARC devices will have \fBl2arc_write_max\fR increased by this amount
130 while they remain cold.
131 .sp
132 Default value: \fB8,388,608\fR.
133 .RE
134
135 .sp
136 .ne 2
137 .na
138 \fBl2arc_write_max\fR (ulong)
139 .ad
140 .RS 12n
141 Max write bytes per interval
142 .sp
143 Default value: \fB8,388,608\fR.
144 .RE
145
146 .sp
147 .ne 2
148 .na
149 \fBmetaslab_aliquot\fR (ulong)
150 .ad
151 .RS 12n
152 Metaslab granularity, in bytes. This is roughly similar to what would be
153 referred to as the "stripe size" in traditional RAID arrays. In normal
154 operation, ZFS will try to write this amount of data to a top-level vdev
155 before moving on to the next one.
156 .sp
157 Default value: \fB524,288\fR.
158 .RE
159
160 .sp
161 .ne 2
162 .na
163 \fBmetaslab_bias_enabled\fR (int)
164 .ad
165 .RS 12n
166 Enable metaslab group biasing based on its vdev's over- or under-utilization
167 relative to the pool.
168 .sp
169 Use \fB1\fR for yes (default) and \fB0\fR for no.
170 .RE
171
172 .sp
173 .ne 2
174 .na
175 \fBzfs_metaslab_segment_weight_enabled\fR (int)
176 .ad
177 .RS 12n
178 Enable/disable segment-based metaslab selection.
179 .sp
180 Use \fB1\fR for yes (default) and \fB0\fR for no.
181 .RE
182
183 .sp
184 .ne 2
185 .na
186 \fBzfs_metaslab_switch_threshold\fR (int)
187 .ad
188 .RS 12n
189 When using segment-based metaslab selection, continue allocating
190 from the active metaslab until \fBzfs_metaslab_switch_threshold\fR
191 worth of buckets have been exhausted.
192 .sp
193 Default value: \fB2\fR.
194 .RE
195
196 .sp
197 .ne 2
198 .na
199 \fBmetaslab_debug_load\fR (int)
200 .ad
201 .RS 12n
202 Load all metaslabs during pool import.
203 .sp
204 Use \fB1\fR for yes and \fB0\fR for no (default).
205 .RE
206
207 .sp
208 .ne 2
209 .na
210 \fBmetaslab_debug_unload\fR (int)
211 .ad
212 .RS 12n
213 Prevent metaslabs from being unloaded.
214 .sp
215 Use \fB1\fR for yes and \fB0\fR for no (default).
216 .RE
217
218 .sp
219 .ne 2
220 .na
221 \fBmetaslab_fragmentation_factor_enabled\fR (int)
222 .ad
223 .RS 12n
224 Enable use of the fragmentation metric in computing metaslab weights.
225 .sp
226 Use \fB1\fR for yes (default) and \fB0\fR for no.
227 .RE
228
229 .sp
230 .ne 2
231 .na
232 \fBmetaslabs_per_vdev\fR (int)
233 .ad
234 .RS 12n
235 When a vdev is added, it will be divided into approximately (but no more than) this number of metaslabs.
236 .sp
237 Default value: \fB200\fR.
238 .RE
239
240 .sp
241 .ne 2
242 .na
243 \fBmetaslab_preload_enabled\fR (int)
244 .ad
245 .RS 12n
246 Enable metaslab group preloading.
247 .sp
248 Use \fB1\fR for yes (default) and \fB0\fR for no.
249 .RE
250
251 .sp
252 .ne 2
253 .na
254 \fBmetaslab_lba_weighting_enabled\fR (int)
255 .ad
256 .RS 12n
257 Give more weight to metaslabs with lower LBAs, assuming they have
258 greater bandwidth as is typically the case on a modern constant
259 angular velocity disk drive.
260 .sp
261 Use \fB1\fR for yes (default) and \fB0\fR for no.
262 .RE
263
264 .sp
265 .ne 2
266 .na
267 \fBspa_config_path\fR (charp)
268 .ad
269 .RS 12n
270 SPA config file
271 .sp
272 Default value: \fB/etc/zfs/zpool.cache\fR.
273 .RE
274
275 .sp
276 .ne 2
277 .na
278 \fBspa_asize_inflation\fR (int)
279 .ad
280 .RS 12n
281 Multiplication factor used to estimate actual disk consumption from the
282 size of data being written. The default value is a worst case estimate,
283 but lower values may be valid for a given pool depending on its
284 configuration. Pool administrators who understand the factors involved
285 may wish to specify a more realistic inflation factor, particularly if
286 they operate close to quota or capacity limits.
287 .sp
288 Default value: \fB24\fR.
289 .RE
290
291 .sp
292 .ne 2
293 .na
294 \fBspa_load_verify_data\fR (int)
295 .ad
296 .RS 12n
297 Whether to traverse data blocks during an "extreme rewind" (\fB-X\fR)
298 import. Use 0 to disable and 1 to enable.
299
300 An extreme rewind import normally performs a full traversal of all
301 blocks in the pool for verification. If this parameter is set to 0,
302 the traversal skips non-metadata blocks. It can be toggled once the
303 import has started to stop or start the traversal of non-metadata blocks.
304 .sp
305 Default value: \fB1\fR.
306 .RE
307
308 .sp
309 .ne 2
310 .na
311 \fBspa_load_verify_metadata\fR (int)
312 .ad
313 .RS 12n
314 Whether to traverse blocks during an "extreme rewind" (\fB-X\fR)
315 pool import. Use 0 to disable and 1 to enable.
316
317 An extreme rewind import normally performs a full traversal of all
318 blocks in the pool for verification. If this parameter is set to 0,
319 the traversal is not performed. It can be toggled once the import has
320 started to stop or start the traversal.
321 .sp
322 Default value: \fB1\fR.
323 .RE
324
325 .sp
326 .ne 2
327 .na
328 \fBspa_load_verify_maxinflight\fR (int)
329 .ad
330 .RS 12n
331 Maximum concurrent I/Os during the traversal performed during an "extreme
332 rewind" (\fB-X\fR) pool import.
333 .sp
334 Default value: \fB10000\fR.
335 .RE
336
337 .sp
338 .ne 2
339 .na
340 \fBspa_slop_shift\fR (int)
341 .ad
342 .RS 12n
343 Normally, we don't allow the last 3.2% (1/(2^spa_slop_shift)) of space
344 in the pool to be consumed. This ensures that we don't run the pool
345 completely out of space, due to unaccounted changes (e.g. to the MOS).
346 It also limits the worst-case time to allocate space. If we have
347 less than this amount of free space, most ZPL operations (e.g. write,
348 create) will return ENOSPC.
349 .sp
350 Default value: \fB5\fR.
351 .RE
352
353 .sp
354 .ne 2
355 .na
356 \fBzfetch_array_rd_sz\fR (ulong)
357 .ad
358 .RS 12n
359 If prefetching is enabled, disable prefetching for reads larger than this size.
360 .sp
361 Default value: \fB1,048,576\fR.
362 .RE
363
364 .sp
365 .ne 2
366 .na
367 \fBzfetch_max_distance\fR (uint)
368 .ad
369 .RS 12n
370 Max bytes to prefetch per stream (default 8MB).
371 .sp
372 Default value: \fB8,388,608\fR.
373 .RE
374
375 .sp
376 .ne 2
377 .na
378 \fBzfetch_max_streams\fR (uint)
379 .ad
380 .RS 12n
381 Max number of streams per zfetch (prefetch streams per file).
382 .sp
383 Default value: \fB8\fR.
384 .RE
385
386 .sp
387 .ne 2
388 .na
389 \fBzfetch_min_sec_reap\fR (uint)
390 .ad
391 .RS 12n
392 Min time before an active prefetch stream can be reclaimed
393 .sp
394 Default value: \fB2\fR.
395 .RE
396
397 .sp
398 .ne 2
399 .na
400 \fBzfs_arc_dnode_limit\fR (ulong)
401 .ad
402 .RS 12n
403 When the number of bytes consumed by dnodes in the ARC exceeds this number of
404 bytes, try to unpin some of it in response to demand for non-metadata. This
405 value acts as a ceiling to the amount of dnode metadata, and defaults to 0 which
406 indicates that a percent which is based on \fBzfs_arc_dnode_limit_percent\fR of
407 the ARC meta buffers that may be used for dnodes.
408
409 See also \fBzfs_arc_meta_prune\fR which serves a similar purpose but is used
410 when the amount of metadata in the ARC exceeds \fBzfs_arc_meta_limit\fR rather
411 than in response to overall demand for non-metadata.
412
413 .sp
414 Default value: \fB0\fR.
415 .RE
416
417 .sp
418 .ne 2
419 .na
420 \fBzfs_arc_dnode_limit_percent\fR (ulong)
421 .ad
422 .RS 12n
423 Percentage that can be consumed by dnodes of ARC meta buffers.
424 .sp
425 See also \fBzfs_arc_dnode_limit\fR which serves a similar purpose but has a
426 higher priority if set to nonzero value.
427 .sp
428 Default value: \fB10\fR%.
429 .RE
430
431 .sp
432 .ne 2
433 .na
434 \fBzfs_arc_dnode_reduce_percent\fR (ulong)
435 .ad
436 .RS 12n
437 Percentage of ARC dnodes to try to scan in response to demand for non-metadata
438 when the number of bytes consumed by dnodes exceeds \fBzfs_arc_dnode_limit\fR.
439
440 .sp
441 Default value: \fB10\fR% of the number of dnodes in the ARC.
442 .RE
443
444 .sp
445 .ne 2
446 .na
447 \fBzfs_arc_average_blocksize\fR (int)
448 .ad
449 .RS 12n
450 The ARC's buffer hash table is sized based on the assumption of an average
451 block size of \fBzfs_arc_average_blocksize\fR (default 8K). This works out
452 to roughly 1MB of hash table per 1GB of physical memory with 8-byte pointers.
453 For configurations with a known larger average block size this value can be
454 increased to reduce the memory footprint.
455
456 .sp
457 Default value: \fB8192\fR.
458 .RE
459
460 .sp
461 .ne 2
462 .na
463 \fBzfs_arc_evict_batch_limit\fR (int)
464 .ad
465 .RS 12n
466 Number ARC headers to evict per sub-list before proceeding to another sub-list.
467 This batch-style operation prevents entire sub-lists from being evicted at once
468 but comes at a cost of additional unlocking and locking.
469 .sp
470 Default value: \fB10\fR.
471 .RE
472
473 .sp
474 .ne 2
475 .na
476 \fBzfs_arc_grow_retry\fR (int)
477 .ad
478 .RS 12n
479 If set to a non zero value, it will replace the arc_grow_retry value with this value.
480 The arc_grow_retry value (default 5) is the number of seconds the ARC will wait before
481 trying to resume growth after a memory pressure event.
482 .sp
483 Default value: \fB0\fR.
484 .RE
485
486 .sp
487 .ne 2
488 .na
489 \fBzfs_arc_lotsfree_percent\fR (int)
490 .ad
491 .RS 12n
492 Throttle I/O when free system memory drops below this percentage of total
493 system memory. Setting this value to 0 will disable the throttle.
494 .sp
495 Default value: \fB10\fR%.
496 .RE
497
498 .sp
499 .ne 2
500 .na
501 \fBzfs_arc_max\fR (ulong)
502 .ad
503 .RS 12n
504 Max arc size of ARC in bytes. If set to 0 then it will consume 1/2 of system
505 RAM. This value must be at least 67108864 (64 megabytes).
506 .sp
507 This value can be changed dynamically with some caveats. It cannot be set back
508 to 0 while running and reducing it below the current ARC size will not cause
509 the ARC to shrink without memory pressure to induce shrinking.
510 .sp
511 Default value: \fB0\fR.
512 .RE
513
514 .sp
515 .ne 2
516 .na
517 \fBzfs_arc_meta_adjust_restarts\fR (ulong)
518 .ad
519 .RS 12n
520 The number of restart passes to make while scanning the ARC attempting
521 the free buffers in order to stay below the \fBzfs_arc_meta_limit\fR.
522 This value should not need to be tuned but is available to facilitate
523 performance analysis.
524 .sp
525 Default value: \fB4096\fR.
526 .RE
527
528 .sp
529 .ne 2
530 .na
531 \fBzfs_arc_meta_limit\fR (ulong)
532 .ad
533 .RS 12n
534 The maximum allowed size in bytes that meta data buffers are allowed to
535 consume in the ARC. When this limit is reached meta data buffers will
536 be reclaimed even if the overall arc_c_max has not been reached. This
537 value defaults to 0 which indicates that a percent which is based on
538 \fBzfs_arc_meta_limit_percent\fR of the ARC may be used for meta data.
539 .sp
540 This value my be changed dynamically except that it cannot be set back to 0
541 for a specific percent of the ARC; it must be set to an explicit value.
542 .sp
543 Default value: \fB0\fR.
544 .RE
545
546 .sp
547 .ne 2
548 .na
549 \fBzfs_arc_meta_limit_percent\fR (ulong)
550 .ad
551 .RS 12n
552 Percentage of ARC buffers that can be used for meta data.
553
554 See also \fBzfs_arc_meta_limit\fR which serves a similar purpose but has a
555 higher priority if set to nonzero value.
556
557 .sp
558 Default value: \fB75\fR%.
559 .RE
560
561 .sp
562 .ne 2
563 .na
564 \fBzfs_arc_meta_min\fR (ulong)
565 .ad
566 .RS 12n
567 The minimum allowed size in bytes that meta data buffers may consume in
568 the ARC. This value defaults to 0 which disables a floor on the amount
569 of the ARC devoted meta data.
570 .sp
571 Default value: \fB0\fR.
572 .RE
573
574 .sp
575 .ne 2
576 .na
577 \fBzfs_arc_meta_prune\fR (int)
578 .ad
579 .RS 12n
580 The number of dentries and inodes to be scanned looking for entries
581 which can be dropped. This may be required when the ARC reaches the
582 \fBzfs_arc_meta_limit\fR because dentries and inodes can pin buffers
583 in the ARC. Increasing this value will cause to dentry and inode caches
584 to be pruned more aggressively. Setting this value to 0 will disable
585 pruning the inode and dentry caches.
586 .sp
587 Default value: \fB10,000\fR.
588 .RE
589
590 .sp
591 .ne 2
592 .na
593 \fBzfs_arc_meta_strategy\fR (int)
594 .ad
595 .RS 12n
596 Define the strategy for ARC meta data buffer eviction (meta reclaim strategy).
597 A value of 0 (META_ONLY) will evict only the ARC meta data buffers.
598 A value of 1 (BALANCED) indicates that additional data buffers may be evicted if
599 that is required to in order to evict the required number of meta data buffers.
600 .sp
601 Default value: \fB1\fR.
602 .RE
603
604 .sp
605 .ne 2
606 .na
607 \fBzfs_arc_min\fR (ulong)
608 .ad
609 .RS 12n
610 Min arc size of ARC in bytes. If set to 0 then arc_c_min will default to
611 consuming the larger of 32M or 1/32 of total system memory.
612 .sp
613 Default value: \fB0\fR.
614 .RE
615
616 .sp
617 .ne 2
618 .na
619 \fBzfs_arc_min_prefetch_ms\fR (int)
620 .ad
621 .RS 12n
622 Minimum time prefetched blocks are locked in the ARC, specified in ms.
623 A value of \fB0\fR will default to 1000 ms.
624 .sp
625 Default value: \fB0\fR.
626 .RE
627
628 .sp
629 .ne 2
630 .na
631 \fBzfs_arc_min_prescient_prefetch_ms\fR (int)
632 .ad
633 .RS 12n
634 Minimum time "prescient prefetched" blocks are locked in the ARC, specified
635 in ms. These blocks are meant to be prefetched fairly aggresively ahead of
636 the code that may use them. A value of \fB0\fR will default to 6000 ms.
637 .sp
638 Default value: \fB0\fR.
639 .RE
640
641 .sp
642 .ne 2
643 .na
644 \fBzfs_multilist_num_sublists\fR (int)
645 .ad
646 .RS 12n
647 To allow more fine-grained locking, each ARC state contains a series
648 of lists for both data and meta data objects. Locking is performed at
649 the level of these "sub-lists". This parameters controls the number of
650 sub-lists per ARC state, and also applies to other uses of the
651 multilist data structure.
652 .sp
653 Default value: \fB4\fR or the number of online CPUs, whichever is greater
654 .RE
655
656 .sp
657 .ne 2
658 .na
659 \fBzfs_arc_overflow_shift\fR (int)
660 .ad
661 .RS 12n
662 The ARC size is considered to be overflowing if it exceeds the current
663 ARC target size (arc_c) by a threshold determined by this parameter.
664 The threshold is calculated as a fraction of arc_c using the formula
665 "arc_c >> \fBzfs_arc_overflow_shift\fR".
666
667 The default value of 8 causes the ARC to be considered to be overflowing
668 if it exceeds the target size by 1/256th (0.3%) of the target size.
669
670 When the ARC is overflowing, new buffer allocations are stalled until
671 the reclaim thread catches up and the overflow condition no longer exists.
672 .sp
673 Default value: \fB8\fR.
674 .RE
675
676 .sp
677 .ne 2
678 .na
679
680 \fBzfs_arc_p_min_shift\fR (int)
681 .ad
682 .RS 12n
683 If set to a non zero value, this will update arc_p_min_shift (default 4)
684 with the new value.
685 arc_p_min_shift is used to shift of arc_c for calculating both min and max
686 max arc_p
687 .sp
688 Default value: \fB0\fR.
689 .RE
690
691 .sp
692 .ne 2
693 .na
694 \fBzfs_arc_p_dampener_disable\fR (int)
695 .ad
696 .RS 12n
697 Disable arc_p adapt dampener
698 .sp
699 Use \fB1\fR for yes (default) and \fB0\fR to disable.
700 .RE
701
702 .sp
703 .ne 2
704 .na
705 \fBzfs_arc_shrink_shift\fR (int)
706 .ad
707 .RS 12n
708 If set to a non zero value, this will update arc_shrink_shift (default 7)
709 with the new value.
710 .sp
711 Default value: \fB0\fR.
712 .RE
713
714 .sp
715 .ne 2
716 .na
717 \fBzfs_arc_pc_percent\fR (uint)
718 .ad
719 .RS 12n
720 Percent of pagecache to reclaim arc to
721
722 This tunable allows ZFS arc to play more nicely with the kernel's LRU
723 pagecache. It can guarantee that the arc size won't collapse under scanning
724 pressure on the pagecache, yet still allows arc to be reclaimed down to
725 zfs_arc_min if necessary. This value is specified as percent of pagecache
726 size (as measured by NR_FILE_PAGES) where that percent may exceed 100. This
727 only operates during memory pressure/reclaim.
728 .sp
729 Default value: \fB0\fR% (disabled).
730 .RE
731
732 .sp
733 .ne 2
734 .na
735 \fBzfs_arc_sys_free\fR (ulong)
736 .ad
737 .RS 12n
738 The target number of bytes the ARC should leave as free memory on the system.
739 Defaults to the larger of 1/64 of physical memory or 512K. Setting this
740 option to a non-zero value will override the default.
741 .sp
742 Default value: \fB0\fR.
743 .RE
744
745 .sp
746 .ne 2
747 .na
748 \fBzfs_autoimport_disable\fR (int)
749 .ad
750 .RS 12n
751 Disable pool import at module load by ignoring the cache file (typically \fB/etc/zfs/zpool.cache\fR).
752 .sp
753 Use \fB1\fR for yes (default) and \fB0\fR for no.
754 .RE
755
756 .sp
757 .ne 2
758 .na
759 \fBzfs_checksums_per_second\fR (int)
760 .ad
761 .RS 12n
762 Rate limit checksum events to this many per second. Note that this should
763 not be set below the zed thresholds (currently 10 checksums over 10 sec)
764 or else zed may not trigger any action.
765 .sp
766 Default value: 20
767 .RE
768
769 .sp
770 .ne 2
771 .na
772 \fBzfs_commit_timeout_pct\fR (int)
773 .ad
774 .RS 12n
775 This controls the amount of time that a ZIL block (lwb) will remain "open"
776 when it isn't "full", and it has a thread waiting for it to be committed to
777 stable storage. The timeout is scaled based on a percentage of the last lwb
778 latency to avoid significantly impacting the latency of each individual
779 transaction record (itx).
780 .sp
781 Default value: \fB5\fR%.
782 .RE
783
784 .sp
785 .ne 2
786 .na
787 \fBzfs_dbgmsg_enable\fR (int)
788 .ad
789 .RS 12n
790 Internally ZFS keeps a small log to facilitate debugging. By default the log
791 is disabled, to enable it set this option to 1. The contents of the log can
792 be accessed by reading the /proc/spl/kstat/zfs/dbgmsg file. Writing 0 to
793 this proc file clears the log.
794 .sp
795 Default value: \fB0\fR.
796 .RE
797
798 .sp
799 .ne 2
800 .na
801 \fBzfs_dbgmsg_maxsize\fR (int)
802 .ad
803 .RS 12n
804 The maximum size in bytes of the internal ZFS debug log.
805 .sp
806 Default value: \fB4M\fR.
807 .RE
808
809 .sp
810 .ne 2
811 .na
812 \fBzfs_dbuf_state_index\fR (int)
813 .ad
814 .RS 12n
815 This feature is currently unused. It is normally used for controlling what
816 reporting is available under /proc/spl/kstat/zfs.
817 .sp
818 Default value: \fB0\fR.
819 .RE
820
821 .sp
822 .ne 2
823 .na
824 \fBzfs_deadman_enabled\fR (int)
825 .ad
826 .RS 12n
827 When a pool sync operation takes longer than \fBzfs_deadman_synctime_ms\fR
828 milliseconds, or when an individual I/O takes longer than
829 \fBzfs_deadman_ziotime_ms\fR milliseconds, then the operation is considered to
830 be "hung". If \fBzfs_deadman_enabled\fR is set then the deadman behavior is
831 invoked as described by the \fBzfs_deadman_failmode\fR module option.
832 By default the deadman is enabled and configured to \fBwait\fR which results
833 in "hung" I/Os only being logged. The deadman is automatically disabled
834 when a pool gets suspended.
835 .sp
836 Default value: \fB1\fR.
837 .RE
838
839 .sp
840 .ne 2
841 .na
842 \fBzfs_deadman_failmode\fR (charp)
843 .ad
844 .RS 12n
845 Controls the failure behavior when the deadman detects a "hung" I/O. Valid
846 values are \fBwait\fR, \fBcontinue\fR, and \fBpanic\fR.
847 .sp
848 \fBwait\fR - Wait for a "hung" I/O to complete. For each "hung" I/O a
849 "deadman" event will be posted describing that I/O.
850 .sp
851 \fBcontinue\fR - Attempt to recover from a "hung" I/O by re-dispatching it
852 to the I/O pipeline if possible.
853 .sp
854 \fBpanic\fR - Panic the system. This can be used to facilitate an automatic
855 fail-over to a properly configured fail-over partner.
856 .sp
857 Default value: \fBwait\fR.
858 .RE
859
860 .sp
861 .ne 2
862 .na
863 \fBzfs_deadman_checktime_ms\fR (int)
864 .ad
865 .RS 12n
866 Check time in milliseconds. This defines the frequency at which we check
867 for hung I/O and potentially invoke the \fBzfs_deadman_failmode\fR behavior.
868 .sp
869 Default value: \fB60,000\fR.
870 .RE
871
872 .sp
873 .ne 2
874 .na
875 \fBzfs_deadman_synctime_ms\fR (ulong)
876 .ad
877 .RS 12n
878 Interval in milliseconds after which the deadman is triggered and also
879 the interval after which a pool sync operation is considered to be "hung".
880 Once this limit is exceeded the deadman will be invoked every
881 \fBzfs_deadman_checktime_ms\fR milliseconds until the pool sync completes.
882 .sp
883 Default value: \fB600,000\fR.
884 .RE
885
886 .sp
887 .ne 2
888 .na
889 \fBzfs_deadman_ziotime_ms\fR (ulong)
890 .ad
891 .RS 12n
892 Interval in milliseconds after which the deadman is triggered and an
893 individual IO operation is considered to be "hung". As long as the I/O
894 remains "hung" the deadman will be invoked every \fBzfs_deadman_checktime_ms\fR
895 milliseconds until the I/O completes.
896 .sp
897 Default value: \fB300,000\fR.
898 .RE
899
900 .sp
901 .ne 2
902 .na
903 \fBzfs_dedup_prefetch\fR (int)
904 .ad
905 .RS 12n
906 Enable prefetching dedup-ed blks
907 .sp
908 Use \fB1\fR for yes and \fB0\fR to disable (default).
909 .RE
910
911 .sp
912 .ne 2
913 .na
914 \fBzfs_delay_min_dirty_percent\fR (int)
915 .ad
916 .RS 12n
917 Start to delay each transaction once there is this amount of dirty data,
918 expressed as a percentage of \fBzfs_dirty_data_max\fR.
919 This value should be >= zfs_vdev_async_write_active_max_dirty_percent.
920 See the section "ZFS TRANSACTION DELAY".
921 .sp
922 Default value: \fB60\fR%.
923 .RE
924
925 .sp
926 .ne 2
927 .na
928 \fBzfs_delay_scale\fR (int)
929 .ad
930 .RS 12n
931 This controls how quickly the transaction delay approaches infinity.
932 Larger values cause longer delays for a given amount of dirty data.
933 .sp
934 For the smoothest delay, this value should be about 1 billion divided
935 by the maximum number of operations per second. This will smoothly
936 handle between 10x and 1/10th this number.
937 .sp
938 See the section "ZFS TRANSACTION DELAY".
939 .sp
940 Note: \fBzfs_delay_scale\fR * \fBzfs_dirty_data_max\fR must be < 2^64.
941 .sp
942 Default value: \fB500,000\fR.
943 .RE
944
945 .sp
946 .ne 2
947 .na
948 \fBzfs_delays_per_second\fR (int)
949 .ad
950 .RS 12n
951 Rate limit IO delay events to this many per second.
952 .sp
953 Default value: 20
954 .RE
955
956 .sp
957 .ne 2
958 .na
959 \fBzfs_delete_blocks\fR (ulong)
960 .ad
961 .RS 12n
962 This is the used to define a large file for the purposes of delete. Files
963 containing more than \fBzfs_delete_blocks\fR will be deleted asynchronously
964 while smaller files are deleted synchronously. Decreasing this value will
965 reduce the time spent in an unlink(2) system call at the expense of a longer
966 delay before the freed space is available.
967 .sp
968 Default value: \fB20,480\fR.
969 .RE
970
971 .sp
972 .ne 2
973 .na
974 \fBzfs_dirty_data_max\fR (int)
975 .ad
976 .RS 12n
977 Determines the dirty space limit in bytes. Once this limit is exceeded, new
978 writes are halted until space frees up. This parameter takes precedence
979 over \fBzfs_dirty_data_max_percent\fR.
980 See the section "ZFS TRANSACTION DELAY".
981 .sp
982 Default value: \fB10\fR% of physical RAM, capped at \fBzfs_dirty_data_max_max\fR.
983 .RE
984
985 .sp
986 .ne 2
987 .na
988 \fBzfs_dirty_data_max_max\fR (int)
989 .ad
990 .RS 12n
991 Maximum allowable value of \fBzfs_dirty_data_max\fR, expressed in bytes.
992 This limit is only enforced at module load time, and will be ignored if
993 \fBzfs_dirty_data_max\fR is later changed. This parameter takes
994 precedence over \fBzfs_dirty_data_max_max_percent\fR. See the section
995 "ZFS TRANSACTION DELAY".
996 .sp
997 Default value: \fB25\fR% of physical RAM.
998 .RE
999
1000 .sp
1001 .ne 2
1002 .na
1003 \fBzfs_dirty_data_max_max_percent\fR (int)
1004 .ad
1005 .RS 12n
1006 Maximum allowable value of \fBzfs_dirty_data_max\fR, expressed as a
1007 percentage of physical RAM. This limit is only enforced at module load
1008 time, and will be ignored if \fBzfs_dirty_data_max\fR is later changed.
1009 The parameter \fBzfs_dirty_data_max_max\fR takes precedence over this
1010 one. See the section "ZFS TRANSACTION DELAY".
1011 .sp
1012 Default value: \fB25\fR%.
1013 .RE
1014
1015 .sp
1016 .ne 2
1017 .na
1018 \fBzfs_dirty_data_max_percent\fR (int)
1019 .ad
1020 .RS 12n
1021 Determines the dirty space limit, expressed as a percentage of all
1022 memory. Once this limit is exceeded, new writes are halted until space frees
1023 up. The parameter \fBzfs_dirty_data_max\fR takes precedence over this
1024 one. See the section "ZFS TRANSACTION DELAY".
1025 .sp
1026 Default value: \fB10\fR%, subject to \fBzfs_dirty_data_max_max\fR.
1027 .RE
1028
1029 .sp
1030 .ne 2
1031 .na
1032 \fBzfs_dirty_data_sync\fR (int)
1033 .ad
1034 .RS 12n
1035 Start syncing out a transaction group if there is at least this much dirty data.
1036 .sp
1037 Default value: \fB67,108,864\fR.
1038 .RE
1039
1040 .sp
1041 .ne 2
1042 .na
1043 \fBzfs_fletcher_4_impl\fR (string)
1044 .ad
1045 .RS 12n
1046 Select a fletcher 4 implementation.
1047 .sp
1048 Supported selectors are: \fBfastest\fR, \fBscalar\fR, \fBsse2\fR, \fBssse3\fR,
1049 \fBavx2\fR, \fBavx512f\fR, and \fBaarch64_neon\fR.
1050 All of the selectors except \fBfastest\fR and \fBscalar\fR require instruction
1051 set extensions to be available and will only appear if ZFS detects that they are
1052 present at runtime. If multiple implementations of fletcher 4 are available,
1053 the \fBfastest\fR will be chosen using a micro benchmark. Selecting \fBscalar\fR
1054 results in the original, CPU based calculation, being used. Selecting any option
1055 other than \fBfastest\fR and \fBscalar\fR results in vector instructions from
1056 the respective CPU instruction set being used.
1057 .sp
1058 Default value: \fBfastest\fR.
1059 .RE
1060
1061 .sp
1062 .ne 2
1063 .na
1064 \fBzfs_free_bpobj_enabled\fR (int)
1065 .ad
1066 .RS 12n
1067 Enable/disable the processing of the free_bpobj object.
1068 .sp
1069 Default value: \fB1\fR.
1070 .RE
1071
1072 .sp
1073 .ne 2
1074 .na
1075 \fBzfs_free_max_blocks\fR (ulong)
1076 .ad
1077 .RS 12n
1078 Maximum number of blocks freed in a single txg.
1079 .sp
1080 Default value: \fB100,000\fR.
1081 .RE
1082
1083 .sp
1084 .ne 2
1085 .na
1086 \fBzfs_vdev_async_read_max_active\fR (int)
1087 .ad
1088 .RS 12n
1089 Maximum asynchronous read I/Os active to each device.
1090 See the section "ZFS I/O SCHEDULER".
1091 .sp
1092 Default value: \fB3\fR.
1093 .RE
1094
1095 .sp
1096 .ne 2
1097 .na
1098 \fBzfs_vdev_async_read_min_active\fR (int)
1099 .ad
1100 .RS 12n
1101 Minimum asynchronous read I/Os active to each device.
1102 See the section "ZFS I/O SCHEDULER".
1103 .sp
1104 Default value: \fB1\fR.
1105 .RE
1106
1107 .sp
1108 .ne 2
1109 .na
1110 \fBzfs_vdev_async_write_active_max_dirty_percent\fR (int)
1111 .ad
1112 .RS 12n
1113 When the pool has more than
1114 \fBzfs_vdev_async_write_active_max_dirty_percent\fR dirty data, use
1115 \fBzfs_vdev_async_write_max_active\fR to limit active async writes. If
1116 the dirty data is between min and max, the active I/O limit is linearly
1117 interpolated. See the section "ZFS I/O SCHEDULER".
1118 .sp
1119 Default value: \fB60\fR%.
1120 .RE
1121
1122 .sp
1123 .ne 2
1124 .na
1125 \fBzfs_vdev_async_write_active_min_dirty_percent\fR (int)
1126 .ad
1127 .RS 12n
1128 When the pool has less than
1129 \fBzfs_vdev_async_write_active_min_dirty_percent\fR dirty data, use
1130 \fBzfs_vdev_async_write_min_active\fR to limit active async writes. If
1131 the dirty data is between min and max, the active I/O limit is linearly
1132 interpolated. See the section "ZFS I/O SCHEDULER".
1133 .sp
1134 Default value: \fB30\fR%.
1135 .RE
1136
1137 .sp
1138 .ne 2
1139 .na
1140 \fBzfs_vdev_async_write_max_active\fR (int)
1141 .ad
1142 .RS 12n
1143 Maximum asynchronous write I/Os active to each device.
1144 See the section "ZFS I/O SCHEDULER".
1145 .sp
1146 Default value: \fB10\fR.
1147 .RE
1148
1149 .sp
1150 .ne 2
1151 .na
1152 \fBzfs_vdev_async_write_min_active\fR (int)
1153 .ad
1154 .RS 12n
1155 Minimum asynchronous write I/Os active to each device.
1156 See the section "ZFS I/O SCHEDULER".
1157 .sp
1158 Lower values are associated with better latency on rotational media but poorer
1159 resilver performance. The default value of 2 was chosen as a compromise. A
1160 value of 3 has been shown to improve resilver performance further at a cost of
1161 further increasing latency.
1162 .sp
1163 Default value: \fB2\fR.
1164 .RE
1165
1166 .sp
1167 .ne 2
1168 .na
1169 \fBzfs_vdev_max_active\fR (int)
1170 .ad
1171 .RS 12n
1172 The maximum number of I/Os active to each device. Ideally, this will be >=
1173 the sum of each queue's max_active. It must be at least the sum of each
1174 queue's min_active. See the section "ZFS I/O SCHEDULER".
1175 .sp
1176 Default value: \fB1,000\fR.
1177 .RE
1178
1179 .sp
1180 .ne 2
1181 .na
1182 \fBzfs_vdev_scrub_max_active\fR (int)
1183 .ad
1184 .RS 12n
1185 Maximum scrub I/Os active to each device.
1186 See the section "ZFS I/O SCHEDULER".
1187 .sp
1188 Default value: \fB2\fR.
1189 .RE
1190
1191 .sp
1192 .ne 2
1193 .na
1194 \fBzfs_vdev_scrub_min_active\fR (int)
1195 .ad
1196 .RS 12n
1197 Minimum scrub I/Os active to each device.
1198 See the section "ZFS I/O SCHEDULER".
1199 .sp
1200 Default value: \fB1\fR.
1201 .RE
1202
1203 .sp
1204 .ne 2
1205 .na
1206 \fBzfs_vdev_sync_read_max_active\fR (int)
1207 .ad
1208 .RS 12n
1209 Maximum synchronous read I/Os active to each device.
1210 See the section "ZFS I/O SCHEDULER".
1211 .sp
1212 Default value: \fB10\fR.
1213 .RE
1214
1215 .sp
1216 .ne 2
1217 .na
1218 \fBzfs_vdev_sync_read_min_active\fR (int)
1219 .ad
1220 .RS 12n
1221 Minimum synchronous read I/Os active to each device.
1222 See the section "ZFS I/O SCHEDULER".
1223 .sp
1224 Default value: \fB10\fR.
1225 .RE
1226
1227 .sp
1228 .ne 2
1229 .na
1230 \fBzfs_vdev_sync_write_max_active\fR (int)
1231 .ad
1232 .RS 12n
1233 Maximum synchronous write I/Os active to each device.
1234 See the section "ZFS I/O SCHEDULER".
1235 .sp
1236 Default value: \fB10\fR.
1237 .RE
1238
1239 .sp
1240 .ne 2
1241 .na
1242 \fBzfs_vdev_sync_write_min_active\fR (int)
1243 .ad
1244 .RS 12n
1245 Minimum synchronous write I/Os active to each device.
1246 See the section "ZFS I/O SCHEDULER".
1247 .sp
1248 Default value: \fB10\fR.
1249 .RE
1250
1251 .sp
1252 .ne 2
1253 .na
1254 \fBzfs_vdev_queue_depth_pct\fR (int)
1255 .ad
1256 .RS 12n
1257 Maximum number of queued allocations per top-level vdev expressed as
1258 a percentage of \fBzfs_vdev_async_write_max_active\fR which allows the
1259 system to detect devices that are more capable of handling allocations
1260 and to allocate more blocks to those devices. It allows for dynamic
1261 allocation distribution when devices are imbalanced as fuller devices
1262 will tend to be slower than empty devices.
1263
1264 See also \fBzio_dva_throttle_enabled\fR.
1265 .sp
1266 Default value: \fB1000\fR%.
1267 .RE
1268
1269 .sp
1270 .ne 2
1271 .na
1272 \fBzfs_expire_snapshot\fR (int)
1273 .ad
1274 .RS 12n
1275 Seconds to expire .zfs/snapshot
1276 .sp
1277 Default value: \fB300\fR.
1278 .RE
1279
1280 .sp
1281 .ne 2
1282 .na
1283 \fBzfs_admin_snapshot\fR (int)
1284 .ad
1285 .RS 12n
1286 Allow the creation, removal, or renaming of entries in the .zfs/snapshot
1287 directory to cause the creation, destruction, or renaming of snapshots.
1288 When enabled this functionality works both locally and over NFS exports
1289 which have the 'no_root_squash' option set. This functionality is disabled
1290 by default.
1291 .sp
1292 Use \fB1\fR for yes and \fB0\fR for no (default).
1293 .RE
1294
1295 .sp
1296 .ne 2
1297 .na
1298 \fBzfs_flags\fR (int)
1299 .ad
1300 .RS 12n
1301 Set additional debugging flags. The following flags may be bitwise-or'd
1302 together.
1303 .sp
1304 .TS
1305 box;
1306 rB lB
1307 lB lB
1308 r l.
1309 Value Symbolic Name
1310 Description
1311 _
1312 1 ZFS_DEBUG_DPRINTF
1313 Enable dprintf entries in the debug log.
1314 _
1315 2 ZFS_DEBUG_DBUF_VERIFY *
1316 Enable extra dbuf verifications.
1317 _
1318 4 ZFS_DEBUG_DNODE_VERIFY *
1319 Enable extra dnode verifications.
1320 _
1321 8 ZFS_DEBUG_SNAPNAMES
1322 Enable snapshot name verification.
1323 _
1324 16 ZFS_DEBUG_MODIFY
1325 Check for illegally modified ARC buffers.
1326 _
1327 32 ZFS_DEBUG_SPA
1328 Enable spa_dbgmsg entries in the debug log.
1329 _
1330 64 ZFS_DEBUG_ZIO_FREE
1331 Enable verification of block frees.
1332 _
1333 128 ZFS_DEBUG_HISTOGRAM_VERIFY
1334 Enable extra spacemap histogram verifications.
1335 _
1336 256 ZFS_DEBUG_METASLAB_VERIFY
1337 Verify space accounting on disk matches in-core range_trees.
1338 _
1339 512 ZFS_DEBUG_SET_ERROR
1340 Enable SET_ERROR and dprintf entries in the debug log.
1341 .TE
1342 .sp
1343 * Requires debug build.
1344 .sp
1345 Default value: \fB0\fR.
1346 .RE
1347
1348 .sp
1349 .ne 2
1350 .na
1351 \fBzfs_free_leak_on_eio\fR (int)
1352 .ad
1353 .RS 12n
1354 If destroy encounters an EIO while reading metadata (e.g. indirect
1355 blocks), space referenced by the missing metadata can not be freed.
1356 Normally this causes the background destroy to become "stalled", as
1357 it is unable to make forward progress. While in this stalled state,
1358 all remaining space to free from the error-encountering filesystem is
1359 "temporarily leaked". Set this flag to cause it to ignore the EIO,
1360 permanently leak the space from indirect blocks that can not be read,
1361 and continue to free everything else that it can.
1362
1363 The default, "stalling" behavior is useful if the storage partially
1364 fails (i.e. some but not all i/os fail), and then later recovers. In
1365 this case, we will be able to continue pool operations while it is
1366 partially failed, and when it recovers, we can continue to free the
1367 space, with no leaks. However, note that this case is actually
1368 fairly rare.
1369
1370 Typically pools either (a) fail completely (but perhaps temporarily,
1371 e.g. a top-level vdev going offline), or (b) have localized,
1372 permanent errors (e.g. disk returns the wrong data due to bit flip or
1373 firmware bug). In case (a), this setting does not matter because the
1374 pool will be suspended and the sync thread will not be able to make
1375 forward progress regardless. In case (b), because the error is
1376 permanent, the best we can do is leak the minimum amount of space,
1377 which is what setting this flag will do. Therefore, it is reasonable
1378 for this flag to normally be set, but we chose the more conservative
1379 approach of not setting it, so that there is no possibility of
1380 leaking space in the "partial temporary" failure case.
1381 .sp
1382 Default value: \fB0\fR.
1383 .RE
1384
1385 .sp
1386 .ne 2
1387 .na
1388 \fBzfs_free_min_time_ms\fR (int)
1389 .ad
1390 .RS 12n
1391 During a \fBzfs destroy\fR operation using \fBfeature@async_destroy\fR a minimum
1392 of this much time will be spent working on freeing blocks per txg.
1393 .sp
1394 Default value: \fB1,000\fR.
1395 .RE
1396
1397 .sp
1398 .ne 2
1399 .na
1400 \fBzfs_immediate_write_sz\fR (long)
1401 .ad
1402 .RS 12n
1403 Largest data block to write to zil. Larger blocks will be treated as if the
1404 dataset being written to had the property setting \fBlogbias=throughput\fR.
1405 .sp
1406 Default value: \fB32,768\fR.
1407 .RE
1408
1409 .sp
1410 .ne 2
1411 .na
1412 \fBzfs_max_recordsize\fR (int)
1413 .ad
1414 .RS 12n
1415 We currently support block sizes from 512 bytes to 16MB. The benefits of
1416 larger blocks, and thus larger IO, need to be weighed against the cost of
1417 COWing a giant block to modify one byte. Additionally, very large blocks
1418 can have an impact on i/o latency, and also potentially on the memory
1419 allocator. Therefore, we do not allow the recordsize to be set larger than
1420 zfs_max_recordsize (default 1MB). Larger blocks can be created by changing
1421 this tunable, and pools with larger blocks can always be imported and used,
1422 regardless of this setting.
1423 .sp
1424 Default value: \fB1,048,576\fR.
1425 .RE
1426
1427 .sp
1428 .ne 2
1429 .na
1430 \fBzfs_metaslab_fragmentation_threshold\fR (int)
1431 .ad
1432 .RS 12n
1433 Allow metaslabs to keep their active state as long as their fragmentation
1434 percentage is less than or equal to this value. An active metaslab that
1435 exceeds this threshold will no longer keep its active status allowing
1436 better metaslabs to be selected.
1437 .sp
1438 Default value: \fB70\fR.
1439 .RE
1440
1441 .sp
1442 .ne 2
1443 .na
1444 \fBzfs_mg_fragmentation_threshold\fR (int)
1445 .ad
1446 .RS 12n
1447 Metaslab groups are considered eligible for allocations if their
1448 fragmentation metric (measured as a percentage) is less than or equal to
1449 this value. If a metaslab group exceeds this threshold then it will be
1450 skipped unless all metaslab groups within the metaslab class have also
1451 crossed this threshold.
1452 .sp
1453 Default value: \fB85\fR.
1454 .RE
1455
1456 .sp
1457 .ne 2
1458 .na
1459 \fBzfs_mg_noalloc_threshold\fR (int)
1460 .ad
1461 .RS 12n
1462 Defines a threshold at which metaslab groups should be eligible for
1463 allocations. The value is expressed as a percentage of free space
1464 beyond which a metaslab group is always eligible for allocations.
1465 If a metaslab group's free space is less than or equal to the
1466 threshold, the allocator will avoid allocating to that group
1467 unless all groups in the pool have reached the threshold. Once all
1468 groups have reached the threshold, all groups are allowed to accept
1469 allocations. The default value of 0 disables the feature and causes
1470 all metaslab groups to be eligible for allocations.
1471
1472 This parameter allows one to deal with pools having heavily imbalanced
1473 vdevs such as would be the case when a new vdev has been added.
1474 Setting the threshold to a non-zero percentage will stop allocations
1475 from being made to vdevs that aren't filled to the specified percentage
1476 and allow lesser filled vdevs to acquire more allocations than they
1477 otherwise would under the old \fBzfs_mg_alloc_failures\fR facility.
1478 .sp
1479 Default value: \fB0\fR.
1480 .RE
1481
1482 .sp
1483 .ne 2
1484 .na
1485 \fBzfs_multihost_history\fR (int)
1486 .ad
1487 .RS 12n
1488 Historical statistics for the last N multihost updates will be available in
1489 \fB/proc/spl/kstat/zfs/<pool>/multihost\fR
1490 .sp
1491 Default value: \fB0\fR.
1492 .RE
1493
1494 .sp
1495 .ne 2
1496 .na
1497 \fBzfs_multihost_interval\fR (ulong)
1498 .ad
1499 .RS 12n
1500 Used to control the frequency of multihost writes which are performed when the
1501 \fBmultihost\fR pool property is on. This is one factor used to determine
1502 the length of the activity check during import.
1503 .sp
1504 The multihost write period is \fBzfs_multihost_interval / leaf-vdevs\fR milliseconds.
1505 This means that on average a multihost write will be issued for each leaf vdev every
1506 \fBzfs_multihost_interval\fR milliseconds. In practice, the observed period can
1507 vary with the I/O load and this observed value is the delay which is stored in
1508 the uberblock.
1509 .sp
1510 On import the activity check waits a minimum amount of time determined by
1511 \fBzfs_multihost_interval * zfs_multihost_import_intervals\fR. The activity
1512 check time may be further extended if the value of mmp delay found in the best
1513 uberblock indicates actual multihost updates happened at longer intervals than
1514 \fBzfs_multihost_interval\fR. A minimum value of \fB100ms\fR is enforced.
1515 .sp
1516 Default value: \fB1000\fR.
1517 .RE
1518
1519 .sp
1520 .ne 2
1521 .na
1522 \fBzfs_multihost_import_intervals\fR (uint)
1523 .ad
1524 .RS 12n
1525 Used to control the duration of the activity test on import. Smaller values of
1526 \fBzfs_multihost_import_intervals\fR will reduce the import time but increase
1527 the risk of failing to detect an active pool. The total activity check time is
1528 never allowed to drop below one second. A value of 0 is ignored and treated as
1529 if it was set to 1
1530 .sp
1531 Default value: \fB10\fR.
1532 .RE
1533
1534 .sp
1535 .ne 2
1536 .na
1537 \fBzfs_multihost_fail_intervals\fR (uint)
1538 .ad
1539 .RS 12n
1540 Controls the behavior of the pool when multihost write failures are detected.
1541 .sp
1542 When \fBzfs_multihost_fail_intervals = 0\fR then multihost write failures are ignored.
1543 The failures will still be reported to the ZED which depending on its
1544 configuration may take action such as suspending the pool or offlining a device.
1545 .sp
1546 When \fBzfs_multihost_fail_intervals > 0\fR then sequential multihost write failures
1547 will cause the pool to be suspended. This occurs when
1548 \fBzfs_multihost_fail_intervals * zfs_multihost_interval\fR milliseconds have
1549 passed since the last successful multihost write. This guarantees the activity test
1550 will see multihost writes if the pool is imported.
1551 .sp
1552 Default value: \fB5\fR.
1553 .RE
1554
1555 .sp
1556 .ne 2
1557 .na
1558 \fBzfs_no_scrub_io\fR (int)
1559 .ad
1560 .RS 12n
1561 Set for no scrub I/O. This results in scrubs not actually scrubbing data and
1562 simply doing a metadata crawl of the pool instead.
1563 .sp
1564 Use \fB1\fR for yes and \fB0\fR for no (default).
1565 .RE
1566
1567 .sp
1568 .ne 2
1569 .na
1570 \fBzfs_no_scrub_prefetch\fR (int)
1571 .ad
1572 .RS 12n
1573 Set to disable block prefetching for scrubs.
1574 .sp
1575 Use \fB1\fR for yes and \fB0\fR for no (default).
1576 .RE
1577
1578 .sp
1579 .ne 2
1580 .na
1581 \fBzfs_nocacheflush\fR (int)
1582 .ad
1583 .RS 12n
1584 Disable cache flush operations on disks when writing. Beware, this may cause
1585 corruption if disks re-order writes.
1586 .sp
1587 Use \fB1\fR for yes and \fB0\fR for no (default).
1588 .RE
1589
1590 .sp
1591 .ne 2
1592 .na
1593 \fBzfs_nopwrite_enabled\fR (int)
1594 .ad
1595 .RS 12n
1596 Enable NOP writes
1597 .sp
1598 Use \fB1\fR for yes (default) and \fB0\fR to disable.
1599 .RE
1600
1601 .sp
1602 .ne 2
1603 .na
1604 \fBzfs_dmu_offset_next_sync\fR (int)
1605 .ad
1606 .RS 12n
1607 Enable forcing txg sync to find holes. When enabled forces ZFS to act
1608 like prior versions when SEEK_HOLE or SEEK_DATA flags are used, which
1609 when a dnode is dirty causes txg's to be synced so that this data can be
1610 found.
1611 .sp
1612 Use \fB1\fR for yes and \fB0\fR to disable (default).
1613 .RE
1614
1615 .sp
1616 .ne 2
1617 .na
1618 \fBzfs_pd_bytes_max\fR (int)
1619 .ad
1620 .RS 12n
1621 The number of bytes which should be prefetched during a pool traversal
1622 (eg: \fBzfs send\fR or other data crawling operations)
1623 .sp
1624 Default value: \fB52,428,800\fR.
1625 .RE
1626
1627 .sp
1628 .ne 2
1629 .na
1630 \fBzfs_per_txg_dirty_frees_percent \fR (ulong)
1631 .ad
1632 .RS 12n
1633 Tunable to control percentage of dirtied blocks from frees in one TXG.
1634 After this threshold is crossed, additional dirty blocks from frees
1635 wait until the next TXG.
1636 A value of zero will disable this throttle.
1637 .sp
1638 Default value: \fB30\fR and \fB0\fR to disable.
1639 .RE
1640
1641
1642
1643 .sp
1644 .ne 2
1645 .na
1646 \fBzfs_prefetch_disable\fR (int)
1647 .ad
1648 .RS 12n
1649 This tunable disables predictive prefetch. Note that it leaves "prescient"
1650 prefetch (e.g. prefetch for zfs send) intact. Unlike predictive prefetch,
1651 prescient prefetch never issues i/os that end up not being needed, so it
1652 can't hurt performance.
1653 .sp
1654 Use \fB1\fR for yes and \fB0\fR for no (default).
1655 .RE
1656
1657 .sp
1658 .ne 2
1659 .na
1660 \fBzfs_read_chunk_size\fR (long)
1661 .ad
1662 .RS 12n
1663 Bytes to read per chunk
1664 .sp
1665 Default value: \fB1,048,576\fR.
1666 .RE
1667
1668 .sp
1669 .ne 2
1670 .na
1671 \fBzfs_read_history\fR (int)
1672 .ad
1673 .RS 12n
1674 Historical statistics for the last N reads will be available in
1675 \fB/proc/spl/kstat/zfs/<pool>/reads\fR
1676 .sp
1677 Default value: \fB0\fR (no data is kept).
1678 .RE
1679
1680 .sp
1681 .ne 2
1682 .na
1683 \fBzfs_read_history_hits\fR (int)
1684 .ad
1685 .RS 12n
1686 Include cache hits in read history
1687 .sp
1688 Use \fB1\fR for yes and \fB0\fR for no (default).
1689 .RE
1690
1691 .sp
1692 .ne 2
1693 .na
1694 \fBzfs_recover\fR (int)
1695 .ad
1696 .RS 12n
1697 Set to attempt to recover from fatal errors. This should only be used as a
1698 last resort, as it typically results in leaked space, or worse.
1699 .sp
1700 Use \fB1\fR for yes and \fB0\fR for no (default).
1701 .RE
1702
1703 .sp
1704 .ne 2
1705 .na
1706 \fBzfs_resilver_min_time_ms\fR (int)
1707 .ad
1708 .RS 12n
1709 Resilvers are processed by the sync thread. While resilvering it will spend
1710 at least this much time working on a resilver between txg flushes.
1711 .sp
1712 Default value: \fB3,000\fR.
1713 .RE
1714
1715 .sp
1716 .ne 2
1717 .na
1718 \fBzfs_scrub_min_time_ms\fR (int)
1719 .ad
1720 .RS 12n
1721 Scrubs are processed by the sync thread. While scrubbing it will spend
1722 at least this much time working on a scrub between txg flushes.
1723 .sp
1724 Default value: \fB1,000\fR.
1725 .RE
1726
1727 .sp
1728 .ne 2
1729 .na
1730 \fBzfs_scan_checkpoint_intval\fR (int)
1731 .ad
1732 .RS 12n
1733 To preserve progress across reboots the sequential scan algorithm periodically
1734 needs to stop metadata scanning and issue all the verifications I/Os to disk.
1735 The frequency of this flushing is determined by the
1736 \fBfBzfs_scan_checkpoint_intval\fR tunable.
1737 .sp
1738 Default value: \fB7200\fR seconds (every 2 hours).
1739 .RE
1740
1741 .sp
1742 .ne 2
1743 .na
1744 \fBzfs_scan_fill_weight\fR (int)
1745 .ad
1746 .RS 12n
1747 This tunable affects how scrub and resilver I/O segments are ordered. A higher
1748 number indicates that we care more about how filled in a segment is, while a
1749 lower number indicates we care more about the size of the extent without
1750 considering the gaps within a segment. This value is only tunable upon module
1751 insertion. Changing the value afterwards will have no affect on scrub or
1752 resilver performance.
1753 .sp
1754 Default value: \fB3\fR.
1755 .RE
1756
1757 .sp
1758 .ne 2
1759 .na
1760 \fBzfs_scan_issue_strategy\fR (int)
1761 .ad
1762 .RS 12n
1763 Determines the order that data will be verified while scrubbing or resilvering.
1764 If set to \fB1\fR, data will be verified as sequentially as possible, given the
1765 amount of memory reserved for scrubbing (see \fBzfs_scan_mem_lim_fact\fR). This
1766 may improve scrub performance if the pool's data is very fragmented. If set to
1767 \fB2\fR, the largest mostly-contiguous chunk of found data will be verified
1768 first. By deferring scrubbing of small segments, we may later find adjacent data
1769 to coalesce and increase the segment size. If set to \fB0\fR, zfs will use
1770 strategy \fB1\fR during normal verification and strategy \fB2\fR while taking a
1771 checkpoint.
1772 .sp
1773 Default value: \fB0\fR.
1774 .RE
1775
1776 .sp
1777 .ne 2
1778 .na
1779 \fBzfs_scan_legacy\fR (int)
1780 .ad
1781 .RS 12n
1782 A value of 0 indicates that scrubs and resilvers will gather metadata in
1783 memory before issuing sequential I/O. A value of 1 indicates that the legacy
1784 algorithm will be used where I/O is initiated as soon as it is discovered.
1785 Changing this value to 0 will not affect scrubs or resilvers that are already
1786 in progress.
1787 .sp
1788 Default value: \fB0\fR.
1789 .RE
1790
1791 .sp
1792 .ne 2
1793 .na
1794 \fBzfs_scan_max_ext_gap\fR (int)
1795 .ad
1796 .RS 12n
1797 Indicates the largest gap in bytes between scrub / resilver I/Os that will still
1798 be considered sequential for sorting purposes. Changing this value will not
1799 affect scrubs or resilvers that are already in progress.
1800 .sp
1801 Default value: \fB2097152 (2 MB)\fR.
1802 .RE
1803
1804 .sp
1805 .ne 2
1806 .na
1807 \fBzfs_scan_mem_lim_fact\fR (int)
1808 .ad
1809 .RS 12n
1810 Maximum fraction of RAM used for I/O sorting by sequential scan algorithm.
1811 This tunable determines the hard limit for I/O sorting memory usage.
1812 When the hard limit is reached we stop scanning metadata and start issuing
1813 data verification I/O. This is done until we get below the soft limit.
1814 .sp
1815 Default value: \fB20\fR which is 5% of RAM (1/20).
1816 .RE
1817
1818 .sp
1819 .ne 2
1820 .na
1821 \fBzfs_scan_mem_lim_soft_fact\fR (int)
1822 .ad
1823 .RS 12n
1824 The fraction of the hard limit used to determined the soft limit for I/O sorting
1825 by the sequential scan algorithm. When we cross this limit from bellow no action
1826 is taken. When we cross this limit from above it is because we are issuing
1827 verification I/O. In this case (unless the metadata scan is done) we stop
1828 issuing verification I/O and start scanning metadata again until we get to the
1829 hard limit.
1830 .sp
1831 Default value: \fB20\fR which is 5% of the hard limit (1/20).
1832 .RE
1833
1834 .sp
1835 .ne 2
1836 .na
1837 \fBzfs_scan_vdev_limit\fR (int)
1838 .ad
1839 .RS 12n
1840 Maximum amount of data that can be concurrently issued at once for scrubs and
1841 resilvers per leaf device, given in bytes.
1842 .sp
1843 Default value: \fB41943040\fR.
1844 .RE
1845
1846 .sp
1847 .ne 2
1848 .na
1849 \fBzfs_send_corrupt_data\fR (int)
1850 .ad
1851 .RS 12n
1852 Allow sending of corrupt data (ignore read/checksum errors when sending data)
1853 .sp
1854 Use \fB1\fR for yes and \fB0\fR for no (default).
1855 .RE
1856
1857 .sp
1858 .ne 2
1859 .na
1860 \fBzfs_sync_pass_deferred_free\fR (int)
1861 .ad
1862 .RS 12n
1863 Flushing of data to disk is done in passes. Defer frees starting in this pass
1864 .sp
1865 Default value: \fB2\fR.
1866 .RE
1867
1868 .sp
1869 .ne 2
1870 .na
1871 \fBzfs_sync_pass_dont_compress\fR (int)
1872 .ad
1873 .RS 12n
1874 Don't compress starting in this pass
1875 .sp
1876 Default value: \fB5\fR.
1877 .RE
1878
1879 .sp
1880 .ne 2
1881 .na
1882 \fBzfs_sync_pass_rewrite\fR (int)
1883 .ad
1884 .RS 12n
1885 Rewrite new block pointers starting in this pass
1886 .sp
1887 Default value: \fB2\fR.
1888 .RE
1889
1890 .sp
1891 .ne 2
1892 .na
1893 \fBzfs_sync_taskq_batch_pct\fR (int)
1894 .ad
1895 .RS 12n
1896 This controls the number of threads used by the dp_sync_taskq. The default
1897 value of 75% will create a maximum of one thread per cpu.
1898 .sp
1899 Default value: \fB75\fR%.
1900 .RE
1901
1902 .sp
1903 .ne 2
1904 .na
1905 \fBzfs_txg_history\fR (int)
1906 .ad
1907 .RS 12n
1908 Historical statistics for the last N txgs will be available in
1909 \fB/proc/spl/kstat/zfs/<pool>/txgs\fR
1910 .sp
1911 Default value: \fB0\fR.
1912 .RE
1913
1914 .sp
1915 .ne 2
1916 .na
1917 \fBzfs_txg_timeout\fR (int)
1918 .ad
1919 .RS 12n
1920 Flush dirty data to disk at least every N seconds (maximum txg duration)
1921 .sp
1922 Default value: \fB5\fR.
1923 .RE
1924
1925 .sp
1926 .ne 2
1927 .na
1928 \fBzfs_vdev_aggregation_limit\fR (int)
1929 .ad
1930 .RS 12n
1931 Max vdev I/O aggregation size
1932 .sp
1933 Default value: \fB131,072\fR.
1934 .RE
1935
1936 .sp
1937 .ne 2
1938 .na
1939 \fBzfs_vdev_cache_bshift\fR (int)
1940 .ad
1941 .RS 12n
1942 Shift size to inflate reads too
1943 .sp
1944 Default value: \fB16\fR (effectively 65536).
1945 .RE
1946
1947 .sp
1948 .ne 2
1949 .na
1950 \fBzfs_vdev_cache_max\fR (int)
1951 .ad
1952 .RS 12n
1953 Inflate reads smaller than this value to meet the \fBzfs_vdev_cache_bshift\fR
1954 size (default 64k).
1955 .sp
1956 Default value: \fB16384\fR.
1957 .RE
1958
1959 .sp
1960 .ne 2
1961 .na
1962 \fBzfs_vdev_cache_size\fR (int)
1963 .ad
1964 .RS 12n
1965 Total size of the per-disk cache in bytes.
1966 .sp
1967 Currently this feature is disabled as it has been found to not be helpful
1968 for performance and in some cases harmful.
1969 .sp
1970 Default value: \fB0\fR.
1971 .RE
1972
1973 .sp
1974 .ne 2
1975 .na
1976 \fBzfs_vdev_mirror_rotating_inc\fR (int)
1977 .ad
1978 .RS 12n
1979 A number by which the balancing algorithm increments the load calculation for
1980 the purpose of selecting the least busy mirror member when an I/O immediately
1981 follows its predecessor on rotational vdevs for the purpose of making decisions
1982 based on load.
1983 .sp
1984 Default value: \fB0\fR.
1985 .RE
1986
1987 .sp
1988 .ne 2
1989 .na
1990 \fBzfs_vdev_mirror_rotating_seek_inc\fR (int)
1991 .ad
1992 .RS 12n
1993 A number by which the balancing algorithm increments the load calculation for
1994 the purpose of selecting the least busy mirror member when an I/O lacks
1995 locality as defined by the zfs_vdev_mirror_rotating_seek_offset. I/Os within
1996 this that are not immediately following the previous I/O are incremented by
1997 half.
1998 .sp
1999 Default value: \fB5\fR.
2000 .RE
2001
2002 .sp
2003 .ne 2
2004 .na
2005 \fBzfs_vdev_mirror_rotating_seek_offset\fR (int)
2006 .ad
2007 .RS 12n
2008 The maximum distance for the last queued I/O in which the balancing algorithm
2009 considers an I/O to have locality.
2010 See the section "ZFS I/O SCHEDULER".
2011 .sp
2012 Default value: \fB1048576\fR.
2013 .RE
2014
2015 .sp
2016 .ne 2
2017 .na
2018 \fBzfs_vdev_mirror_non_rotating_inc\fR (int)
2019 .ad
2020 .RS 12n
2021 A number by which the balancing algorithm increments the load calculation for
2022 the purpose of selecting the least busy mirror member on non-rotational vdevs
2023 when I/Os do not immediately follow one another.
2024 .sp
2025 Default value: \fB0\fR.
2026 .RE
2027
2028 .sp
2029 .ne 2
2030 .na
2031 \fBzfs_vdev_mirror_non_rotating_seek_inc\fR (int)
2032 .ad
2033 .RS 12n
2034 A number by which the balancing algorithm increments the load calculation for
2035 the purpose of selecting the least busy mirror member when an I/O lacks
2036 locality as defined by the zfs_vdev_mirror_rotating_seek_offset. I/Os within
2037 this that are not immediately following the previous I/O are incremented by
2038 half.
2039 .sp
2040 Default value: \fB1\fR.
2041 .RE
2042
2043 .sp
2044 .ne 2
2045 .na
2046 \fBzfs_vdev_read_gap_limit\fR (int)
2047 .ad
2048 .RS 12n
2049 Aggregate read I/O operations if the gap on-disk between them is within this
2050 threshold.
2051 .sp
2052 Default value: \fB32,768\fR.
2053 .RE
2054
2055 .sp
2056 .ne 2
2057 .na
2058 \fBzfs_vdev_scheduler\fR (charp)
2059 .ad
2060 .RS 12n
2061 Set the Linux I/O scheduler on whole disk vdevs to this scheduler. Valid options
2062 are noop, cfq, bfq & deadline
2063 .sp
2064 Default value: \fBnoop\fR.
2065 .RE
2066
2067 .sp
2068 .ne 2
2069 .na
2070 \fBzfs_vdev_write_gap_limit\fR (int)
2071 .ad
2072 .RS 12n
2073 Aggregate write I/O over gap
2074 .sp
2075 Default value: \fB4,096\fR.
2076 .RE
2077
2078 .sp
2079 .ne 2
2080 .na
2081 \fBzfs_vdev_raidz_impl\fR (string)
2082 .ad
2083 .RS 12n
2084 Parameter for selecting raidz parity implementation to use.
2085
2086 Options marked (always) below may be selected on module load as they are
2087 supported on all systems.
2088 The remaining options may only be set after the module is loaded, as they
2089 are available only if the implementations are compiled in and supported
2090 on the running system.
2091
2092 Once the module is loaded, the content of
2093 /sys/module/zfs/parameters/zfs_vdev_raidz_impl will show available options
2094 with the currently selected one enclosed in [].
2095 Possible options are:
2096 fastest - (always) implementation selected using built-in benchmark
2097 original - (always) original raidz implementation
2098 scalar - (always) scalar raidz implementation
2099 sse2 - implementation using SSE2 instruction set (64bit x86 only)
2100 ssse3 - implementation using SSSE3 instruction set (64bit x86 only)
2101 avx2 - implementation using AVX2 instruction set (64bit x86 only)
2102 avx512f - implementation using AVX512F instruction set (64bit x86 only)
2103 avx512bw - implementation using AVX512F & AVX512BW instruction sets (64bit x86 only)
2104 aarch64_neon - implementation using NEON (Aarch64/64 bit ARMv8 only)
2105 aarch64_neonx2 - implementation using NEON with more unrolling (Aarch64/64 bit ARMv8 only)
2106 .sp
2107 Default value: \fBfastest\fR.
2108 .RE
2109
2110 .sp
2111 .ne 2
2112 .na
2113 \fBzfs_zevent_cols\fR (int)
2114 .ad
2115 .RS 12n
2116 When zevents are logged to the console use this as the word wrap width.
2117 .sp
2118 Default value: \fB80\fR.
2119 .RE
2120
2121 .sp
2122 .ne 2
2123 .na
2124 \fBzfs_zevent_console\fR (int)
2125 .ad
2126 .RS 12n
2127 Log events to the console
2128 .sp
2129 Use \fB1\fR for yes and \fB0\fR for no (default).
2130 .RE
2131
2132 .sp
2133 .ne 2
2134 .na
2135 \fBzfs_zevent_len_max\fR (int)
2136 .ad
2137 .RS 12n
2138 Max event queue length. A value of 0 will result in a calculated value which
2139 increases with the number of CPUs in the system (minimum 64 events). Events
2140 in the queue can be viewed with the \fBzpool events\fR command.
2141 .sp
2142 Default value: \fB0\fR.
2143 .RE
2144
2145 .sp
2146 .ne 2
2147 .na
2148 \fBzfs_zil_clean_taskq_maxalloc\fR (int)
2149 .ad
2150 .RS 12n
2151 The maximum number of taskq entries that are allowed to be cached. When this
2152 limit is exceeded transaction records (itxs) will be cleaned synchronously.
2153 .sp
2154 Default value: \fB1048576\fR.
2155 .RE
2156
2157 .sp
2158 .ne 2
2159 .na
2160 \fBzfs_zil_clean_taskq_minalloc\fR (int)
2161 .ad
2162 .RS 12n
2163 The number of taskq entries that are pre-populated when the taskq is first
2164 created and are immediately available for use.
2165 .sp
2166 Default value: \fB1024\fR.
2167 .RE
2168
2169 .sp
2170 .ne 2
2171 .na
2172 \fBzfs_zil_clean_taskq_nthr_pct\fR (int)
2173 .ad
2174 .RS 12n
2175 This controls the number of threads used by the dp_zil_clean_taskq. The default
2176 value of 100% will create a maximum of one thread per cpu.
2177 .sp
2178 Default value: \fB100\fR%.
2179 .RE
2180
2181 .sp
2182 .ne 2
2183 .na
2184 \fBzil_replay_disable\fR (int)
2185 .ad
2186 .RS 12n
2187 Disable intent logging replay. Can be disabled for recovery from corrupted
2188 ZIL
2189 .sp
2190 Use \fB1\fR for yes and \fB0\fR for no (default).
2191 .RE
2192
2193 .sp
2194 .ne 2
2195 .na
2196 \fBzil_slog_bulk\fR (ulong)
2197 .ad
2198 .RS 12n
2199 Limit SLOG write size per commit executed with synchronous priority.
2200 Any writes above that will be executed with lower (asynchronous) priority
2201 to limit potential SLOG device abuse by single active ZIL writer.
2202 .sp
2203 Default value: \fB786,432\fR.
2204 .RE
2205
2206 .sp
2207 .ne 2
2208 .na
2209 \fBzio_delay_max\fR (int)
2210 .ad
2211 .RS 12n
2212 A zevent will be logged if a ZIO operation takes more than N milliseconds to
2213 complete. Note that this is only a logging facility, not a timeout on
2214 operations.
2215 .sp
2216 Default value: \fB30,000\fR.
2217 .RE
2218
2219 .sp
2220 .ne 2
2221 .na
2222 \fBzio_dva_throttle_enabled\fR (int)
2223 .ad
2224 .RS 12n
2225 Throttle block allocations in the ZIO pipeline. This allows for
2226 dynamic allocation distribution when devices are imbalanced.
2227 When enabled, the maximum number of pending allocations per top-level vdev
2228 is limited by \fBzfs_vdev_queue_depth_pct\fR.
2229 .sp
2230 Default value: \fB1\fR.
2231 .RE
2232
2233 .sp
2234 .ne 2
2235 .na
2236 \fBzio_requeue_io_start_cut_in_line\fR (int)
2237 .ad
2238 .RS 12n
2239 Prioritize requeued I/O
2240 .sp
2241 Default value: \fB0\fR.
2242 .RE
2243
2244 .sp
2245 .ne 2
2246 .na
2247 \fBzio_taskq_batch_pct\fR (uint)
2248 .ad
2249 .RS 12n
2250 Percentage of online CPUs (or CPU cores, etc) which will run a worker thread
2251 for IO. These workers are responsible for IO work such as compression and
2252 checksum calculations. Fractional number of CPUs will be rounded down.
2253 .sp
2254 The default value of 75 was chosen to avoid using all CPUs which can result in
2255 latency issues and inconsistent application performance, especially when high
2256 compression is enabled.
2257 .sp
2258 Default value: \fB75\fR.
2259 .RE
2260
2261 .sp
2262 .ne 2
2263 .na
2264 \fBzvol_inhibit_dev\fR (uint)
2265 .ad
2266 .RS 12n
2267 Do not create zvol device nodes. This may slightly improve startup time on
2268 systems with a very large number of zvols.
2269 .sp
2270 Use \fB1\fR for yes and \fB0\fR for no (default).
2271 .RE
2272
2273 .sp
2274 .ne 2
2275 .na
2276 \fBzvol_major\fR (uint)
2277 .ad
2278 .RS 12n
2279 Major number for zvol block devices
2280 .sp
2281 Default value: \fB230\fR.
2282 .RE
2283
2284 .sp
2285 .ne 2
2286 .na
2287 \fBzvol_max_discard_blocks\fR (ulong)
2288 .ad
2289 .RS 12n
2290 Discard (aka TRIM) operations done on zvols will be done in batches of this
2291 many blocks, where block size is determined by the \fBvolblocksize\fR property
2292 of a zvol.
2293 .sp
2294 Default value: \fB16,384\fR.
2295 .RE
2296
2297 .sp
2298 .ne 2
2299 .na
2300 \fBzvol_prefetch_bytes\fR (uint)
2301 .ad
2302 .RS 12n
2303 When adding a zvol to the system prefetch \fBzvol_prefetch_bytes\fR
2304 from the start and end of the volume. Prefetching these regions
2305 of the volume is desirable because they are likely to be accessed
2306 immediately by \fBblkid(8)\fR or by the kernel scanning for a partition
2307 table.
2308 .sp
2309 Default value: \fB131,072\fR.
2310 .RE
2311
2312 .sp
2313 .ne 2
2314 .na
2315 \fBzvol_request_sync\fR (uint)
2316 .ad
2317 .RS 12n
2318 When processing I/O requests for a zvol submit them synchronously. This
2319 effectively limits the queue depth to 1 for each I/O submitter. When set
2320 to 0 requests are handled asynchronously by a thread pool. The number of
2321 requests which can be handled concurrently is controller by \fBzvol_threads\fR.
2322 .sp
2323 Default value: \fB0\fR.
2324 .RE
2325
2326 .sp
2327 .ne 2
2328 .na
2329 \fBzvol_threads\fR (uint)
2330 .ad
2331 .RS 12n
2332 Max number of threads which can handle zvol I/O requests concurrently.
2333 .sp
2334 Default value: \fB32\fR.
2335 .RE
2336
2337 .sp
2338 .ne 2
2339 .na
2340 \fBzvol_volmode\fR (uint)
2341 .ad
2342 .RS 12n
2343 Defines zvol block devices behaviour when \fBvolmode\fR is set to \fBdefault\fR.
2344 Valid values are \fB1\fR (full), \fB2\fR (dev) and \fB3\fR (none).
2345 .sp
2346 Default value: \fB1\fR.
2347 .RE
2348
2349 .sp
2350 .ne 2
2351 .na
2352 \fBzfs_qat_disable\fR (int)
2353 .ad
2354 .RS 12n
2355 This tunable disables qat hardware acceleration for gzip compression and.
2356 AES-GCM encryption. It is available only if qat acceleration is compiled in
2357 and the qat driver is present.
2358 .sp
2359 Use \fB1\fR for yes and \fB0\fR for no (default).
2360 .RE
2361
2362 .SH ZFS I/O SCHEDULER
2363 ZFS issues I/O operations to leaf vdevs to satisfy and complete I/Os.
2364 The I/O scheduler determines when and in what order those operations are
2365 issued. The I/O scheduler divides operations into five I/O classes
2366 prioritized in the following order: sync read, sync write, async read,
2367 async write, and scrub/resilver. Each queue defines the minimum and
2368 maximum number of concurrent operations that may be issued to the
2369 device. In addition, the device has an aggregate maximum,
2370 \fBzfs_vdev_max_active\fR. Note that the sum of the per-queue minimums
2371 must not exceed the aggregate maximum. If the sum of the per-queue
2372 maximums exceeds the aggregate maximum, then the number of active I/Os
2373 may reach \fBzfs_vdev_max_active\fR, in which case no further I/Os will
2374 be issued regardless of whether all per-queue minimums have been met.
2375 .sp
2376 For many physical devices, throughput increases with the number of
2377 concurrent operations, but latency typically suffers. Further, physical
2378 devices typically have a limit at which more concurrent operations have no
2379 effect on throughput or can actually cause it to decrease.
2380 .sp
2381 The scheduler selects the next operation to issue by first looking for an
2382 I/O class whose minimum has not been satisfied. Once all are satisfied and
2383 the aggregate maximum has not been hit, the scheduler looks for classes
2384 whose maximum has not been satisfied. Iteration through the I/O classes is
2385 done in the order specified above. No further operations are issued if the
2386 aggregate maximum number of concurrent operations has been hit or if there
2387 are no operations queued for an I/O class that has not hit its maximum.
2388 Every time an I/O is queued or an operation completes, the I/O scheduler
2389 looks for new operations to issue.
2390 .sp
2391 In general, smaller max_active's will lead to lower latency of synchronous
2392 operations. Larger max_active's may lead to higher overall throughput,
2393 depending on underlying storage.
2394 .sp
2395 The ratio of the queues' max_actives determines the balance of performance
2396 between reads, writes, and scrubs. E.g., increasing
2397 \fBzfs_vdev_scrub_max_active\fR will cause the scrub or resilver to complete
2398 more quickly, but reads and writes to have higher latency and lower throughput.
2399 .sp
2400 All I/O classes have a fixed maximum number of outstanding operations
2401 except for the async write class. Asynchronous writes represent the data
2402 that is committed to stable storage during the syncing stage for
2403 transaction groups. Transaction groups enter the syncing state
2404 periodically so the number of queued async writes will quickly burst up
2405 and then bleed down to zero. Rather than servicing them as quickly as
2406 possible, the I/O scheduler changes the maximum number of active async
2407 write I/Os according to the amount of dirty data in the pool. Since
2408 both throughput and latency typically increase with the number of
2409 concurrent operations issued to physical devices, reducing the
2410 burstiness in the number of concurrent operations also stabilizes the
2411 response time of operations from other -- and in particular synchronous
2412 -- queues. In broad strokes, the I/O scheduler will issue more
2413 concurrent operations from the async write queue as there's more dirty
2414 data in the pool.
2415 .sp
2416 Async Writes
2417 .sp
2418 The number of concurrent operations issued for the async write I/O class
2419 follows a piece-wise linear function defined by a few adjustable points.
2420 .nf
2421
2422 | o---------| <-- zfs_vdev_async_write_max_active
2423 ^ | /^ |
2424 | | / | |
2425 active | / | |
2426 I/O | / | |
2427 count | / | |
2428 | / | |
2429 |-------o | | <-- zfs_vdev_async_write_min_active
2430 0|_______^______|_________|
2431 0% | | 100% of zfs_dirty_data_max
2432 | |
2433 | `-- zfs_vdev_async_write_active_max_dirty_percent
2434 `--------- zfs_vdev_async_write_active_min_dirty_percent
2435
2436 .fi
2437 Until the amount of dirty data exceeds a minimum percentage of the dirty
2438 data allowed in the pool, the I/O scheduler will limit the number of
2439 concurrent operations to the minimum. As that threshold is crossed, the
2440 number of concurrent operations issued increases linearly to the maximum at
2441 the specified maximum percentage of the dirty data allowed in the pool.
2442 .sp
2443 Ideally, the amount of dirty data on a busy pool will stay in the sloped
2444 part of the function between \fBzfs_vdev_async_write_active_min_dirty_percent\fR
2445 and \fBzfs_vdev_async_write_active_max_dirty_percent\fR. If it exceeds the
2446 maximum percentage, this indicates that the rate of incoming data is
2447 greater than the rate that the backend storage can handle. In this case, we
2448 must further throttle incoming writes, as described in the next section.
2449
2450 .SH ZFS TRANSACTION DELAY
2451 We delay transactions when we've determined that the backend storage
2452 isn't able to accommodate the rate of incoming writes.
2453 .sp
2454 If there is already a transaction waiting, we delay relative to when
2455 that transaction will finish waiting. This way the calculated delay time
2456 is independent of the number of threads concurrently executing
2457 transactions.
2458 .sp
2459 If we are the only waiter, wait relative to when the transaction
2460 started, rather than the current time. This credits the transaction for
2461 "time already served", e.g. reading indirect blocks.
2462 .sp
2463 The minimum time for a transaction to take is calculated as:
2464 .nf
2465 min_time = zfs_delay_scale * (dirty - min) / (max - dirty)
2466 min_time is then capped at 100 milliseconds.
2467 .fi
2468 .sp
2469 The delay has two degrees of freedom that can be adjusted via tunables. The
2470 percentage of dirty data at which we start to delay is defined by
2471 \fBzfs_delay_min_dirty_percent\fR. This should typically be at or above
2472 \fBzfs_vdev_async_write_active_max_dirty_percent\fR so that we only start to
2473 delay after writing at full speed has failed to keep up with the incoming write
2474 rate. The scale of the curve is defined by \fBzfs_delay_scale\fR. Roughly speaking,
2475 this variable determines the amount of delay at the midpoint of the curve.
2476 .sp
2477 .nf
2478 delay
2479 10ms +-------------------------------------------------------------*+
2480 | *|
2481 9ms + *+
2482 | *|
2483 8ms + *+
2484 | * |
2485 7ms + * +
2486 | * |
2487 6ms + * +
2488 | * |
2489 5ms + * +
2490 | * |
2491 4ms + * +
2492 | * |
2493 3ms + * +
2494 | * |
2495 2ms + (midpoint) * +
2496 | | ** |
2497 1ms + v *** +
2498 | zfs_delay_scale ----------> ******** |
2499 0 +-------------------------------------*********----------------+
2500 0% <- zfs_dirty_data_max -> 100%
2501 .fi
2502 .sp
2503 Note that since the delay is added to the outstanding time remaining on the
2504 most recent transaction, the delay is effectively the inverse of IOPS.
2505 Here the midpoint of 500us translates to 2000 IOPS. The shape of the curve
2506 was chosen such that small changes in the amount of accumulated dirty data
2507 in the first 3/4 of the curve yield relatively small differences in the
2508 amount of delay.
2509 .sp
2510 The effects can be easier to understand when the amount of delay is
2511 represented on a log scale:
2512 .sp
2513 .nf
2514 delay
2515 100ms +-------------------------------------------------------------++
2516 + +
2517 | |
2518 + *+
2519 10ms + *+
2520 + ** +
2521 | (midpoint) ** |
2522 + | ** +
2523 1ms + v **** +
2524 + zfs_delay_scale ----------> ***** +
2525 | **** |
2526 + **** +
2527 100us + ** +
2528 + * +
2529 | * |
2530 + * +
2531 10us + * +
2532 + +
2533 | |
2534 + +
2535 +--------------------------------------------------------------+
2536 0% <- zfs_dirty_data_max -> 100%
2537 .fi
2538 .sp
2539 Note here that only as the amount of dirty data approaches its limit does
2540 the delay start to increase rapidly. The goal of a properly tuned system
2541 should be to keep the amount of dirty data out of that range by first
2542 ensuring that the appropriate limits are set for the I/O scheduler to reach
2543 optimal throughput on the backend storage, and then by changing the value
2544 of \fBzfs_delay_scale\fR to increase the steepness of the curve.