Solaris Resource Manager 1.3 System Administration Guide

Using the Resource Capping Daemon

Use rcapadm(1MSRM) to configure the daemon.

Selecting the Mode of Operation

Two modes of operation are supported, lnode and project.

To enforce caps defined for lnodes and ignore caps defined for projects, type:


# rcapadm -m lnode

To enforce caps defined for projects and ignore caps defined for lnodes, type:


# rcapadm -m project

Tuning Operation Intervals

You can tune the intervals for the periodic operations performed by rcapd. To reset intervals, use the -i option.


# rcapadm -i interval=value,...,interval=value 

All intervals are specified in seconds. The intervals and their default values are described in the following table.

Interval 

Default Value in Seconds 

Description 

scan

15 

Rate at which rcapd scans for new processes. Minimum value is 1 second.

sample

Rate of process resident set size sampling. Minimum value is 1 second. 

report

5  

Rate at which paging statistics are updated by rcapd for rcapstat. If set to 0, statistics will not be updated.

config

60 

Rate of reconfiguration. In a reconfiguration event, rcapd checks its configuration file for updates, and scans lnode (limits) databases or project databases for new lnode or project caps, or new collections.

If the interval specified to rcapstat is shorter than the interval specified to rcapd (with rcapadm(1MSRM)), the output for some intervals can be zero. This is because rcapd does not update statistics more frequently than the interval specified with rcapadm, and this interval is independent of, and less precise than, the sampling interval used by rcapstat.

Setting Memory Cap Enforcement Value

Caps can be configured so that they will not be enforced until the physical memory available to processes is low. The minimum (and default) value is 0, which means that memory caps are always enforced. To set a different minimum physical memory utilization for memory cap enforcement, type:


# rcapadm -c percent

The percent value should be in the range 0 to 100. The current global physical memory utilization and its cap can be obtained by using the -g option to the rcapstat command. See Reporting Global Memory Caps.

Enabling Resource Capping

To enable the resource capping daemon so that it will be started now and also be started each time the system is booted, type :


# rcapadm -E

To enable the resource capping daemon at boot without affecting its current running status, also specify the -n option:


# rcapadm -n -E

Disabling Resource Capping

To disable the the resource capping daemon so that it will be stopped now and not be started when the system is booted, type :


# rcapadm -D

To disable the resource capping daemon without affecting its current running status, also specify the -n option:


# rcapadm -n -D

Note -

If killed, rcapd can leave processes in a stopped state. See kill(1). Use rcapadm -D or SIGTERM to cause rcapd to terminate properly.