Displays information and statistics about Replication Server operations.
admin {stats | statistics} [, sysmon | "all" | module_name [, inbound | outbound] [, display_name ]] [, server[, database]] | [instance_id] [, {display |, save} [, obs_interval] [, sample_period]]
Displays statistics only for those counters identified as particularly important for performance and tuning purposes. Counters are selected from nearly all modules. This is the default.
Displays statistics from all counters.
Displays statistics from the named module’s counters, where module_name is cm, dsi, dist, dsiexec, repagent, rsi, rsiuser, serv, sqm, sqt, sts, sync, and others. Use rs_helpcounter to obtain valid module names.
inbound and outbound are types of sqt or sqm. If neither inbound nor outbound is supplied for the sqt or sqm module, Replication Server reports statistics for both types of queues.
Is the name of a counter. Use rs_helpcounter to obtain valid display names. display_name is only used in conjunction with module_name.
If the statistics to be collected are related to a connection, server must be a dataserver and database must be supplied. If the statistics to be collected are related to a route, server must be a Replication Server and you are not allowed to supply database.
Identifies a particular instance of a module such as SQT or SQM. To view instance IDs, execute admin who and view the Info column.
The instance ID 0 indicates Replication Server-wide statistics. It is the instance ID of the Replication Server.
Displays statistics on the computer screen. This is the default.
Saves statistics in the RSSD. Old sampling data is truncated or preserved, depending on the current setting of stats_reset_rssd.
Specifies the length of each observation interval during the sampling period. If you do not specify an interval, there will be only one observation interval with a length equal to the sampling period. Each observation interval must be at least 15 seconds. Format can either be a numeric value in seconds, or “hh:mm[:ss]”.
Indicates the total sampling duration. The default value is zero, which reports the current counter values. With a non-zero value, the current counter values are reset and then collected for the specified sample period. Format can either be a numeric value in seconds, or “hh:mm[:ss]”.
Collects outbound SQT statistics for connection 108 for two minutes and sends the data to the RSSD.
admin stats, sqt, outbound, 108, save, 120
Collects outbound SQT statistics for connection 108 for two hours and sends data to the RSSD. In addition, the sample period is divided into observation intervals of 30 seconds each.
admin stats, sqt, outbound, 108, save, 30, "02:00:00"
Displays statistics for the SQM and SQMR modules for the inbound queue for connection 102.
admin stats, sqm, inbound, 102
Report Time: 10/31/05 02:14:17 PM Instance Instance ID ModType/InstVal -------------------------- ----------- ---------------- SQM, 102:1 pds01.tpcc 102 1 Monitor Obs Last Max Avg ttl/obs --------------------- ------ ------ ------ ------------ #*SegsActive 1 1 1 1 ========================================================================== Instance Instance ID ModType/InstVal ------------------------------ ----------- ---------------- SQMR, 102:1 pds01.tpcc, 0 SQT 102 11 Observer Obs Rate x/sec ---------------------- ------ ---------- SleepsWriteQ 4 0
In output, prefixes that precede counter names provide information about the counter. For example, a preceding # indicates a counter that is not reset, even if admin stats, reset is executed, and a preceding * indicates a counter that must be sampled, irrespective of the setting of stats_sampling. In this example, the SegsActive counter is always sampled and never reset.
Collects statistics for all instances of the SleepsWriteQ counter in the SQM module.
admin stats, sqm, SleepsWriteQ
Report Time 10/31/05 02:17:03 PM Instance Observer Obs Rate x/sec ------------------------------------- ------------- ---- ---------- SQMR, 101:0 edsprs01.edbprs01, 0, DSI SleepsWriteQ 0 0 SQMR, 102:0 pds01.tpcc, 0, DSI SleepsWriteQ 0 0 SQMR, 102:1 pds01.tpcc, 0, DSI SleepsWriteQ 20 0 SQMR, 103:0 rds01.tpcc, 0, DSI SleepsWriteQ 0 0
Starts sampling and saving statistics to the RSSD for one hour and thirty minutes at 20-second intervals:
admin stats, "all", save, 20, "01:30:00"
admin stats collects and displays statistics from Replication Server modules. There are three types of statistics collectors:
Observer – counts the number of times an event occurs. For example, Replication Server uses an observer to count the number of times a command from the RepAgent is observed.
Monitor – periodically samples a value. For example, Replication Server uses a monitor to sample the sizes of sent commands.
Counter – collects statistics not observed by monitors and observers. Counters are usually used to accumulate a running total of a particular value, including the total number of milliseconds required to complete a particular task. For example, Replication Server uses a counter to accumulate the elapsed time between receiving two commands from the RepAgent.
Observer, monitor, and counter watch four types of statistics: number of observations, total observed values, last observed values, and maximum observed values.
admin stats prints a report that includes this information:
Instance – a specific occurrence of a module.
Instance ID – the numeric identifier for a given module instance. For example, two different SQM instances may have instance IDs 102 and 103 respectively.
ModType/InstVal – in some cases, an instance may have multiple versions or module types. For example, a given SQM instance may have an inbound type and an outbound type. For SQM instances, inbound versions have a module type of 1 and outbound versions have a module type of 0.
Monitor, Observer, or Counter – displays the name of the statistics collector being observed. For example, SleepsWriteQ.
Obs – the number of observations of a statistics collector during an observation period.
Last – the last value observed during an observation period.
Max – the maximum value observed during an observation period.
Total – the sum of the observed values during an observation period.
Avg ttl/obs – the average value observed in an observation period. This is calculated as Total/Obs.
Rate x/sec – the change, in a period of 1 second, observed during the given observation period. Observers calculate this as Obs/seconds in an observation period. Monitors and counters calculate this as Total/second in an observation period.
By default, admin stats reports values for the sysmon counters.
By default, admin stats does not report counters that show 0 (zero) observation. To change this behavior, set the stats_show_zero_counters configuration parameter on.
If statistics are displayed on the computer screen, they are not stored in the RSSD. Similarly, if statistics are stored in the RSSD, they are not displayed on screen.
If you use admin stats...display_name to display statistics for a particular counter, Replication Server always displays statistics for that counter, even if stats_sampling is off and the number of observations is zero.
Use admin stats with the independent module name to collect statistics for dependent modules. You cannot collect statistics using the dependent module name in the admin stats command.
Independent module |
Dependent module |
---|---|
Data Server Interface (DSI) |
DSI Executor (DSIEXEC) |
Data Server Interface (DSI) |
Active Object Statistics (AOBJ) |
Stable Queue Manager (SQM) |
SQM Reader (SQMR) |
Thread Synchronization (SYNC) |
SYNC Element (SYNCELE) |
For more information about Replication Server modules, see the Replication Server Administration Guide Volume 2.
Any user may execute this command.