<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Creating a fake, or combination, client</TITLE>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.3157" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2>Hi Martin,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2>I do a similar thing with our Citrix servers, where I have 
a "Farm" host to hold a summary of the total number of connections across all 
servers.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2>I do this by running a script from hobbitlaunch on the 
server, and summing up the results of the individual Citrix servers using 
hobbitdboard.  After parsing the results, I send a single message for the 
"Farm" host in the same format as the individual host messages and Hobbit 
magically makes the graph for me :-)</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2>It's not too flash, but here are all the bits and pieces 
which make it work.  I hope they may help you in making a similar script 
for a postfix farm.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2><STRONG>BB-HOSTS ENTRIES :</STRONG></FONT></SPAN></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff 
  size=2>127.0.0.1       citrix-farm    
  # COMMENT:"Farm Totals" testip noconn noinfo notrends</FONT></SPAN></DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>192.168.1.101   
  citrix-01      # <BR>192.168.1.102   
  citrix-02      # </FONT></SPAN></DIV></BLOCKQUOTE>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2><STRONG>SHELL SCRIPT</STRONG> 
/opt/hobbit/bin/citrix-totals.sh :</FONT></SPAN></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>#!/bin/sh</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>TFIL=/tmp/`basename 
  $0`.$$</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>/opt/hobbit/server/bin/bb localhost 
  "hobbitdboard host=citrix-[0-9][0-9] test=citrix fields=msg" | gsed 
  's/\\n/\n/g' > ${TFIL}</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>LINE=`grep -v 'users active' 
  ${TFIL}`</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>CSUM=`grep "users active" ${TFIL} | 
  awk ' { sum += $1; } END { print sum; } '`</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>if [ -z "${CSUM}" 
  ]<BR>then<BR>        
  CSUM=0<BR>fi</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>/opt/hobbit/server/bin/bb localhost 
  "status citrix-farm.citrix green `date`</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff size=2>${CSUM} users 
  active</FONT></SPAN></DIV>
  <DIV><FONT face="Courier New" color=#0000ff size=2></FONT> </DIV><SPAN 
  class=927402620-06112007>
  <DIV dir=ltr align=left><FONT color=#0000ff size=2></FONT><FONT color=#0000ff 
  size=2></FONT><BR><FONT face=Tahoma color=#0000ff size=2>${LINE}"</FONT></DIV>
  <DIV><FONT face=Tahoma color=#0000ff size=2></FONT> </DIV>
  <DIV dir=ltr align=left><FONT face=Tahoma color=#0000ff size=2>rm 
  ${TFIL}</FONT></DIV></BLOCKQUOTE>
<DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT face=Tahoma 
color=#0000ff size=2><STRONG>HOBBITLAUNCH.CFG 
ENTRY:</STRONG></FONT></SPAN></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV dir=ltr align=left><SPAN class=927402620-06112007><FONT 
  face="Courier New" color=#0000ff 
  size=2>[citrix-totals]<BR>        ENVFILE 
  /opt/hobbit/server/etc/hobbitserver.cfg<BR>        
  NEEDS hobbitd<BR>        CMD 
  /opt/hobbit/bin/citrix-totals.sh<BR>        
  LOGFILE 
  $BBSERVERLOGS/logs/citrix-totals.log<BR>        
  INTERVAL 5m</FONT></SPAN></DIV></BLOCKQUOTE>
<DIV><FONT face=Tahoma color=#0000ff size=2></FONT></SPAN><SPAN 
class=927402620-06112007><FONT face=Tahoma color=#0000ff 
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=927402620-06112007><FONT face=Tahoma color=#0000ff size=2>The 
paths for the binaries etc would obviously need massaging to suit your 
installation.  Good luck!</FONT></SPAN></DIV>
<DIV><SPAN class=927402620-06112007><FONT face=Tahoma color=#0000ff 
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=927402620-06112007><FONT face=Tahoma color=#0000ff 
size=2>Andy.</FONT></SPAN></DIV>
<DIV><FONT face=Tahoma color=#0000ff size=2></FONT><FONT face=Tahoma 
color=#0000ff size=2></FONT><BR></DIV>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> Ward, Martin [mailto:Martin.Ward@colt.net] 
<BR><B>Sent:</B> Wednesday, 7 November 2007 1:11 a.m.<BR><B>To:</B> 
hobbit@hswn.dk<BR><B>Subject:</B> [hobbit] Creating a fake, or combination, 
client<BR></FONT><BR></DIV>
<DIV></DIV><!-- Converted from text/rtf format -->
<P><FONT face=Arial size=2>Hi all,</FONT> </P>
<P><FONT face=Arial size=2>I am a newbie to Hobbit and have inherited a working 
system. I have a good idea of how it all hangs together but now I want to 
produce certain graphs and cannot figure out how.</FONT></P>
<P><FONT face=Arial size=2>I have a cluster of mail servers that run Postfix; 
each of these clients is monitored within Hobbit. In the Trends link for each 
client I have graphs showing the various mail queues (incoming, deferred etc) 
and this data is stored in RRD files on the Hobbit server.</FONT></P>
<P><FONT face=Arial size=2>Is there a way within Hobbit of creating a false or 
meta- client that can have a graph with data from all of these RRD files? 
Particularly I would like a graph that has all the incoming mail queue sizes on 
it with one line per server. I already have this information in lots of 
different RRD files but would like to have them all in one graph. I can create a 
graph outside of Hobbit to do this, but within the monitoring system it 
restricts the RRD files it will display data from to those in the data directory 
of the selected client (in the Trends link).</FONT></P>
<P><FONT face=Arial size=2>I have tried creating a new client in the data files 
ans symbolically linking the other RRD files into its data directory, but cannot 
persude the graphs to appear in the trends web page.</FONT></P>
<P><FONT face=Arial size=2>Thanks for your time,</FONT> </P>
<P><FONT face=Arial size=2>|\/|artin</FONT> <BR><FONT face=Arial 
size=2>----</FONT> <BR><FONT face=Arial size=2>NetOps TAC</FONT> <BR><FONT 
face=Arial size=2>T:+44 20 7863 5218</FONT> <BR><FONT face=Arial 
size=2>Group:</FONT> <FONT face=Arial size=2>+49 69 56607 0412</FONT> <BR><FONT 
face=Arial size=2>F: +44 20 7863 5210</FONT> </P>
<P>#####################################################################################</P>
<P>This email is intended for the person to whom it is addressed<BR>only. If you 
are not the intended recipient, do not read, copy<BR>or use the contents in any 
way. The opinions expressed may not<BR>necessarily reflect those of ZESPRI Group 
of Companies ('ZESPRI').</P>
<P>While every effort has been made to verify the information<BR>contained 
herein, ZESPRI does not make any representations <BR>as to the accuracy of the 
information or to the performance<BR>of any data, information or the products 
mentioned herein.<BR>ZESPRI will not accept liability for any losses, damage 
or<BR>consequence, however, resulting directly or indirectly from<BR>the use of 
this 
e-mail/attachments.<BR>#####################################################################################</P>
</BODY></HTML>