[rrd-users] Unable to print date to the graph

Emre Aydın emraydin at gmail.com
Tue Feb 21 20:45:17 CET 2012


I'm not sure why you're using GPRINT.
I add the date to my graphs too in my bash script. But I add it as a
COMMENT. Here's the basic idea.

time_readible=$(echo $(date) | sed 's/\:/\\:/g')

COMMENT:"Last Update: $time_readible"

the sed line is just to add a backslash before every semi-colon (so that
rrdtool won't think of it as a command like it happened earlier to you)

Hope this helps,

On Tue, Feb 21, 2012 at 9:30 PM, Sebastian John <basti at fukz.de> wrote:

> Hello,
>
> Yes, it seems the semicolon is wrong. But now I get an other error:
>
>  ERROR: bad format for GPRINT in '  max %0.2lf %H '
>
> Sebastian
>
> On Tue, Feb 21, 2012 at 06:48:21PM +0200, Emre Aydın wrote:
> > Maybe i'm wrong but the semicolon (:) before the %H shouldn't be there?
> >
> > On Tue, Feb 21, 2012 at 5:35 PM, Sebastian John <basti at fukz.de> wrote:
> >
> > > Hallo,
> > >
> > > I have a problem while printing the date/time of a vdef to my
> > > graph. Maybe its a problem understanding the syntax. Hope you can help
> > > me.
> > >
> > > My graph definition (snipped)
> > >
> > > ..
> > > VDEF:tmax=tmp,MAXIMUM
> > > ..
> > > GPRINT:tmax:"max %0.2lf":"%H"
> > > ..
> > >
> > > I get: ERROR: I don't understand ':%H' in command: 'GPRINT:tmax:max
> > > %0.2lf:%H'.
> > >
> > > what is my fault?
> > >
> > > Sebastian
> > > --
> > >
> > > _______________________________________________
> > > rrd-users mailing list
> > > rrd-users at lists.oetiker.ch
> > > https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users
> > >
> > >
>
> --
>
> _______________________________________________
> rrd-users mailing list
> rrd-users at lists.oetiker.ch
> https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users
>
>


-- 
M. EMRE AYDIN
emraydin at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/rrd-users/attachments/20120221/26bcd8e7/attachment.htm 


More information about the rrd-users mailing list