[rrd-users] Re: probelms with timestamp

Patrick Ammann Patrick.Ammann at nextra.ch
Fri Apr 14 15:31:05 MEST 2000


hi again,


thnx for all your help. the problem could be solved.

i just post how I did it. Prehaps it will also help some other maillist 
members.

my $slastupdate = scalar localtime(RRDs::last $sRRDfile);
          $slastupdate =~ /(\d{1,2}\:\d{1,2}\:\d{1,2})/;
          $slastupdate=$1;

'COMMENT:Last update: '.$slastupdate .' \\r',

Just a little other question. Is there a documentation on the different
possibilities to format the text in the png files ?

geetings,
patrick


At 10:54 14.04.00 +0200, you wrote:
>In article <4.2.0.58.20000413153724.00a61da0 at mail.nextra.ch> you wrote:
>
> > i just have a little probelm. I'm just generationg some graphs and all
> > works fine, except the time-value. I want to put a text like "last updated
> > on " in my png files. I managed to get used bandwith etc. values in the
> > graph but not the timestamp from the last entrie in the RRD file. I 
> already
> > tried it on different ways but the result was always the same - it doesn't
> > work.
> >
> > could someone give me some help ?
>
>A workaround:
>
>$last = RRDs::last('rrdfile');
>$lasttime=localtime($lasttime);
>$lasttime =~ s/:/\\:/;
>push (@aDEF, 'COMMENT:Current Timestamp\: '.$lasttime.'\\r');
>
>BTW: Why is it necessary to excape : in the comment/legend strings? They are
>the last fields in the arguments ...
>
>Rainer
>--
>Rainer.Bawidamann at informatik.uni-ulm.de
>
>--
>Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
>Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
>Archive     http://www.ee.ethz.ch/~slist/rrd-users

--
Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-users



More information about the rrd-users mailing list