# $Id: README,v 1.2 2008/07/29 17:48:41 ksb Exp $ This program implements a shell level interface to the PEG sampler host. We take updates from a file (really stdin), which we package then send to peg. We expect updates in the form: update class/host/thing.rrd Ds1:Ds2:... Date:Sample2:Samlpe2:...\n where: update Is the literal word "update", class/host/thing.rrd Is the path from current working directory of the rrdd daemon we want to update, Ds1:Ds2:... Are the names of the data sources (DS in RRD speak) we just sampled, Date Can be either [Thu Nov 24 18:22:48 1986] A date in ctime(3) format w/o the "\n\000" enclosed in square brackets, or N The string "N" for the present time 1217353324 An integral seconds since the epoch Sample2:Samlpe2:... The sample values that match the DS names sent in the order presented \n is a newline character. This is not the preferred way to send updates, as is forks another process to do the (simple) UDP datagram formatting. The better way to to take the "sampler.pl" perl script as a template to code your own sample that is persitant and takes all the std options. If you can code a sampler as a function in perl (mkUpdate in the example sampler) which returns the same text as rrdup(1) takes, without the word "update " on the front, then you are in much better shape than starting with a shell script and a pipe to rrdup. -- ksb, July 2008