Skip Navigation Links | |
Exit Print View | |
![]() |
Oracle Solaris Tunable Parameters Reference Manual Oracle Solaris 10 1/13 Information Library |
1. Overview of Oracle Solaris System Tuning
2. Oracle Solaris Kernel Tunable Parameters
Where to Find Tunable Parameter Information
General Kernel and Memory Parameters
fsflush and Related Parameters
General File System Parameters
SPARC System Specific Parameters
Solaris Volume Manager Parameters
3. Oracle Solaris ZFS Tunable Parameters
5. Internet Protocol Suite Tunable Parameters
A. Tunable Parameters Change History
The Solaris OS uses a demand paged virtual memory system. As the system runs, pages are brought into memory as needed. When memory becomes occupied above a certain threshold and demand for memory continues, paging begins. Paging goes through several levels that are controlled by certain parameters.
The general paging algorithm is as follows:
A memory deficit is noticed. The page scanner thread runs and begins to walk through memory. A two-step algorithm is employed:
A page is marked as unused.
If still unused after a time interval, the page is viewed as a subject for reclaim.
If the page has been modified, a request is made to the pageout thread to schedule the page for I/O. Also, the page scanner continues looking at memory. Pageout causes the page to be written to the page's backing store and placed on the free list. When the page scanner scans memory, no distinction is made as to the origin of the page. The page might have come from a data file, or it might represent a page from an executable's text, data, or stack.
As memory pressure on the system increases, the algorithm becomes more aggressive in the pages it will consider as candidates for reclamation and in how frequently the paging algorithm runs. (For more information, see fastscan and slowscan.) As available memory falls between the range lotsfree and minfree, the system linearly increases the amount of memory scanned in each invocation of the pageout thread from the value specified by slowscan to the value specified by fastscan. The system uses the desfree parameter to control a number of decisions about resource usage and behavior.
The system initially constrains itself to use no more than 4 percent of one CPU for pageout operations. As memory pressure increases, the amount of CPU time consumed in support of pageout operations linearly increases until a maximum of 80 percent of one CPU is consumed. The algorithm looks through some amount of memory between slowscan and fastscan, then stops when one of the following occurs:
Enough pages have been found to satisfy the memory shortfall.
The planned number of pages have been looked at.
Too much time has elapsed.
If a memory shortfall is still present when pageout finishes its scan, another scan is scheduled for 1/4 second in the future.
The configuration mechanism of the paging subsystem was changed. Instead of depending on a set of predefined values for fastscan, slowscan, and handspreadpages, the system determines the appropriate settings for these parameters at boot time. Setting any of these parameters in the /etc/system file can cause the system to use less than optimal values.
![]() | Caution - Remove all tuning of the VM system from the /etc/system file. Run with the default settings and determine if it is necessary to adjust any of these parameters. Do not set either cachefree or priority_paging. |
Dynamic reconfiguration (DR) for CPU and memory is supported. A system in a DR operation that involves the addition or deletion of memory recalculates values for the relevant parameters, unless the parameter has been explicitly set in /etc/system. In that case, the value specified in /etc/system is used, unless a constraint on the value of the variable has been violated. In this case, the value is reset.
Serves as the initial trigger for system paging to begin. When this threshold is crossed, the page scanner wakes up to begin looking for memory pages to reclaim.
Unsigned long
The greater of 1/64th of physical memory or 512 KB
The minimum value is 512 KB or 1/64th of physical memory, whichever is greater, expressed as pages using the page size returned by getpagesize. For more information, seegetpagesize(3C).
The maximum value is the number of physical memory pages. The maximum value should be no more than 30 percent of physical memory. The system does not enforce this range, other than that described in the Validation section.
Pages
Yes, but dynamic changes are lost if a memory-based DR operation occurs.
If lotsfree is greater than the amount of physical memory, the value is reset to the default.
The relationship of lotsfree being greater than desfree, which is greater than minfree, should be maintained at all times.
When demand for pages is subject to sudden sharp spikes, the memory algorithm might be unable to keep up with demand. One workaround is to start reclaiming memory at an earlier time. This solution gives the paging system some additional margin.
A rule of thumb is to set this parameter to 2 times what the system needs to allocate in a few seconds. This parameter is workload dependent. A DBMS server can probably work fine with the default settings. However, you might need to adjust this parameter for a system doing heavy file system I/O.
For systems with relatively static workloads and large amounts of memory, lower this value. The minimum acceptable value is 512 KB, expressed as pages using the page size returned by getpagesize.
Unstable
Specifies the preferred amount of memory to be free at all times on the system.
Unsigned integer
lotsfree / 2
The minimum value is 256 KB or 1/128th of physical memory, whichever is greater, expressed as pages using the page size returned by getpagesize.
The maximum value is the number of physical memory pages. The maximum value should be no more than 15 percent of physical memory. The system does not enforce this range other than that described in the Validation section.
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided in the /etc/system file or calculated from the new physical memory value.
If desfree is greater than lotsfree, desfree is set to lotsfree / 2. No message is displayed.
The relationship of lotsfree being greater than desfree, which is greater than minfree, should be maintained at all times.
Several side effects can arise from increasing the value of this parameter. When the new value nears or exceeds the amount of available memory on the system, the following can occur:
Asynchronous I/O requests are not processed, unless available memory exceeds desfree. Increasing the value of desfree can result in rejection of requests that otherwise would succeed.
NFS asynchronous writes are executed as synchronous writes.
The swapper is awakened earlier, and the behavior of the swapper is biased towards more aggressive actions.
The system might not preload (prefault) as many executable pages as possible into the system. This side effect results in applications potentially running slower than they otherwise would.
For systems with relatively static workloads and large amounts of memory, lower this value. The minimum acceptable value is 256 KB, expressed as pages using the page size returned by getpagesize.
Unstable
Specifies the minimum acceptable memory level. When memory drops below this number, the system biases allocations toward allocations necessary to successfully complete pageout operations or to swap processes completely out of memory. Either allocation denies or blocks other allocation requests.
Unsigned integer
desfree / 2
The minimum value is 128 KB or 1/256th of physical memory, whichever is greater, expressed as pages using the page size returned by getpagesize.
The maximum value is the number of physical memory pages. The maximum value should be no more than 7.5 percent of physical memory. The system does not enforce this range other than that described in the Validation section.
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided in the /etc/system file or calculated from the new physical memory value.
If minfree is greater than desfree, minfree is set to desfree / 2. No message is displayed.
The relationship of lotsfree being greater than desfree, which is greater than minfree, should be maintained at all times.
The default value is generally adequate. For systems with relatively static workloads and large amounts of memory, lower this value. The minimum acceptable value is 128 KB, expressed as pages using the page size returned by getpagesize.
Unstable
Specifies the memory level at which blocking memory allocation requests are put to sleep, even if the memory is sufficient to satisfy the request.
Unsigned integer
minfree
The minimum value is 128 KB or 1/256th of physical memory, whichever is greater, expressed as pages using the page size returned by getpagesize.
The maximum value is the number of physical memory pages. The maximum value should be no more than 4 percent of physical memory. The system does not enforce this range other than that described in the Validation section.
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided in the /etc/system file or calculated from the new physical memory value.
If throttlefree is greater than desfree, throttlefree is set to minfree. No message is displayed.
The relationship of lotsfree is greater than desfree, which is greater than minfree, should be maintained at all times.
The default value is generally adequate. For systems with relatively static workloads and large amounts of memory, lower this value. The minimum acceptable value is 128 KB, expressed as pages using the page size returned by getpagesize. For more information, see getpagesize(3C).
Unstable
Specifies the number of pages reserved for the exclusive use of the pageout or scheduler threads. When available memory is less than this value, nonblocking allocations are denied for any processes other than pageout or the scheduler. Pageout needs to have a small pool of memory for its use so it can allocate the data structures necessary to do the I/O for writing a page to its backing store.
Unsigned integer
throttlefree / 2
The minimum value is 64 KB or 1/512th of physical memory, whichever is greater, expressed as pages using the page size returned by getpagesize(3C).
The maximum is the number of physical memory pages. The maximum value should be no more than 2 percent of physical memory. The system does not enforce this range, other than that described in the Validation section.
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided in the /etc/system file or calculated from the new physical memory value.
If pageout_reserve is greater than throttlefree / 2, pageout_reserve is set to throttlefree / 2. No message is displayed.
The relationship of lotsfree being greater than desfree, which is greater than minfree, should be maintained at all times.
The default value is generally adequate. For systems with relatively static workloads and large amounts of memory, lower this value. The minimum acceptable value is 64 KB, expressed as pages using the page size returned by getpagesize.
Unstable
Defines the number of pages that must be unlocked. If a request to lock pages would force available memory below this value, that request is refused.
Unsigned long
The greater of (tune_t_minarmem + 100 and [4% of memory available at boot time + 4 MB])
Minimum value enforced by the system is tune_t_minarmem + 100. The system does not enforce a maximum value.
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided in the /etc/system file or was calculated from the new physical memory value.
If the value specified in the /etc/system file or the calculated default is less than tune_t_minarmem + 100, the value is reset to tune_t_minarmem + 100.
No message is displayed if the value from the /etc/system file is increased. Validation is done only at boot time and during dynamic reconfiguration operations that involve adding or deleting memory.
When memory-locking requests fail or when attaching to a shared memory segment with the SHARE_MMU flag fails, yet the amount of memory available seems to be sufficient.
Excessively large values can cause memory locking requests (mlock, mlockall, and memcntl) to fail unnecessarily. For more information, see mlock(3C), mlockall(3C), and memcntl(2).
Unstable
Defines the minimum available resident (not swappable) memory to maintain necessary to avoid deadlock. Used to reserve a portion of memory for use by the core of the OS. Pages restricted in this way are not seen when the OS determines the maximum amount of memory available.
Signed integer
25
1 to physical memory
Pages
No
None. Large values result in wasted physical memory.
The default value is generally adequate. Consider increasing the default value if the system locks up and debugging information indicates that no memory was available.
Unstable
Defines the maximum number of pages per second that the system looks at when memory pressure is highest.
Signed integer
The fastscan default value is set in one of the following ways:
The fastscan value set in the /etc/system file is used.
The maxfastscan value set in the /etc/system file is used.
If neither fastscan nor maxfastscan is set in the /etc/system file, fastscan is set to 64 MB when the system is booted. Then, after the system is booted for a few minutes, the fastscan value is set to the number of pages that the scanner can scan in one second using 10% of a CPU.
In all three cases, if the derived value is more than half the memory in the system, the fastscan value is capped at the value of half the memory in the system.
64 MB to half the system's physical memory
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided by /etc/system or calculated from the new physical memory value.
The maximum value is the lesser of 64 MB and 1/2 of physical memory.
When more aggressive scanning of memory is preferred during periods of memory shortfall, especially when the system is subject to periods of intense memory demand or when performing heavy file I/O.
Unstable
Defines the minimum number of pages per second that the system looks at when attempting to reclaim memory.
Signed integer
The smaller of 1/20th of physical memory in pages and 100.
1 to fastscan / 2
Pages
Yes, unless dynamic reconfiguration operations that add or delete memory occur. At that point, the value is reset to the value provided in the /etc/system file or calculated from the new physical memory value.
If slowscan is larger than fastscan / 2, slowscan is reset to fastscan / 2. No message is displayed.
When more aggressive scanning of memory is preferred during periods of memory shortfall, especially when the system is subject to periods of intense memory demand.
Unstable
Defines the minimum percentage of CPU that pageout can consume. This parameter is used as the starting point for determining the maximum amount of time that can be consumed by the page scanner.
Signed integer
4
1 to 80
Percentage
Yes
None
Increasing this value on systems with multiple CPUs and lots of memory, which are subject to intense periods of memory demand, enables the pager to spend more time attempting to find memory.
Unstable
The Oracle Solaris OS uses a two-handed clock algorithm to look for pages that are candidates for reclaiming when memory is low. The first hand of the clock walks through memory marking pages as unused. The second hand walks through memory some distance after the first hand, checking to see if the page is still marked as unused. If so, the page is subject to being reclaimed. The distance between the first hand and the second hand is handspreadpages.
Unsigned long
fastscan
1 to maximum number of physical memory pages on the system
Pages
Yes. This parameter requires that the kernel reset_hands parameter also be set to a non-zero value. Once the new value of handspreadpages has been recognized, reset_hands is set to zero.
The value is set to the lesser of either the amount of physical memory and the handspreadpages value.
When you want to increase the amount of time that pages are potentially resident before being reclaimed. Increasing this value increases the separation between the hands, and therefore, the amount of time before a page can be reclaimed.
Unstable
Defines part of a system threshold that immediately frees pages after an I/O completes instead of storing the pages for possible reuse. The threshold is lotsfree + pages_before_pager. The NFS environment also uses this threshold to curtail its asynchronous activities as memory pressure mounts.
Signed integer
200
1 to amount of physical memory
Pages
No
None
You might change this parameter when the majority of I/O is done for pages that are truly read or written once and never referenced again. Setting this variable to a larger amount of memory keeps adding pages to the free list.
You might also change this parameter when the system is subject to bursts of severe memory pressure. A larger value here helps maintain a larger cushion against the pressure.
Unstable
Defines the maximum number of page I/O requests that can be queued by the paging system. This number is divided by 4 to get the actual maximum number used by the paging system. This parameter is used to throttle the number of requests as well as to control process swapping.
Signed integer
40
1 to a variable maximum that depends on the system architecture, but mainly by the I/O subsystem, such as the number of controllers, disks, and disk swap size
I/0s
No
None
The maximum number of I/O requests from the pager is limited by the size of a list of request buffers, which is currently sized at 256.
Increase this parameter to page out memory faster. A larger value might help to recover faster from memory pressure if more than one swap device is configured or if the swap device is a striped device. Note that the existing I/O subsystem should be able to handle the additional I/O load. Also, increased swap I/O could degrade application I/O performance if the swap partition and application files are on the same disk.
Unstable
For information, see maxpgio (Solaris 10 Releases).