[rrd-users] Difficulty setting Graph TITLE font with RRDs::graph

Darren Murphy darren at victoriajd.com
Fri Aug 16 06:56:02 CEST 2013


Hi Steve,

Thanks for the advice.
I have RRDs version 1.4.007, and have confirmed this the only version
installed, and the correct path is included in @INC

# perl -MRRDs -le 'print $RRDs::VERSION'
1.4007

# find / -type f -name RRDs.pm
/usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi/RRDs.pm

# perl -le 'print join("\n", at INC)'
/usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.8
/usr/lib/perl5/site_perl
/usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.8
/usr/lib/perl5/vendor_perl
/usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi
/usr/lib/perl5/5.8.8

As mentioned in my original email, I have RRDTool 1.4.7, so it appears the
versions of both are correct.
I did try re-installing the perl-rrdtool (perl-rrdtool.x86_64
0:1.4.7-1.el5.rf) package, but this didn't help.

So now I'm stuck again - anything else you can suggest?

thanks again,
Darren



On 16 August 2013 05:40, Steve Shipway <s.shipway at auckland.ac.nz> wrote:

> This looks as if you have a different version of RRDs to your rrdtool
> executable version.****
>
> ** **
>
> Try this:****
>
> ** **
>
>                 rrdtool  -v****
>
> ** **
>
> This should give you the version of the RRDTool executable, and****
>
> ** **
>
>                 perl -MRRDs -e ‘print $RRDs::VERSION;’****
>
> ** **
>
> this should give you the version of your RRDs module.****
>
> ** **
>
> It sounds as if you have an older version of the RRDs libraries installed
> (possibly v1.2.x).  In this case, reinstall the updated version, or ensure
> your perl @INC path is pointing first to the newer one.****
>
> ** **
>
> Steve****
>
> ** **
> ------------------------------
>
> *Steve Shipway***
>
> ITS Unix Services Design Lead****
>
> University of Auckland, New Zealand****
>
> Floor 1, 58 Symonds Street, Auckland****
>
> *Phone: +64 (0)9 3737599 ext 86487*
>
> *DDI: +64 (0)9 923 6487*
>
> *Mobile: +64 (0)21 753 189*
>
> *Email: s.shipway at auckland.ac.nz*
>
> P Please consider the environment before printing this e-mail : 打印本
> 邮件,将减少一棵树存活的机会****
>
> ** **
>
> *From:* rrd-users-bounces+s.shipway=auckland.ac.nz at lists.oetiker.ch[mailto:
> rrd-users-bounces+s.shipway=auckland.ac.nz at lists.oetiker.ch] *On Behalf
> Of *Darren Murphy
> *Sent:* Friday, 16 August 2013 4:15 a.m.
> *To:* rrd-users at lists.oetiker.ch
> *Subject:* [rrd-users] Difficulty setting Graph TITLE font with
> RRDs::graph****
>
> ** **
>
> Hi list,
>
> I'm having difficulty setting a graph TITLE font size using the RRDTool
> Perl bindings (RRDs::graph).
>
> When used in a shell with `rrdtool graph`, both "-n TITLE:7:" and "--font
> TITLE:7:" work as expected and give the desired result.
> However, both options when passed to RRDs::graph produce an error.
>
> "-n TITLE:7:" results in: Error: RRDs::graph failed, invalid text property
> format
> "--font TITLE:7:" results in: Error: RRDs::graph failed, unknown option
> '--font TITLE:7:'
>
> A Google search for both errors hasn't turned up anything useful, the
> closest I got was a posting in the Cacti forums (
> http://forums.cacti.net/about28174.html) that suggested upgrading RRDTool.
>
> I am using RRDTool version 1.4.7 on CentOS 5.4
>
> For completeness, I have included below both a dump of the array passed to
> RRDs::graph which produces the failure, as well as the result of the same
> arguments passed to `rrdtool graph`
>
> Any advice much appreciated.
>
> Thanks in advance,
> Darren
>
> @graph_args = (
>
> '/home/mrtg/png/custom/brbraholid-usg-1_aux0-1376582178.png',
>                  '-s 1375134000',
>                  '-e 1375146000',
>                  '-u',
>                  5000000,
>                  '--font TITLE:7:',
>                  '-t "brbraholid-usg-1_aux0 - 2013-07-29 13:40:00 to
> 2013-07-29 17:00:00 BOT"',
>                  '--lazy',
>                  '-c',
>                  'FONT#000000',
>                  '-c',
>                  'MGRID#000000',
>                  '-c',
>                  'FRAME#000000',
>                  '-g',
>                  '-l',
>                  '0',
>                  '-c',
>                  'BACK#f5f5f5',
>                  '-c',
>                  'ARROW#000000',
>                  '-b',
>                  1000,
>                  '-w',
>                  400,
>                  '-h',
>                  100,
>
> 'DEF:in0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds0:AVERAGE',
>                  'CDEF:in=in0,8,*',
>
> 'DEF:maxin0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds0:MAX',
>                  'CDEF:maxin=maxin0,8,*',
>
> 'DEF:out0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds1:AVERAGE',
>                  'CDEF:out=out0,8,*',
>
> 'DEF:maxout0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds1:MAX',
>                  'CDEF:maxout=maxout0,8,*',
>                  '-v',
>                  'Bits per second',
>                  'AREA:in#00cc00:In',
>                  'LINE2:out#0000ff:Out',
>                  'PRINT:out:MAX:%.1lf',
>                  'PRINT:in:MAX:%.1lf',
>                  'PRINT:out:AVERAGE:%.1lf',
>                  'PRINT:in:AVERAGE:%.1lf',
>                  'PRINT:out:LAST:%.1lf',
>                  'PRINT:in:LAST:%.1lf',
>                  'HRULE:5000000#cc0000'
>                );
>
>
>
> # rrdtool graph /home/mrtg/png/custom/brbraholid-usg-1_aux0-1376582307.png
> "-s 1375134000" "-e 1375146000" -u 5000000 --font TITLE:7: -t
> "brbraholid-usg-1_aux0 - 2013-07-29 13:40:00 to 2013-07-29 17:00:00 BOT"
> --lazy -c FONT#000000 -c MGRID#000000 -c FRAME#000000 -g -l 0 -c
> BACK#f5f5f5 -c ARROW#000000 -b 1000 -w 400 -h 100
> DEF:in0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds0:AVERAGE
> CDEF:in=in0,8,*
> DEF:maxin0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds0:MAX
> CDEF:maxin=maxin0,8,*
> DEF:out0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds1:AVERAGE
> CDEF:out=out0,8,*
> DEF:maxout0=/home/mrtg/logs/brbraholid-usg-1_aux0.rrd:ds1:MAX
> CDEF:maxout=maxout0,8,* -v "Bits per second" AREA:in#00cc00:In
> LINE2:out#0000ff:Out PRINT:out:MAX:%.1lf PRINT:in:MAX:%.1lf
> PRINT:out:AVERAGE:%.1lf PRINT:in:AVERAGE:%.1lf PRINT:out:LAST:%.1lf
> PRINT:in:LAST:%.1lf HRULE:5000000#cc0000
> 497x152
> 1509394.8
> 4679144.1
> 870588.4
> 3460818.0
> 630603.4
> 3686902.0****
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/rrd-users/attachments/20130816/2a668e4b/attachment.htm 


More information about the rrd-users mailing list