Search:
wiki:findwave
Last modified 19 months ago Last modified on 02/26/12 12:33:31

# Earthworm Module: findwave

Contributed by:

## Function

Program to listen to a ring, and write to a file the SCN(L)'s of all TRACEBUF or TRACEBUF2 messages found there and some statistics about the SCN(L).

## Details

Findwave is a command line diagnostic program. It attaches to a transport ring and discovers all TRACE_BUF messages on that ring. It then computes some statistics for each SCN, and writes this to a file. This file is rewritten every five seconds, listing the statistics at that time. Findwave also writes the number of distinct SCN's found to stdout.

Findwave attempts to be helpful for configuring WaveServers:

First, it lists the largest packet length (Msg Len Max) found for each SCN - this is suitable for the "Record size" field in wave_serverV.d. Second, it estimates the required tank size for 24 hours of trace data storage. This is computed for each SCN as follows: Find the average time contained in all TRACE_BUF messages seen for this SCN; assume that each message will live in a record of "Max Msg Len" bytes, and compute the number of such records required to store 24 hours of trace data.

Usage: FINDWAVE <ring name> <index size> <days> <file name> <output type>

output type = w for waveserver output, which produces a waveserver

helper file with days = days to save per tank, and index size = the waveserver index size.

output type = d for SCN debug output, still provide days and index size.

For example:

findwave WAVE_RING testfile.txt

This would result in the file containing:

    S	C	N	Msg Len	 Rate	Nmsg	Mb/day

    Max	Min
    8028	HNE	NP	464	464	 100.0	 186	 40.1
    8028	HNN	NP	464	464	 100.0	 187	 40.1
    8028	HNZ	NP	464	464	 100.0	 187	 40.1
    PMR	BHE	AT	2288	1904	 20.0	 14	 8.6
    PMR	BHN	AT	2228	1936	 20.0	 14	 8.0

## Helpful Hints

### Download in other formats:

- Plain Text