[Solved] Incorrect CDEF

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
gordon1023
Posts: 6
Joined: Thu Oct 02, 2008 10:13 pm

[Solved] Incorrect CDEF

Post by gordon1023 »

How to modify incorrect CDEFs in graph template?

Dear All

I want to monitor file system utilization, the php script has been invoked by "script server" of cacti 0.8.7b version, but the utilization always 100%, I did graph debug, and found there is something wrong with CDEFs. would you please instruct me to correct it in cacti? For details, please refer to following statements & pictures. thanks so much for your help, I am beginner at cacti.

Following is detail template information:

Data Query : SNMP - Get Mounted Partitions
Data Template : Host MIB - Hard Drive Space
Graph Template : ucd 90 Filesystems

This is output of RRD Graph Debug Mode:


/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-60 \
--title="test_srv - Used Space - /" \
--rigid \
--base=1024 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="bytes" \
--slope-mode \
--font TITLE:10: \
--font AXIS:8: \
--font LEGEND:8: \
--font UNIT:8: \
DEF:a="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_total:AVERAGE \
DEF:b="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_total:LAST \
DEF:c="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_total:MIN \
DEF:d="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_total:MAX \
DEF:e="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_used:AVERAGE \
DEF:f="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_used:LAST \
DEF:g="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_used:MIN \
DEF:h="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_used:MAX \
DEF:i="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_percent:LAST \
DEF:j="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_percent:MIN \
DEF:ba="/var/www/html/rra/test_srv_hdd_total_41.rrd":hdd_percent:MAX \
CDEF:cdefj=b,a,/,100,* \
CDEF:cdefba=b,a,/,100,* \
####these CDEFs are not correct, would you please let me know how to change them?####
AREA:a#002A97FF:"Total" \
GPRINT:b:LAST:"Current\:%8.2lf %s" \
GPRINT:a:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:d:MAX:"Maximum\:%8.2lf %s\n" \
AREA:e#F51D30FF:"Used" \
GPRINT:f:LAST:" Current\:%8.2lf %s" \
GPRINT:e:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:h:MAX:"Maximum\:%8.2lf %s\n" \
COMMENT:"% Used" \
GPRINT:cdefj:LAST:"Current\:%8.2lf %%" \
GPRINT:cdefba:AVERAGE:"Average\:%8.2lf %%" \
GPRINT:cdefba:MAX:"Maximum\:%8.2lf %%\n" \
COMMENT:"\n" \
COMMENT:"Last Updated \: Thu 02 Oct 22\:43\:06 CDT 2008"
Last edited by gordon1023 on Thu Oct 02, 2008 11:59 pm, edited 4 times in total.
gordon1023
Posts: 6
Joined: Thu Oct 02, 2008 10:13 pm

Post by gordon1023 »

I think the correct CDEFs should like this:

CDEF:cdefj=f,b,/,100,* \
CDEF:cdefba=e,a,/,100,* \
CDEF:cdefbb=h,d,/,100,* \
gordon1023
Posts: 6
Joined: Thu Oct 02, 2008 10:13 pm

Post by gordon1023 »

incorrect Graph Item Fields for "Percent Disk Space Data Source"
Attachments
incorrect Graph Item Fields for "Percent Disk Space Data Source"
incorrect Graph Item Fields for "Percent Disk Space Data Source"
1.JPG (60.81 KiB) Viewed 2025 times
gordon1023
Posts: 6
Joined: Thu Oct 02, 2008 10:13 pm

Post by gordon1023 »

Incorrect utilization 100%
Attachments
[b]Incorrect utilization 100%[/b]
[b]Incorrect utilization 100%[/b]
2.JPG (30.97 KiB) Viewed 2022 times
gordon1023
Posts: 6
Joined: Thu Oct 02, 2008 10:13 pm

Post by gordon1023 »

Resolution: Modify Graph Item in the graph template "ucd 90 Filesystem"

Focus on fields below:
Consolidation Function,
CDEF Function,
GPRINT Type
gordon1023
Posts: 6
Joined: Thu Oct 02, 2008 10:13 pm

Post by gordon1023 »

Please refer to the correct utilization
Attachments
Correct utilization
Correct utilization
3.JPG (32.44 KiB) Viewed 2012 times
Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests