My impression about Merlin and Ninja

Andreas Ericsson ae at op5.se
Wed Aug 5 12:29:48 CEST 2009


Johannes Dagemark wrote:
> Hi Mathieu and everyone else interested
> 
> Mathieu Gagné wrote:
>> Hi all,
>>
>> Some of us are under the impression that Merlin and Ninja will be the 
>> new default GUI and NEB module used in Nagios.
>>
>> I therefore gave a try to both of them this week and I would like to 
>> share my impression and opinion about those.
>>   
> Very nice :)
> 
> After working with Ninja and Merlin for most of this year I have to say 
> I'm really happy to see that people are interested and actually succeed 
> to get as far as "working" installations at this early stage.
> 

Agreed. :-)


>> 1.3) Configuration propagation
>>
>> - How is it propagated? Do I have to rsync them? Is it propagated or 
>> just imported to the database for status aggregation purpose?
>>   
> It's not propagated at all so yes you have to rsync them. It would 
> though be very nice if this were handled by Merlin in some nice way, I 
> know I for one would like that.

It's supposed to be handled by Merlin, and there's even room in the
protocol for it. The import-program needs to be taught how to read a
valid configuration and dole out a partial one from it before that
can happen though.

>> 1.4) Nagios instance
>>
>> Was the NDOutils concept of "nagios instance" dropped? I can see this in 
>> object_importer.inc.php:
>>
>> $obj['instance_id'] = 0;
>> $obj['instance_name'] = 'Local Nagios/Merlin instance';
>>
>>   
> yes, for now at least. If it makes sense in the future we might 
> reintroduce it.

The instance_id field is supposed to provide a map to which merlin nodes
are connected, as well as being used to determine which particular node
performed a check. This is not yet completed as we've focused primarily
on getting the single-server case to work nicely first (it was necessary
to get Ninja to move forward in the fast pace it has been the past four
months).

>> 3) Using PHP for shell scripts
>>
>> I used to program PHP for several years in the past. PHP is nice and 
>> easy to learn. However having to install PHP on a monitoring server just 
>> so a single shell script can import a Nagios configuration isn't really 
>> cool. I would prefer Perl or Python which are usually already installed 
>> on the server.
>>   
> The story behind this was that we had this code in php already and 
> wanted to get the import program to work fast so that we could start 
> testing with some real data. I agree that it's not sane to use php for 
> the reasons you describe. We might change this in the future but it's 
> not top priority. A patch for this would be very welcome.

The patch should, for preference, implement the config parser in C, or
create configuration objects from the running Nagios and send via the
ipc socket to the merlin daemon. Sadly though, that means having to add
quite a lot of code to the merlin module. Primarily a lot of strings,
which will get copied each time Nagios forks.

For the time being, the config importer will remain written in PHP
unfortunately.

>> And now with Ninja.
>>
>> 1.1. I installed a MySQL server on a remote host. I can't specify a host 
>> on which I want to configure the database. I had to execute each part of 
>> the installation process separately.
>>
>> 1.2. Error reporting isn't user friendly. I was prompted with this error 
>> during the installation process:
>>
>> sh: -c: line 0: syntax error near unexpected token `newline'
>> sh: -c: line 0: `/usr/bin/php /usr/local/ninja/index.php 
>> cli/insert_user_data <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 
>> Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> '
>>
>> An error occurred and this script will terminate. Too bad...
>>
>> It is in fact the first line of a huge backtrace from Kohana telling it 
>> can't connect to MySQL.
>>   

Ninja is currently shipped with debug output from Kohana enabled.

>> 2) Interface
>>
>> 2.1) At first glance, the interface is nice. The dashboard and the use 
>> of widgets is a good idea.
>>   
> thanks
>> However the interface is very pale and seriously lacking colors/contrast.
>>
>> Your answer would be: "Ninja supports themes so improve it yourself". 
>> While it's a valid answer, it certainly won't satisfy anybody as it 
>> requires time and expertise which most of us don't have. And I would 
>> personally consider this answer as a loophole so you don't have to 
>> review/change the theme to answer most people concerns and needs.
>>
>> To justify my opinion, let me give you an example. With the current CGI 
>> interface, when a server is marked as DOWN, we get a WHOLE red line to 
>> draw our attention. This is great because I know in seconds where to 
>> look and what is asking my attention.
>>
>> However, with Ninja, we only get a 16x16 icon which doesn't draw any 
>> attention. It's even worst when you are showing the interface on a big 
>> screen in a NOC. Small icons simply don't do the job compared to an 
>> awesome huge red line.
>>
>> IMO, state should use background colors instead of icons and commands 
>> should use icons. (pretty much like Nagios does today)
>>
>>   
> Well, I myself is a bit conflicted here. My first reaction was the same 
> as yours but after a time I have gotten used to the new look and feel. 
> Some parts I like better with the old gui but most parts I like better 
> with the new gui. I was hoping for people to give feedback like you are 
> doing now and it will be very interesting to hear what other people 
> think also.
> 
> The best would be to have a couple of skins available, like "The good 
> old days", "Ninja style", "High contrast", etc...

I think we will create more skins as time moves on, but creating those
skins is, right now, quite a low priority since it's one of the easier
tasks new participants can join in on, (reading up on Kohana docs a bit
will be necessary though). We also have other more pressing tasks to
take care of before we get this far.

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july




More information about the Developers mailing list