[op5-users] How to Geomap ?

Jean-Marc LE FEVRE eos at etatcritik.dyndns.org
Sat Nov 28 14:20:03 CET 2009


Well I was already trying to make a recipice to send to the list
As I did lots of modification, it is not easy.

Here is the draft 'im working on. Unfortunelty I'm not sure I an rerun  
the whole process during the week end to validate it.


OS Centos 5.3 + updates to 5.4

I've setup nagios 3.2.0 using daag repository (Release     : 1.el5.rf)
I've set up lilac to import an old nagios config and set up a new one.  
On this step the only difficulties was to chmod / chown /etc/nagios to  
write down new conf (and I don't use the feature of lilac that reload  
nagios on the web interface)
I've set up pnp4nagios last release :
PKG_REL_DATE="11-22-2009"
PKG_VERSION="0.6.1"
PKG_NAME="pnp4nagios"

This release need php 5.2+ so I've set up php 5.2.9 using Centos  
testing repos.
This lead to a seg fault, so I've seek the web and found php 5.3.1  
from remi repos. (release 1)
The binary release  from remi repository is not posix compilant, so  
I've download the srpms, change the ./configure line in the spec file,  
disable sqlite support as some dependencies were broken and rebuild an  
RPM.

then I've setup merlin in /usr/share/nagios/addons/merlin, and tested  
it with nagios.
then I've setup ninja in /usr/share/nagios/addons/ninja, and tested it.
I've symlinks merlin with /opt/monitor/op5/merlin
I've symlinks ninja with /opt/monitor/op5/ninja

For theses installations I've follwed the op5 wiki instructions.

Then I've grep'ed into the php source code for ereg and split  
functions (maybe a few more) as they are deprecated with php 5.3
ereg ('pattern',string) can be replace with preg_match('/ 
pattern/',string) and split('FS',string) with preg_split('/FS/',string)
I've corrected all the warning and the path issue I can find to make  
ninja/merlin/nagios work.

Here is the part that has to be tested :

I've download op5 monitor appliance, set up a vmware to use it (on  
this point some explaination about the ovf file on the op5 website  
could be nice for those who are not familliar with latest new from  
virtualisation world)
Then I get copy the nagvis folder to /usr/share/nagios/addons/nagvis/  
and symlinks /opt/monitor/op5/nagvis to it. I've also symlinks /var/ 
www/html/nagvis to nagvis installation, but I'm not sure it is really  
usefull

I've also took some httpd.conf line from the op5 vm and setup apache  
to use https, see below for apache configuration

About file permissions, I had to set manually the rights for the  
apache user on the nagvis/var and the nagvis/etc directories

Restarting all merlin, nagios, apache and tell your browser to trust  
the self-signed SSL certificate.

If I miss no steps, this should work. I don't mention crossdomain.xml  
as it seems not to be called anymore. There are also a lot of steps  
that may not be needed and may not be secure.
At last, this may not work completly as I didn't figure out yet how  
the location feature of the geomap work and it may be a bug somewhere.

If you have some space somewhere I can upload php 5.3.1 binaries rpm,  
and a tar with permissions protection of the /usr/share/nagios/  
directory




#################################################################################################
Here are the apache conf file :
#################################################################################################

nagios.conf :


<IfModule mod_rewrite.c>
     RewriteEngine On
         RewriteRule ^/(.*)$ https://%{SERVER_NAME}/$1 [R]
</IfModule>


ScriptAlias /nagios/cgi-bin "/usr/lib/nagios/cgi"

<Directory "/usr/lib/nagios/cgi">
#  SSLRequireSSL
    Options ExecCGI FollowSymLinks Indexes
    AllowOverride All
    Order allow,deny
    Allow from all
#  Order deny,allow
#  Deny from all
##  Allow from 127.0.0.1
    AuthName "Nagios Access"
    AuthType Basic
    AuthUserFile /etc/nagios/htpasswd.users
    Require valid-user
</Directory>

Alias /nagios "/usr/share/nagios"
Alias /ninja "/usr/share/nagios/addons/ninja"

<Directory "/usr/share/nagios">
#  SSLRequireSSL
    Options ExecCGI FollowSymLinks
    AllowOverride All
    Order allow,deny
    Allow from all
#  Order deny,allow
#  Deny from all
#  Allow from 127.0.0.1
    AuthName "Nagios Access"
    AuthType Basic
    AuthUserFile /etc/nagios/htpasswd.users
    Require valid-user
</Directory>

<Directory "/usr/share/nagios/addons/ninja">
#  SSLRequireSSL
    Options ExecCGI FollowSymLinks
    AllowOverride All
    Order allow,deny
    Allow from all
</Directory>

