diff options
author | Brian Behlendorf <[email protected]> | 2014-09-25 15:15:45 -0700 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2014-09-30 10:46:55 -0700 |
commit | aa0ac7caa438bf3981456c559d4224be104ccc7d (patch) | |
tree | f3ddd427d47ad3d28535be3067bbdc4c9f239970 /man/man1 | |
parent | cb08f063074a5363810a39775fd90a4d214c5d87 (diff) |
Make user stack limit configurable
To aid in detecting and debugging stack overflow issues make the
user space stack limit configurable via a new ZFS_STACK_SIZE
environment variable. The value assigned to ZFS_STACK_SIZE will
be used as the default stack size in bytes.
Because this is mainly useful as a debugging aid in conjunction
with ztest the stack limit is disabled by default. See the ztest(1)
man page for additional details on using the ZFS_STACK_SIZE
environment variable.
Signed-off-by: Brian Behlendorf <[email protected]>
Signed-off-by: Ned Bass <[email protected]>
Closes #2743
Issue #2293
Diffstat (limited to 'man/man1')
-rw-r--r-- | man/man1/ztest.1 | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/man/man1/ztest.1 b/man/man1/ztest.1 index 961a5b0de..f798bcfcb 100644 --- a/man/man1/ztest.1 +++ b/man/man1/ztest.1 @@ -144,6 +144,22 @@ Maybe you'd like to run ztest for longer? To do so simply use the -T option and specify the runlength in seconds like so: .IP ztest -f / -V -T 120 + +.SH "ENVIRONMENT VARIABLES" +.TP +.B "ZFS_STACK_SIZE=stacksize" +Limit the default stack size to \fBstacksize\fR bytes for the purpose of +detecting and debugging kernel stack overflows. For x86_64 platforms this +value should be set as follows to simulate these platforms: \fB8192\fR +(Linux), \fB20480\fR (Illumos), \fB16384\fR (FreeBSD). + +In practice you may need to set these value slightly higher because +differences in stack usage between kernel and user space can lead to spurious +stack overflows (especially when debugging is enabled). The specified value +will be rounded up to a floor of PTHREAD_STACK_MIN which is the minimum stack +required for a NULL procedure in user space. + +By default the stack size is limited to 256K. .SH "SEE ALSO" .BR "zpool (1)" "," .BR "zfs (1)" "," |