Nagvis 1.8 add Aggragation

This forum was archived to /woltlab and is now in read-only mode. Please register a new account on our new community platform.

You can create a thread on the new site and link to an archived thread. This archive is available as knowledge base, safe and secured.

More details here.
  • In Nagvis 1.8 there is no aggregations to select when i add a icon or service.
    the aggregations are in check_mk.



    Can't find any errors in a logfile.


    anyone a idea?

  • Found the missing link, the backendtype mkbi.


    trying to figure out the settings of this new type.  :S 


    anyone a idea how to configure this backend, not added in the documentation of the 1.8

  • Guck mal in die englische Doku, da gibt es ein Kapitel zum mkbi-Backend, von dem ich hoffe, dass es zur Hilfe bei der Konfiguration ausreicht.

  • Danke fur die update im doku

    Guck mal in die englische Doku, da gibt es ein Kapitel zum mkbi-Backend, von dem ich hoffe, dass es zur Hilfe bei der Konfiguration ausreicht.

  • After adding the backend with the info out the Documentation, need to find the map layout for the map its expected "aggr_all_api"

  • Let me try to explain it a bit more, i think the nagvis part is now oke, and is the View missing in check_mk called aggr_all_api.


    After some goolge work i found a post that maybe explans the right view:

    Code
    1. +# Shows minimal information about a multiple aggregation+# Use together with output_format=python for API calls+'aggr_all_api': {'browser_reload': 0,+ 'column_headers': 'pergroup',+ 'datasource': 'bi_aggregations',+ 'description': _('List of all aggregations, containing the name of aggregations and state information'),+ 'group_painters': [],+ 'hard_filters': [],+ 'hard_filtervars': [],+ 'hidden': True,+ 'hide_filters': [],+ 'hidebutton': True,+ 'icon': 'aggr',+ 'layout': 'table',+ 'linktitle': 'All Aggregations',+ 'mobile': False,+ 'mustsearch': False,+ 'name': 'aggr_all_api',+ 'num_columns': 1,+ 'owner': 'omdadmin',+ 'painters': [('aggr_group', None, ''),+ ('aggr_name', None, ''),+ ('aggr_state_num', None, ''),+ ('aggr_output', None, ''),+ ('aggr_treestate', None, '')],+ 'play_sounds': False,+ 'public': True,+ 'show_checkboxes': None,+ 'show_filters': [],+ 'sorters': [],+ 'title': u'List of all Aggregations for simple API calls',+ 'topic': u'Business Intelligence',+ 'user_sortable': None},


    Is this the correct view?
    Thanks in advantage.



  • I replaced OMDs Nagvis with version 1.8.1 and added aggr_all_api. Now I get this errors:



    Any ideas?

  • How did you replace NagVis within OMD?

    I replaced /omd/versions/default/share/nagvis/htdocs with the new version. Just keep the old server/core/defines/global.php for handling "local" files...

  • What NagVis is doing there is to call this URL:


    [BASE_URL]view.py?view_name=aggr_all_api&output_format=json&_username=[USER}&_secret=[SECRET]


    Please replace the macros with the things you configured in your backend, then open the URL in your browser and paste the response here.

  • Hallo zusammen,


    ich versuche ebenfalls zurzeit die Aggregations in NagVis zu implementieren, aber leider werde ich auch aus der Doku nicht schlau.
    Ich habe versucht, das Backend mit dem type mkbi anzulegen, allerdings erscheint dann immer die Fehlermeldung
    "The required value "backendid" is not set", egal welche id ich verwende. Auch ist mir nicht klar, welche URL ich angeben muss.
    Also Aggregations in check_mk sind natürlich vorhanden, aber nicht unter Aggregations in NagVis aufgelistet.


    Es wäre super, wenn mir jemand einen Tipp geben könnte.


    Gruß
    Benni

  • What NagVis is doing there is to call this URL:


    [BASE_URL]view.py?view_name=aggr_all_api&output_format=json&_username=[USER}&_secret=[SECRET]


    Please replace the macros with the things you configured in your backend, then open the URL in your browser and paste the response here.

    Hi LaMi,


    I've the same problem : i'm using nagios+checkMK and i have configured a BI view into Nagios. I'd like to show this view using Nagvis 1.8.
    First, with some problem, i have added the new Backend (mkbi) but i have modified by hand (because using GUI always fail) the file nagvis.ini.php and below you can find (for your check) the BackEnd Section; then i have modified the file /usr/share/check_mk/web/plugins/views/builtin.py because was missing for code aggr_all_api. After restarting nagios, httpd i have tried to add the "aggregation" object to the map (regular map) without success but using your command above it seems that i was able to query nagios BI (attach), isn't it?
    Any help was aprreciated, thanks.
    Regards


    nagvis.ini.php - BackEnd Section



    ; ----------------------------
    ; Backend definitions
    ; ----------------------------


    ; Example definition of a livestatus backend.
    ; In this case the backend_id is live_1
    ; The path /usr/local/nagios/var/rw has to exist
    [backend_live_1]
    backendtype="mklivestatus"
    ; The status host can be used to prevent annoying timeouts when a backend is not
    ; reachable. This is only useful in multi backend setups.
    ;
    ; It works as follows: The assumption is that there is a "local" backend which
    ; monitors the host of the "remote" backend. When the remote backend host is
    ; reported as UP the backend is queried as normal.
    ; When the remote backend host is reported as "DOWN" or "UNREACHABLE" NagVis won't
    ; try to connect to the backend anymore until the backend host gets available again.
    ;
    ; The statushost needs to be given in the following format:
    ; ":" -> e.g. "live_2:nagios"
    ;statushost=""
    socket="unix:/var/log/nagios/rw/live"


    [backend_mkbi_1]
    backendtype="mkbi"
    base_url="http://10.1.2.134/check_mk/"
    auth_user="nagvis"
    auth_secret="DWSIGFXCRTJDXCOHOVFW"


    ; Example definition for a MySQL backend
    ; in this example the ID of the Backend is "ndomy_1" you can define another ID.
    [backend_ndomy_1]
    ; type of backend - MUST be set
    backendtype="ndomy"
    ; The status host can be used to prevent annoying timeouts when a backend is not
    ; reachable. This is only useful in multi backend setups.
    ;
    ; It works as follows: The assumption is that there is a "local" backend which
    ; monitors the host of the "remote" backend. When the remote backend host is
    ; reported as UP the backend is queried as normal.
    ; When the remote backend host is reported as "DOWN" or "UNREACHABLE" NagVis won't
    ; try to connect to the backend anymore until the backend host gets available again.
    ;
    ; The statushost needs to be given in the following format:
    ; ":" -> e.g. "live_2:nagios"
    ;statushost=""
    ; hostname for NDO-db
    ;dbhost="localhost"
    ; portname for NDO-db
    ;dbport=3306
    ; database name for NDO-db
    ;dbname="nagios"
    ; username for NDO-db
    ;dbuser="root"
    ; password for NDO-db
    ;dbpass=""
    ; prefix for tables in NDO-db
    ;dbprefix="nagios_"
    ; instance name for tables in NDO-db
    ;dbinstancename="default"
    ; maximum delay of the NDO Database in seconds
    ;maxtimewithoutupdate=180

  • Hi Benni,
    I've the same problem and, after trying many times, i have added the backend manually in the file nagvis.ini.php like below but, unfortunately, i'm not sure was corret because i was not able to add and aggragtion object



    [backend_mkbi_1]
    backendtype="mkbi"
    base_url="http://10.1.2.134/check_mk/"
    auth_user="nagvis"
    auth_secret="DWSIGFXCRTJDXCOHOVFW"


    Maybe LaMi can hel you.
    Regards
    David


  • The doku ist fine, but it is simply not working. There are no aggregations to choose.

    I can only say that with the nightly builds from OMD it is working (28.04.2015).


    With the nightly snapshot of 280415, I could at least create the backend. But still no aggregations.


    Any ideas?