<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html xmlns="http://www.w3.org/TR/REC-html40" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:p="urn:schemas-microsoft-com:office:powerpoint" xmlns:a="urn:schemas-microsoft-com:office:access" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema" xmlns:b="urn:schemas-microsoft-com:office:publisher" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:odc="urn:schemas-microsoft-com:office:odc" xmlns:oa="urn:schemas-microsoft-com:office:activation" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:q="http://schemas.xmlsoap.org/soap/envelope/" xmlns:rtc="http://microsoft.com/officenet/conferencing" XMLNS:D="DAV:" XMLNS:Repl="http://schemas.microsoft.com/repl/" xmlns:mt="http://schemas.microsoft.com/sharepoint/soap/meetings/" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ppda="http://www.passport.com/NameSpace.xsd" xmlns:ois="http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc="http://schemas.microsoft.com/data/udc" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sub="http://schemas.microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:ec="http://www.w3.org/2001/04/xmlenc#" xmlns:sp="http://schemas.microsoft.com/sharepoint/" xmlns:sps="http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:udcs="http://schemas.microsoft.com/data/udc/soap" xmlns:udcxf="http://schemas.microsoft.com/data/udc/xmlfile" xmlns:udcp2p="http://schemas.microsoft.com/data/udc/parttopart" xmlns:wf="http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:dsss="http://schemas.microsoft.com/office/2006/digsig-setup" xmlns:dssi="http://schemas.microsoft.com/office/2006/digsig" xmlns:mdssi="http://schemas.openxmlformats.org/package/2006/digital-signature" xmlns:mver="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mrels="http://schemas.openxmlformats.org/package/2006/relationships" xmlns:spwp="http://microsoft.com/sharepoint/webpartpages" xmlns:ex12t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:ex12m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:pptsl="http://schemas.microsoft.com/sharepoint/soap/SlideLibrary/" xmlns:spsl="http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService" XMLNS:Z="urn:schemas-microsoft-com:" xmlns:st="">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="GENERATOR" content="MSHTML 8.00.6001.18975">
<style>@font-face {
        font-family: Calibri;
}
@page Section1 {size: 612.0pt 792.0pt; margin: 70.85pt 70.85pt 70.85pt 70.85pt; }
P.MsoNormal {
        MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Calibri","sans-serif"; FONT-SIZE: 11pt
}
LI.MsoNormal {
        MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Calibri","sans-serif"; FONT-SIZE: 11pt
}
DIV.MsoNormal {
        MARGIN: 0cm 0cm 0pt; FONT-FAMILY: "Calibri","sans-serif"; FONT-SIZE: 11pt
}
A:link {
        COLOR: blue; TEXT-DECORATION: underline; mso-style-priority: 99
}
SPAN.MsoHyperlink {
        COLOR: blue; TEXT-DECORATION: underline; mso-style-priority: 99
}
A:visited {
        COLOR: purple; TEXT-DECORATION: underline; mso-style-priority: 99
}
SPAN.MsoHyperlinkFollowed {
        COLOR: purple; TEXT-DECORATION: underline; mso-style-priority: 99
}
SPAN.EmailStyle17 {
        FONT-FAMILY: "Calibri","sans-serif"; COLOR: windowtext; mso-style-type: personal-compose
}
.MsoChpDefault {
        mso-style-type: export-only
}
DIV.Section1 {
        page: Section1
}
</style><!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>
<body lang="FR" link="blue" vlink="purple">
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">Thomas,</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">Here is what I'm doing to sum data from multiply rrd's and display on one graph "all data combined and sum'd in one line". I have not done this with bandwidth
 data but its the same basic thing. Its really easy to do. The trick is knowing that the graph will show up under the trends column and you must create a blank rrd file that matches your graph definition.</span></font><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">First use the rrdtool command to find out what your DS values are. In my example I'm using lambda. In your bandwidth rrd you will have 2 ds's one for in
 bits and one for out bits.</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">cd to your $xymon_home/data/rrd/host1</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"> </span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">rrdtool dump your.rrd|more</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">My example:</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">rrdtool dump msu,grp.rrd |more<br>
</div>
</span></font>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"><!-- Round Robin Database Dump --><rrd> <version> 0003 </version><br>
        <step> 300 </step> <!-- Seconds --><br>
        <lastupdate> 1292424133 </lastupdate> <!-- 2010-12-15 09:42:13 EST --></span></font></div>