#######################################################################################################
Nagvis.conf
#######################################################################################################
<IfModule !mod_autoindex.c>
         LoadModule autoindex_module modules/mod_autoindex.so
</IfModule>
<IfModule !mod_alias.c>
         LoadModule alias_module modules/mod_alias.so
</IfModule>

<IfModule !mod_autoindex.c>
         LoadModule autoindex_module modules/mod_autoindex.so
</IfModule>

<IfModule mod_autoindex.c>
         <Directory "/var/www/html/monitor/images">
                 Options Indexes
                 AllowOverride None
                 order allow,deny
                 Allow from all
         </Directory>
</IfModule>



<IfModule !mod_cgi.c>
         LoadModule cgi_module modules/mod_cgi.so
</IfModule>

<IfModule !mod_auth_basic.c>
         LoadModule auth_module modules/mod_auth_basic.so
</IfModule>

#################################################################################################
pnp4nagios
#################################################################################################

Alias /pnp4nagios "/usr/share/nagios/addons/pnp4nagios/share"

<Directory "/usr/share/nagios/addons/pnp4nagios/share">
         AllowOverride None
         Order allow,deny
         Allow from all
         #
         # Use the same value as defined in nagios.conf
         #
         AuthName "Nagios Access"
         AuthType Basic
         AuthUserFile /etc/nagios/htpasswd.users
         Require valid-user
         <IfModule mod_rewrite.c>
                 # Turn on URL rewriting
                 RewriteEngine On
                 Options FollowSymLinks
                 # Installation directory
                 RewriteBase /pnp4nagios/
                 # Protect application and system files from being  
viewed
                 RewriteRule ^(application|modules|system) - [F,L]
                 # Allow any files or directories that exist to be  
displayed directly
                 RewriteCond %{REQUEST_FILENAME} !-f
                 RewriteCond %{REQUEST_FILENAME} !-d
                 # Rewrite all other URLs to index.php/URL
                 RewriteRule .* index.php/$0 [PT,L]
         </IfModule>
</Directory>
~




Le 28 nov. 09 à 13:45, Russell Jennings a écrit :

