Home | Previous Page | Next Page   Utility Reference > onstat: Monitor Database Server Operations > The onstat -g Monitoring Options >

onstat -g xqs query_id

Prints information about finished iterator instances.

As a query tree executes, some iterators will complete execution before others. Use the onstat -g xqs command to display information about iterator instances that have already completed execution.

At any given point in time, which and how many iterator instances have completed execution depends on the type of the query plan, for example, whether the joins are done with a right-deep, left-deep, or zig-zag plan, and on the type of the iterators in the query plan. In a hash join, for example, when the probe phase in a left-deep query plan is executing, the build phase of the plan, along with all iterators below the build phase, will already have finished.

The format of the onstat -g xqs is similar to that of the "Query Statistics" section of the explain file. The only difference is that because the "Query Statistics" section in the explain file is written after the entire query has completed, the "Query Statistics" section contains information about all iterators in the query plan.

The onstat -g xqs command must always be executed on the connection coserver on which the query was started, though it displays a global view of the query across all coservers. The argument to onstat -g xqs must be the plan id of the query you are interested in monitoring; you can obtain the plan id of the query by using the command onstat -g rgm.

Example Output

Figure 70. onstat -g xqs output
informix@aw3:~> onstat -g xqs 286
IBM Informix Extended Parallel Server Version 8.50.UN439 -- On-Line -- Up 114 days 22:27:35 
-- 223232 Kbytes
XMP Query Statistics
 Cosvr_ID: 1     
 Plan_ID: 286 
  type  segid brid information
  ----  ----- ---- -----------
  scan   3    0    inst cosvr time   rows_prod  rows_scan
                   ---- ----- ----   ---------  ---------
                   0    1     3      498437     498437    
                   1    2     4      501563     501563    
                   --------------------------------------
                   2                 1000000    1000000

Output Description

type
Iterator type
segid
Id of segment in the query execution tree at which iterator is located
brid
Id of the branch in query execution tree at which iterator is located
inst
Iterator instance id
cosvr
Coserver in which iterator instance executed
time
Total execution time in seconds for the iterator instance
rows_prod
Rows produced by the iterator instance, that is, how many rows this iterator instance has sent to the iterator above it in the query execution tree
rows_scan
Rows scanned by the iterator instance
Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]