<div><font color="#0000ff" size="2" face="Arial"></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">        <ds><br>
                <name> lambda </name><br>
                <type> GAUGE </type><br>
                <minimal_heartbeat> 600 </minimal_heartbeat><br>
                <min> NaN </min><br>
                <max> NaN </max></span></font></div>
<div><font color="#0000ff" size="2" face="Arial"></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">                <!-- PDP Status --><br>
                <last_ds> 317 </last_ds><br>
                <value> 4.2161000000e+04 </value><br>
                <unknown_sec> 0 </unknown_sec><br>
        </ds></span></font></div>
<div><font color="#0000ff" size="2" face="Arial"></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">Based on the above data you are ready to build your graph definition in $xymon_home/server/etc/hobbitgraph.cfg. Since you will be looking at bandwidth in
 your CDEF you may want to add some more math "8,*" to get the right numbers. You could even add another CDEF line like CDEF:avg_total2=avg_total,8,* just to keep it simple</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">[combined]<br>
        TITLE Combined Example</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">        -h 140<br>
        -w 592<br>
        YAXIS <br>
        DEF:cf1_avg_sum=/home/xymon/data/rrd/host1/msu,avg.rrd:lambda:AVERAGE<br>
        DEF:cf2_avg_sum=/home/xymon/data/rrd/host2/msu,avg.rrd:lambda:AVERAGE<br>
        DEF:cf3_avg_sum=/home/xymon/data/rrd/host2/msu,avg.rrd:lambda:AVERAGE<br>
        CDEF:avg_total=cf1_avg_sum,cf2_avg_sum,+,cf3_avg_sum,+<br>
        AREA:avg_total#aaaaaa:Combined Example<br>
        COMMENT:\n<br>
        GPRINT:avg_total:LAST:AVG \: %5.1lf%s (cur)<br>
        GPRINT:avg_total:MAX: \: %5.1lf%s (max)<br>
        GPRINT:avg_total:MIN: \: %5.1lf%s (min)<br>
        GPRINT:avg_total:AVERAGE: \: %5.1lf%s (avg)</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">Now edit $xymon_home/server/etc/hobbitserver.cfg look for "</span></font><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">GRAPHS=" "this is the one
 to have it show up on the trends column" add your graph definition name to the end of this line. in this example you would add ",combined""</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">The last step the "Trick" is to create a blank "dummy" rrd file that matches your graph definition under what ever host/device you want this data to show up under. So in this
 case if I wanted to see this graph under host1 I would do the following:</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">cd $xymon_home/data/rrd/host1</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">"Create a dummy rrd file"</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">touch combined.rrd</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">Now you should see a new "combined graph" under the trends column of host1.
</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">Troubleshooting is simple...</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">1.) When you look under the trends column and see a red X not graphing data then your graph definition is wrong go back and fix this in hobbitgraph,cfg</span></font></div>
<div><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010">2.) If you see no red X and no graph at all you didn't add the graph definition name to the hobbitserver.cfg or you didn't add the dummy rrd file to $zymon_home/data/rrd/$host.
 Check spelling and case.</div>
<div><br>
        </div>
</span></font>
<div dir="ltr" align="left"><font color="#0000ff" size="2" face="Arial"><span class="477343313-15122010"></span></font> </div>
<font color="#0000ff" size="2" face="Arial"></font><font color="#0000ff" size="2" face="Arial"></font><font color="#0000ff" size="2" face="Arial"></font><br>
<div dir="ltr" lang="en-us" class="OutlookMessageHeader" align="left">
<hr tabindex="-1">
<font size="2" face="Tahoma"><b>From:</b> SEGLARD, Thomas [mailto:tseglard@wat.tv]
<br>
<b>Sent:</b> Tuesday, December 14, 2010 8:58 AM<br>
<b>To:</b> xymon@xymon.com<br>
<b>Subject:</b> [xymon] graph a sum from different graphs<br>
</font><br>
</div>
<div></div>
<div class="Section1">
<p class="MsoNormal">Hello,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I’m sorry for asking you this question again but I really can’t figure how to graph a sum of values coming from other graphes. Basically I want to make a graph of the total bandwidth consumed by a pool of servers. For this I would like
 to use the values coming from the ifstat graph of each server. What will be the best solution ?<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">As I said I asked this question before and got answer from two people but I was not able to have the proposed solution working. So if you have other ideas you’re very welcome !<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I thank you very much for your answers.<o:p></o:p></p>
<p class="MsoNormal">Sincerly,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">ThomaS<o:p></o:p></p>
</div>
</body>
</html>