> What version of nagvis? 1.4 or 1.5?
> What permissions did you need to adjust?
> Please provide any info that may be helpful in other users who are  
> trying to get it up and running (such as myself!)
>
>
> On Nov 28, 2009, at 6:04 AM, Jean-Marc LE FEVRE wrote:
>
>>
>> Le 28 nov. 09 à 11:20, Russell Jennings a écrit :
>>
>>> Not at all what i'm asking.
>>>
>>> For me, I get "channel disconnected" which, i suspect is because my
>>> nagvis install isn't working (can't seem to get it to play with
>>> merlin). So, i imagine if i get that backend working, the frontend
>>> will fall in... but thats theory. I agree the geopmap widget is a  
>>> big
>>> sell for me as well.
>>>
>>>
>>
>> Sorry didn't understand ... English is not my mother language and  
>> now I wish at listen at school in english lesson :(
>> Nagvis is working correctly for the 1.4 branch. When I tested with  
>> 1.5 branch I had a doubt because of sqlite intégration.
>>
>>
>> I've checked futher for error with firebug and realize that in  
>> network performance I get error message 'from" the swf by studying  
>> the POST request / response. (please notice It doesn't appear in  
>> the console)
>> I had some certificates error , file disk permissions, some few bug  
>> due to php 5.3, but  now : I GET IT WORKING !!! using nagvis that  
>> was in op5 virtual appliance.
>> I've set up my google maps key and  now I can play with it.
>>
>>
>>
>> The only features that I didn't find how to use is the location  
>> feature. I've set up all fields, but i can't see how to save the  
>> datas
>> I understand that the link feature is depending of the location  
>> feature, and so I couldn't test it.
>>
>> About geomap for sure it is an important part of the solution. It  
>> is sexy, in fashion, could be usefull and save me lots of time  
>> because I don't need to create nagvis geographical maps by hand...
>>
>> Anyway, thank you all for time spending and for all theses advices  
>> you gave me !!!
>>
>>
>>
>>
>>> On Nov 28, 2009, at 5:16 AM, Jean-Marc LE FEVRE wrote:
>>>
>>>> I can use nagvis, but if I wanted nagvis without geomap, I wouldn't
>>>> even looked into ninja....
>>>>
>>>>
>>>> Le 28 nov. 09 à 11:13, Russell Jennings a écrit :
>>>>
>>>>> can you use nagvis, otherwise? or does it not work at all for you?
>>>>>
>>>>>
>>>>> On Nov 28, 2009, at 5:04 AM, Jean-Marc LE FEVRE wrote:
>>>>>
>>>>>> Le 27 nov. 09 à 13:47, Roman Kyrylych a écrit :
>>>>>>
>>>>>>> Jean-Marc LE FEVRE wrote:
>>>>>>>> Le 26 nov. 09 à 12:58, Roman Kyrylych a écrit :
>>>>>>>>> BTW where did you get Geomap?
>>>>>>>>
>>>>>>>> I didn't write down here I find all release I tested
>>>>>>>> (unfortunelty)
>>>>>>>> But I found all I get on sourceforge, op5 sites, and nagvis  
>>>>>>>> git.
>>>>>>>> All
>>>>>>>> version I used are public release.
>>>>>>>> The lastest 1.4 and 1.5 release of nagvis I tried came from
>>>>>>>> respectivly the nagvis nightly build version and  http://nagvis.git.sourceforge.net
>>>>>>>
>>>>>>> This is the root of all problems.
>>>>>>> There are lots of changes going on in NagVis now,
>>>>>>> so Geomap can be considered as broken until 1.5 final release.
>>>>>>>
>>>>>>> In fact, there is no Geomap in nagvis-1.4 branch at all:
>>>>>>> http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis;a=tree;h=refs/heads/nagvis-1.4;hb=refs/heads/nagvis-1.4
>>>>>>> It was removed long time ago:
>>>>>>> http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis;a=commitdiff;h=47772ae243e9c09f69eb735104543f3c956089c9
>>>>>>>
>>>>>>> Can you point me to NagVis release tarball that contains Geomap?
>>>>>>> You also mentioned op5 sites, can you point me to a place where
>>>>>>> NagVis
>>>>>>> is provided there. Same for NagVis 1.4 nightly builds.
>>>>>>>
>>>>>>
>>>>>> In my memory, I went on the nagvis official site and click on get
>>>>>> nightly buld.
>>>>>>
>>>>>>> It is just that Geomap is not supposed to be released until  
>>>>>>> NagVis
>>>>>>> 1.5,
>>>>>>> and until it will be released it is only available (in a working
>>>>>>> state)
>>>>>>> as experimental part of the latest op5 Monitor.
>>>>>>
>>>>>> Lots of version of nagvis have netmap and geomap in the archive.
>>>>>>
>>>>>>>
>>>>>>>>> And op5's nagvis repo is not available at http://git.op5.org/git/
>>>>>>>>> So I suppose you have installed monitor-nagvis package,
>>>>>>>>
>>>>>>>> Nop, what is it ?
>>>>>>>
>>>>>>> It's a package of a customized NagVis based on version 1.4.1
>>>>>>> with added integration with Ninja.
>>>>>>> It is avaliable as part of the latest release op5 Monitor,
>>>>>>> There is a tarball and a virtual appliance with a trial version
>>>>>>> on op5 website.
>>>>>>>
>>>>>>
>>>>>> I've tried the op5 virtual appliance, and geomap work on it.
>>>>>> I've seen no mention of monitor-nagvis thought.
>>>>>>
>>>>>> I made a copy of nagvis to my installation with no success.
>>>>>> I'll look deeper on this way as I don't ned op5 monitor, just  
>>>>>> ninja
>>>>>> and merlin.
>>>>>>
>>>>>>
>>>>>>
>>>>>>> -- 
>>>>>>> Roman Kyrylych
>>>>>>> Software engineer
>>>>>>> N-iX LLC
>>>>>>> Solutions for Your success
>>>>>>> http://www.n-ix.com
>>>>>>> _______________________________________________
>>>>>>> op5-users mailing list
>>>>>>> op5-users at lists.op5.com
>>>>>>> http://lists.op5.com/mailman/listinfo/op5-users
>>>>>>
>>>>>>
>>>>>>
>>>>>> _______________________________________________
>>>>>> op5-users mailing list
>>>>>> op5-users at lists.op5.com
>>>>>> http://lists.op5.com/mailman/listinfo/op5-users
>>>>>
>>>>> _______________________________________________
>>>>> op5-users mailing list
>>>>> op5-users at lists.op5.com
>>>>> http://lists.op5.com/mailman/listinfo/op5-users
>>>>
>>>> _______________________________________________
>>>> op5-users mailing list
>>>> op5-users at lists.op5.com
>>>> http://lists.op5.com/mailman/listinfo/op5-users
>>>
>>> _______________________________________________
>>> op5-users mailing list
>>> op5-users at lists.op5.com
>>> http://lists.op5.com/mailman/listinfo/op5-users
>>
>> _______________________________________________
>> op5-users mailing list
>> op5-users at lists.op5.com
>> http://lists.op5.com/mailman/listinfo/op5-users
>
> _______________________________________________
> op5-users mailing list
> op5-users at lists.op5.com
> http://lists.op5.com/mailman/listinfo/op5-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.op5.com/pipermail/op5-users/attachments/20091128/8c7564a3/attachment-0001.html 


More information about the op5-users mailing list