<div dir="ltr">Hi Jeremy<div><br></div><div>Thanks for the prompt reply. Many of my doubts got cleared from what you have answered but I would be really pleased if u can provide little more information on the process of data collection by client. It is clear that xymonclient.sh collects the data and is than forwarded to the server. But my main query is how does this collects(xymonclient.sh) data. I have an understanding that message data is read from system logs or error logs, but what about the cpu, disk and other information.</div><div><br></div><div>Thanks and Regard</div><div>Sanjana</div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jan 28, 2015 at 8:44 AM, Jeremy Laidman <span dir="ltr"><<a href="mailto:jlaidman@rebel-it.com.au" target="_blank">jlaidman@rebel-it.com.au</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Sanjana<div><br></div><div>The apt-get tool is for Debian-based systems, including Ubuntu.  These use the "deb" packaging format, which is different from the "rpm" (Red Hat Package Manager) format that other systems (not just Red Hat) use.</div><div><br></div><div>You can list the files installed by a "deb" package using the "dpkg" tool.  So the following might list the files that were installed by apt-get for you:</div><div><br></div><div>  dpkg --listfiles xymon-client</div><div><br></div><div>I don't know the name of the package that you installed, but substitute as appropriate.  If you don't know the package name either, running "dpkg --list | grep xymon" might show you.</div><div><br></div><div>The client package typically creates a client directory structure with subdirectories called "bin", "etc", "ext", "tmp" and "log".  Some of these might be symbolic links to other directories.  You might find these all under /usr/lib/hobbit/client/.</div><div><br></div><div>The client package would also install a start-up or "init" script to start the "xymonlaunch" daemon at boot time.  In some releases of the package, the init script actually runs another script called runclient.sh, and this in turn runs xymonlaunch. Either way, the goal is to have xymonlaunch running in memory.  Once started, the xymonlaunch process runs everything else that's required to perform the Xymon agent tasks.</div><div><br></div><div>The xymonlaunch process looks at the clientlaunch.cfg file (probably in the "etc" subdirectory) and starts processes that are defined in that file.  The only thing that needs to run from clientlaunch.cfg is what is defined in the [client] section.  This section tells xymonlaunch to run the "xymonclient.sh" script every 5 minutes.</div><div><br></div><div>Assuming a default "central mode" installation, the xymonclient.sh script has two main tasks.  The first task is to collect local client data (CPU usage, disk usage, etc) for reporting to the Xymon server.  The second task is to fetch any (optional) configuration data from the Xymon server and store it in a temporary file.  The temporary file is used to collect additional client data to send to the Xymon server on the next run.</div><div><br></div><div>As mentioned, the client data collection is performed by the xymonclient.sh script.  One of the first things this script does it to work out the type of system on which it is running.  It then runs an OS-specific script as appropriate.  For example, on a Linux system, xymonclient.sh will run xymonclient-linux.sh.  The OS-specific script is where the majority all the data is actually collected.  It's all collated into a client message format and written out for xymonclient.sh to collect and report back to the Xymon server.</div><div><br></div><div>The client message is sent back to the Xymon server over a TCP connection on port 1984.  The Xymon server collects this message, parses the different sections for useful metrics, and uses the data to create status information and RRD files for graphing.  All of the status information is stored in html files on disk, so that a web server, such as Apache, can display it all.  Some information, such as the various graphs of performance metrics, is dynamic, and uses some CGI scripts to be called by the web server.</div><div><br></div><div>The Xymon server also runs a xymonlaunch process, and has a similar configuration file called tasks.cfg.  There's much more that goes on here, so there are many more processes started by the server from the tasks.cfg file.</div><div><br></div><div>The Xymon server's different components communicate with each other via various message formats.  I've mentioned a "client" message containing client data.  There are other messages also, such as "status" messages that some the Xymon server components can report "red" or "yellow" or "green" conditions.  Each message type has its own "channel" handler.  For example, a client message usually contains a [df] section with the output of the "df" command, and this includes disk usage figures.  The xymond process gives the message to the xymond_client process, which parses the [df] section for disk usage levels, and if a threshold is exceeded (90% by default) then xymond_client will send a "status" message over TCP port 1984 containing the alert colour ("yellow" for 90%) and other information.  The status message is then received by xymond which updates the "disk" status page for the server in question.  The xymond process also sends the status message to the xymond_rrd process so that it can add the disk usage percentages to an RRD file for graphing.</div><div><br></div><div>Xymon clients can also send message types other than "client" messages, and the most common one is the "status" message that I've already mentioned.  In fact, the forerunner to Xymon, called Big Brother, status messages almost exclusively, and the "client" message is a much more recent invention.</div><div><br></div><div>One of Xymon's awesome features is how extensible it is, and the "status" message is the classic way to extend Xymon's functionality.  The "ext" subdirectory on a client is usually where extension scripts are located (but they could be anywhere).  You can write a script to monitor anything you like, and report it to the Xymon server using a status message.  Such a script can be as simple as:</div><div><br></div><div>#!/bin/sh</div><div>RESULT=`sudo smartctl -H /dev/sda0 2>&1`</div><div>if echo "$RESULT" | grep "Status: OK"; then</div><div>    COL="green"</div><div>else</div><div>    COL="red"<br></div><div>fi</div><div>printf "status $MACHINE.smart $COL SMART status $COL\n$RESULT\n" | $XYMON $XYMSRV @</div><div><br></div><div>You simply arrange for the script to be run every 5 minutes as an "ext" script, and you'll end up with a new "smart" status page (and a corresponding green, yellow or red dot on the summary page) on your Xymon server web interface.</div><div><br></div><div>This is fairly simplistic overview, and there are many features I haven't mentioned, but I hope it answers some of your questions.  The official introduction to Xymon is here:<br></div><div><br></div><div><a href="http://xymon.sourceforge.net/xymon/help/manpages/man7/xymon.7.html" target="_blank">http://xymon.sourceforge.net/xymon/help/manpages/man7/xymon.7.html</a><br></div><div><br></div><div>Cheers</div><div>Jeremy</div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On 28 January 2015 at 00:09, Sanjana Ahlawat <span dir="ltr"><<a href="mailto:sanjana.ahlawat@gssltd.co.in" target="_blank">sanjana.ahlawat@gssltd.co.in</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr">Hi Team<div><br></div><div>I am new to xymon and trying to learn about it. But I am unable to figure out few questions.</div><div><br></div><div>1. I run xymon client installation by apt-get. but can you tell me what is actually running or getting installed in my system is it a rpm or what?</div><div>2. how my agent works. how does it gains information from the system it is running on.</div><div>3. what is the architecture of the xymon.</div><div><br></div><div>I would really appreciate your help. Please give me the insight of the tool. </div><span><font color="#888888"><div><div><br></div>-- <br><div><div dir="ltr">Thanks and Regards<br><span style="color:rgb(11,83,148)"><span style="color:rgb(61,133,198)"><b><i>Sanjana <br></i></b></span><br></span><br><br></div></div>
</div></font></span></div>
<br></div></div>_______________________________________________<br>
Xymon mailing list<br>
<a href="mailto:Xymon@xymon.com" target="_blank">Xymon@xymon.com</a><br>
<a href="http://lists.xymon.com/mailman/listinfo/xymon" target="_blank">http://lists.xymon.com/mailman/listinfo/xymon</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr">Thanks and Regards<br><span style="color:rgb(11,83,148)"><span style="color:rgb(61,133,198)"><b><i>Sanjana <br>Wily Admin Team,<br>Gateway Software Solutions Pvt. Ltd.<br>249(A) , 1st Floor<br>East of Kailash , Sant Nagar<br>New Delhi-110065, India..<br><a href="mailto:sanjana.ahlawat@gssltd.co.in" target="_blank">sanjana.ahlawat@gssltd.co.in</a></i></b></span><br></span><br><br></div></div>
</div>