onstat -O command: Print optical subsystem information

Use the onstat -O command to display information about the Optical Subsystem memory cache and the staging area blobspace.

Figure 1: Syntax:

1  onstat   -O

Example output

The totals shown in the display accumulate from session to session. The database server resets the totals to 0 only when you run the onstat -z command.

Figure 2: onstat -O command output

Optical StageBlob Cache
System Cache Totals:                                 System Blob Totals:
Size    Alloc.  Avail.              Number   Kbytes  Number  Kbytes
500     500     0                   1        20      3       1500

User Cache Totals:                                   User Blob Totals:
SID     User    Size                Number   Kbytes  Number  Kbytes
94      doug    250                 1        20      1       300
95      beth    500                 0        0       2       1200

Output description

The first section of the display provides the following information on system-cache totals:
size
Is the size that the OPCACHEMAX configuration parameter specifies
alloc
Is the number of 1-kilobyte allocations to the cache
avail
Describes how much of alloc (in kilobytes) is not used
number
Is the number of simple large objects that the database server successfully put in the cache without overflowing
kbytes
Is the number of kilobytes of TEXT or BYTE data that the database server put in the cache without overflowing
number
Is the number of simple large objects that the database server wrote to the staging-area blobspace
kbytes
Is the number of kilobytes of TEXT or BYTE data that the database server wrote to the staging-area blobspace

Although the size output indicates the amount of memory that is specified in the configuration parameter OPCACHEMAX, the database server does not allocate memory to OPCACHEMAX until necessary. Therefore, the alloc output reflects only the number of 1-kilobyte allocations of the largest simple large object that has been processed. When the values in the alloc and avail output are equal to each other, the cache is empty.

The second section of the display describes the following user-cache totals information:
SID
Is the session ID for the user
user
Is the user ID of the client
size
Is the size specified in the INFORMIXOPCACHE environment variable, if it is set

If you do not set the INFORMIXOPCACHE environment variable, the database server uses the size that you specify in the configuration parameter OPCACHEMAX.

number
Is the number of simple large objects that the database server put into cache without overflowing
kbytes
Is the number of kilobytes of TEXT or BYTE data that the database server put in the cache without overflowing
number
Is the number of simple large objects that the database server wrote to the staging-area blobspace
kbytes
Is the number of kilobytes of TEXT or BYTE data that the database server wrote to the staging-area blobspace

The last line of the display lists the total number of sessions that are using the cache.