How to increase non-interactive desktop heap size for better performance with MAS and WebStatistica?
book
Article ID: KB0082460
calendar_today
Updated On:
Products
Versions
Spotfire Statistica
11 and later versions
Description
Sometimes each Analysis Configuration requires a lot of system resources to run. By default the Windows operating system allows services to use a small amount of resources in comparison to what logged in users can use. This can result in jobs that complete normally in the interactive mode to fail in the non-interactive mode due to not having enough resources to complete.
Note that this article is also applicable if any batch file is scheduled with Windows Task scheduler and the option "Run whether the user is logged on or not"
Issue/Introduction
How to increase non-interactive desktop heap size for better performance with MAS and WebStatistica
Resolution
There is a fundamental system registry entry that can be modified to increase the heap size (memory allocation size) for non-interactive users (like the MAS service and WebStatistica service). 1. Login to the MAS Server/ WebStatistica server as an administrator
2. Open Registry Editor (by typing RegEdit.exe in Windows Run command) : and increase the zzz in the shared section in Windows registry : SharedSection=xxxx,yyyy,zzzzas detailed below : You may the size of the non-interactive desktop heap by editing the SharedSection parameter Windows key in the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\SubSystems key. The SharedSection parameter uses this format to specify heap size: SharedSection=xxxx,yyyy,zzzz
The value xxxx defines the maximum size of the system-wide heap (in kilobytes), yyyy defines the size of each desktop heap, and zzzz defines the size of the desktop heap that is associated with a non-interactive Windows station. The first SharedSection value (typically 1024) defines the heap size common to all desktops. This includes the global handle table (Window handles are unique machine wide) and shared system settings (such as SystemMetrics). It is unlikely you would ever need to change this value.
The second SharedSection value (typically 3072) controls the size of the desktop heap (used for Windows objects). This static value is used to prevent ill- behaved applications from consuming too many resources. Because the desktop heap is mapped into each process' address space, this value should not be set to an arbitrarily high value (as it would decrease performance), but should only be increased sufficiently to allow all the desired applications to run.
The third SharedSection value (typically 768) is the size of the desktop heap for each desktop that is associated with a "non-interactive" window station. Each service executed under a user account will consume the number of kilobytes of desktop heap specified in the third SharedSection value. If this value is not present, the size of the desktop heap for non-interactive window stations will be same as the size specified for interactive window stations (the second SharedSection value). If only two SharedSection values are present, you can add "768" or "3072" as the third value to specify the size of the desktop heap for desktops created in non-interactive window stations depending on the resource allocation needed for scheduled jobs run by services. The third section can be increased to a higher value - for example to 8192, if jobs are failing with out of memory errors in either MAS or WebStatistica context with resource limitation.
Sometimes there is a 4th section, but this is only for server operating systems with Terminal Services\Citrix installed. The fourth section would control the heap size for the logged in terminal or Citrix users. This should be left as is if present.
3. Close the registry and reboot the application server (MAS or WebStatistica) for the changes to take effect.
DISCLAIMER:
TIBCO Software does not provide support for problems that arise from improper modification of the registry. The Windows registry contains information critical to your computer and applications. Make sure you back up the registry before modifying it. For more information on the Windows Registry Editor and how to back up and restore it, refer toMicrosoft Article ID 256986 “Description of the Microsoft Windows registryat Microsoft Support.