Solaris Containers: Resource Management and Solaris Zones Developer's Guide

Configure Five Applications with Different Characteristics

The following example configures five applications with different characteristics.

Table 8–1 Target Applications and Characteristics

Application Type and Name 


Application server, app_server.

Negative scalability beyond two CPUs. Assign a two-CPU processor set to app_server. Use TS scheduling class.

Database instance, app_db.

Heavily multithreaded. Use FSS scheduling class. 

Test and development, development.

Motif based. Hosts untested code execution. Interactive scheduling class ensures user interface responsiveness. Use process.max-address-space to impose memory limitations and minimize the effects of antisocial processing.

Transaction processing engine, tp_engine.

Response time is paramount. Assign a dedicated set of at least two CPUs to ensure response latency is kept to a minimum. Use timeshare scheduling class. 

Standalone database instance, geo_db.

Heavily multithreaded. Serves multiple time zones. Use FSS scheduling class. 

Note –

Consolidate database applications (app.db and geo_db) onto a single processor set of at least four CPUs. Use FSS scheduling class. Application app_db gets 25% of the project.cpu-shares. Application geo_db gets 75% of the project.cpu-shares.

Edit the /etc/project file. Map users to resource pools for the app_server, app_db, development, tp_engine, and geo_db project entries.

hostname# cat /etc/project

user.app_server:2001:Production Application Server::
user.app_db:2002:App Server DB:::project.pool=db_pool,
development:2003:Test and delopment::staff:project.pool=dev.pool,
user.tp_engine:Transaction Engine:::project.pool=tp_pool
user.geo_db:EDI DB:::project.pool=db_pool;

Note –

The line break in the lines that begin with “project.pool” , “project.cpu-shares=”, “process.max-addressspace”, and “project.cpu-shares=” is not valid in a project file. The line breaks are shown here only to allow the example to display on a printed or displayed page. Each entry must be on one and only one line.

Create the script and add entries for resource pools.

hostname# cat

create system host
create pset dev_pset (unit pset.max = 2)
create pset tp_pset (unit pset.min = 2)
create pset db_pset (unit pset.min = 4; uint pset.max = 6)
create pset app_pset (unit pset.min = 1; uint pset.max = 2)
create pool dev_pool (string pool.scheduler="IA")
create pool appserver_pool (string pool.scheduler="TS")
create pool db_pool (string pool.scheduler="FSS")
create pool tp_pool (string pool.scheduler="TS")
associate pool pool_default (pset pset_default)
associate pool dev_pool (pset dev_pset)
associate pool pool appserver_pool (pset app_pset)
associate pool db_pool (pset db_pset)
associate pool tp_pool (pset tp_pset)

Note –

The line break in the line that begins with “boolean” is not valid in a file. The line break is shown here only to allow the example to display on a printed or displayed page. Each entry must be on one and only one line.

Run the script and modify the configuration as specified in the file.

hostname# poolcfg —f

Read the resource pool configuration file and initialize the resource pools on the system.

hostname# pooladm —c