HP-UX 11i September 2001 Release Notes

Process, Threads, Memory, and Kernel Parameters
Memory Windows
Chapter 8
133
Memory Windows
Running without memory windows, HP-UX has limitations for shared resources on
32-bit applications. All applications in the system are limited to a total of 1.75GB of
shared memory, 2.75GB if compiled as SHMEM_MAGIC. In a system with 16GB of physical
memory, only 1.75 can be used for shared resources.
To address this limitation, a functional change has been made to allow 32-bit processes
to create unique memory windows for shared objects like shared memory.
The memory window for default executables is 1GB.
This allows cooperating applications to create 1GB of shared resources without
exhausting the system-wide resource. Part of the virtual address space remains globally
visible to all processes, so that shared libraries are accessible no matter what memory
window they are in.
Summary of Changes
The following customer-visible changes have been made for memory windows:
New kernel tunable, max_mem_window, to configure the number of memory windows a
system can have.
New set of commands and files (setmemwindow, getmemwindow,
/etc/services.window) to start applications in different memory windows.
Manpages for the new functionality have been created; they are getmemwindow (1M),
setmemwindow (1M), and services.window (4).
See the Memory Windows in HP-UX 11.0 White Paper on http://docs.hp.com for
details.
Compatibility Issues
Incorrect use of memory windows can lead to application failure. Memory windows can
be applied to any application but that does not mean the application is able to run in
memory windows. Some interfaces may break when used under memory windows. HP
does not consider this failure as a compatibility failure as only the application owner or
software provider can certify how and if an application can run under memory windows.
Errors due to incorrect usage may be subtle and normally not associated with memory
windows. In many cases software providers may have already certified their applications
with memory windows. Contact HP to see if this is the case.
Configuration
By default, HP-UX ships with memory windows disabled.
To enable memory windows, set the kernel tunable parameter max_mem_window to the
desired amount. Customers can change this value by placing the desired value in their
kernel configuration file. The system must be rebooted for the new value to take effect.
max_mem_window represents the number of memory windows beyond the global default
window.