rtstats - Generate time based statistics from an LDM product queue and transmit to a receiving host using LDM protocol. |
rtstats [-v] [-x] [-H hostname] [-h remote host] [-P port] [-l logdest] [-f feedtype] [-p pattern] [-q queue] [-o offset] [-i interval] |
This program scans an LDM product queue (see pq(3)) and creates products containing statistics about products being received. The products are generated for each incoming feedtype and are assigned the EXP feedtype for transmission. Statistics are reported at 1 minute intervals as new data are being received. Rtstats is typically used in to accumlate data for monitoring the performance of a distributed LDM system. Statistics for various nodes in the system can be compared to ascertain the performance of the network. This program is similar to pqbinstats(1) with the addition of the delivery of the statistics via LDM protocol to a specified host. A separate statistic product will be sent for each feedtype and LDM product origin. That is, each LDM product will be named as follows: |
rtstats-LDMVERSION/LDMHOST/FEEDTYPE/PRODUCT_ORIGIN |
where LDMVERSION is the release number of the LDM distribution, LDMHOST is the machine where rtstats(1) is running, FEEDTYPE is the class of the incoming data, and PRODUCT_ORIGIN is the assigned identifier denoting the original injection host of the data and upstream host identifier if available (LDM 5.2 and later). In addition to cumulative statistics for the individual feeds, the instantaneous product latency for the most recent product received is provided. The arriving statistics may be processed through pqact(1). |
Creation-time of most recent product |
Product-queue insertion-time of most recent product |
Receiving host (eg localhost id) |
Feedtype |
Origin host |
Products received this hour |
Bytes received this hour |
Latency of most recent product |
Average latency of products received this hour |
Peak latency@min/sec past hour |
Version of LDM running on localhost |
-v |
Verbose logging. A line is emitted for every product in the queue whose feed type and identifier match the specified feedtype and pattern. The emitted line contains the UTC date and time, the program name, the product ingest time, feedtype, sequence number, size in bytes, and the product identifier. |
||
-x |
Debugging information is also emitted. |
-H hostname |
Report as host hostname. The default is to report as the value of registry parameter /hostname, if it is set, or the return value of the gethostname(3) function, otherwise. |
-h remote |
Requests that the statistic products be delivered to the LDM server on remote. Defaults to localhost if not specified. |
−l logdest |
Log to dest. One of ’’ (system logging daemon), ’-’ (standard error stream), or file logdest. Default is the standard error stream if the process has a controlling terminal (i.e., the process isn’t a daemon); otherwise, either the LDM log file or the system logging daemon (execute this program with just the option ’-?’ to determine which). |
−f feedtype |
Reads from the product queue only products that have a feedtype that is a member of the feedtype set. The default is "ANY", specifying all feed types. See pqact(1) for a list of basic feed types and the use of feedtype expressions to specify combinations of basic feed types. |
−p pattern |
Reads from the product queue only products whose identifier matches the regular expression pattern. The default is ".*", specifying all products. |
-q queue |
The pathname of the data product queue. The default is $(regutil /queue/path). The configuration default can be overridden by setting the environment variable LDMPQFNAME. |
−i interval |
Polling interval, in seconds. When the end of the queue is reached, the program sleeps and checks for new products in the product queue every interval seconds. When rtstats(1) is run in the same process group as the programs that insert products into the product queue, a signal informs rtstats(1) and all other interested processes in the process group whenever a new product is available. In this case, the interval should be set so that polling timer rarely expires. The default interval is 15 seconds. |
−o offset |
Offset time, in seconds. Begin reading products inserted into the product queue offset seconds earlier than the current time. The default is to begin just after the time stamp of the oldest product in the queue at startup. |
−P port |
Port on the remote system to which to connect. The well-known LDM port is 388. |
SIGTERM |
Normal termination. |
SIGUSR1 |
Refresh logging (if configure(1) executed without the "--with-ulog" option). |
SIGUSR2 |
Toggle logging of verbose messages. |
The following line may be added to the ldmd.conf file to automatically start rtstats(1) when the LDM is started and deliver statistics to the collection server at the Unidata Program Center. |
exec "rtstats -h rtstats.unidata.ucar.edu" |
ldmd(1), pqact(1), pqcat(1), pqbinstats(1), ulog(3), pq(3), gethostbyname(3), syslogd(8), http://www.unidata.ucar.edu/software/ldm/. |
If you have problems with this program, then you should first examine the LDM email archive for similar problems and how they were solved. The email archive is available via the following World Wide Web URL: |
http://www.unidata.ucar.edu/software/ldm/ |
If this does not suffice and your site is a member of the Unidata program, then send an inquiry via email -- together will all relevant information -- to |
support@unidata.ucar.edu |