Generic server monitoring with Monitis & M3

Had I been told to monitor a cat chasing a mouse with Monitis, my answer would have been – “Yes, it’s probably possible”.
With the not-so-recent addition of M3 to the arsenal of monitoring tools Monitis can utilize, it is possible to monitor anything. However this alone is far from being enough. Smart implementations of proper applicative monitoring is what should be practiced.
Unleashing the power of M3 & timers

During the lifespan of M3 (Monitis Monitor Manager) there has always been something lacking – timers.
M3 execution procedure was outlined in this previous article.
The execution mentioned in the latter was a one-time-execution, whereas server monitoring requires periodic invocation of monitors in order to actually provide counters over time, graphing performance.
The periodic invocation method suggested up until today was to integrate M3 with crontab.
Crontab, in a nutshell, is a Linux/Unix service for periodic invocation of executables. Implementing M3 with crontab properly meant M3 would run every X minutes, producing a Monitis counter update every X minutes, should everything run properly.
In the following article I’ll outline the changes done to support timers in M3.

Pluggable M3 (Monitis Monitor Manager) Framework
Who needs an introduction about M3? – Perhaps no one!
After gaining some reputation with M3, providing extra-easy integration of any monitor into Monitis it was time to take it to the next level.
Generally speaking, the work flow of M3 was described in detail in this article.
After some thought and design, we’ve decided it’d be best if M3 was pluggable. Pluggable in terms of being able to easily add execution and parsing plugins.
The interface and behavior of M3 stayed exactly the same, however now it is much easier to obtain data from any source and parse the data the way you want it.
Saying that, it was time to put the new design for a test. We tried to integrate the DBI support into M3.
Guess what – it was much easier than expected!
In previous articles we introduced the command-line utility “Monitis-Top”, written in VBScript. Monitis Top is a tool that can be used to query your active monitors from the command-line. We promised that we would provide the code of this client utility in C# in addition to the VBScript source, and here it is. The code utilizes Microsoft .NET Framework 4.0, so that is a requirement if you want to use this software or want to make modifications.
We’ll go over the source code below. The complete source code – including the Visual Studio 2010 solution – can be downloaded from Monitis’ Github open source repository.
So far we’ve added support for Internal and External Monitors in Monitis-Top. Now let’s add functionality to support querying the FullPage Monitors. We also made some changes to optimize the source code and utilize the available “topResult” functions in the Monitis API. In our initial article we showed how to use the API functions that deal specifically with Internal and External monitors. If you missed our first Monitis-Top article, you can view it here.
In this article we’ll discuss creating a command line interface to query the Monitis Agents and Monitors you have activated for your systems. We’ll provide the source code for the utility in VBScript and we will also be working on a C# version. We’ll keep things simple for now and start with VBScript and provide a link to the complete source at the end of this article.
To get started we need to identify what information we want to display from our Monitors, what can be easily supported, and what is not supported. The main parts are the different types of agents that Monitis offers, which are the Internal,
External, and custom monitors.
In this article we’ll focus on the basic ‘framework’ of the utility that deals with the definition of some classes to make working with the various agents and monitors easier, accepting and processing command-line arguments, and a small function library to keep our main script very clean. We’ll introduce a neat little feature of VBScript showing you how to work with include files.
Posted by Wawrzyniec | Posted in Sysadmin Tools | Posted on 12-09-2011
In the third part of our closer encounter with the find command [(for previous posts, see Part I and Part II] we are going to look into searching for files based on their size, type, owner and permission in accessing/using them.
Posted by Hovhannes Avoyan | Posted in Sysadmin Tools | Posted on 05-08-2011
Sometimes it’s tough to make choices.
Take, the Unix command-line tool, for example. Everybody has a favorite, and it’s not easy to choose the most valuable. However, “find” would be a strong contender in such a decision. It is probably one of the first commands you learn to use as a Linux/Unix sysadmin, but it has so many options that you might still learn about — even if you’re an old pro at using Linux (or any other Unix-flavored OS).
In this post, Monitis will show you some of the more interesting options of using “Find.” It’s all part of our continuing effort to help make your life as a sysadmin easier, less taxing and richer in experience.