Configuring Thread Stack Size: Difference between revisions
(→Configuring your Thread Stack Size: Changing example) |
|||
Line 1: | Line 1: | ||
==About Thread Stack Size== | ==About Thread Stack Size== | ||
Thread stack size is the amount of memory allocated to a single Java Virtual Machine (JVM) thread | Thread stack size is the amount of memory allocated to a single Java Virtual Machine (JVM) thread. The ZCS application can specify JVM thread stack size using '''zmlocalconfig'''. If you are running ZCS 4.5.10 or 5.0, the default thread stack size is 256k. If you are running an earlier version of ZCS, the default thread stack size varies depending on your server. | ||
Systems running a large number of thread stacks may need to set a smaller the thread stack size in order to improve performance. For optimal performance, Zimbra recommends configuring your thread stack size to 256k. | Systems running a large number of thread stacks may need to set a smaller the thread stack size in order to improve performance. For optimal performance, Zimbra recommends configuring your thread stack size to 256k. |
Revision as of 19:21, 17 December 2007
About Thread Stack Size
Thread stack size is the amount of memory allocated to a single Java Virtual Machine (JVM) thread. The ZCS application can specify JVM thread stack size using zmlocalconfig. If you are running ZCS 4.5.10 or 5.0, the default thread stack size is 256k. If you are running an earlier version of ZCS, the default thread stack size varies depending on your server.
Systems running a large number of thread stacks may need to set a smaller the thread stack size in order to improve performance. For optimal performance, Zimbra recommends configuring your thread stack size to 256k.
Important: The thread stack size should never be smaller than 128k. Setting the thread stack size smaller than this can result in a failure to allocate threads.
Configuring your Thread Stack Size
In order to configure this parameter, you must add the –Xss option to tomcat_java_options.
Note: For ZCS 5.0 or later, this options is added to mailboxd_java_options.
The syntax of this parameter is:
-Xss<value>
For example, in order to set the thread stack size to 256k:
zmlocalconfig -e mailboxd_java_options = -client -Xss256k -verbose:gc -XX:+PrintGCDetails
Note: There is no space between the parameter designation and its value.
Monitoring for Thread Stack Size Errors
It is good practice to monitor /opt/zimbra/log/mailbox.log for errors after changing the thread stack size. If you are getting errors such as java.lang.StackOverflowError, your thread stack size is too large.
Related Articles
- Performance Tuning Guidelines for Large Deployments: Java Settings for Tomcat
- CLI zmlocalconfig (Local Configuration)