Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Icinga2 not get all the graphs from grafana , got only ping4 graph #197

Closed
sohail007 opened this issue Jan 16, 2019 · 8 comments
Closed

Comments

@sohail007
Copy link

Expected Behavior

Current Behavior

Possible Solution

Steps to Reproduce (for bugs)

Context

Your Environment

  • Icinga Web 2 Grafana version (System - About):
  • Icinga Web 2 version and modules (System - About):
  • Version used (icinga2 --version):
  • Operating System and version:
  • Enabled features (icinga2 feature list):
  • Config validation (icinga2 daemon -C):
@sohail007
Copy link
Author

Hi,

Kindly provide the solution issue, icinga2 not getting all the graphs from grafana

@Mikesch-mp
Copy link
Owner

Please post your config.ini & graphs.ini. Also what backend you use, which module version, grafana version .....

@mdazmir
Copy link

mdazmir commented Feb 10, 2019

I have similar issue. My "Icinga Web 2" is only showing "Host Alive" performance graph for all my added hosts and services.

"Host Alive" is the "Default panel id *: 1" in my Grafana (v5.4.3). I'm using "Icinga2 with InfluxDB" dashboard that I've imported from: https://grafana.com/dashboards/381


Below is my environment:

  • Icinga Web 2 Grafana version (System - About): 1.3.4
  • Icinga Web 2 version and modules (System - About): 2.6.2
  • Version used (icinga2 --version): r2.10.2-1
  • Operating System and version: CentOS Linux release 7.6.1810 (Core)
  • Enabled features (icinga2 feature list):
    api checker graphite ido-mysql influxdb mainlog notification perfdata
  • Config validation (icinga2 daemon -C):
[2019-02-11 01:45:49 +0800] information/cli: Icinga application loader (version: r2.10.2-1)
[2019-02-11 01:45:49 +0800] information/cli: Loading configuration file(s).
[2019-02-11 01:45:49 +0800] information/ConfigItem: Committing config item(s).
[2019-02-11 01:45:49 +0800] information/ApiListener: My API identity: synaps.asuscomm.com
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 11 Services.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 InfluxdbWriter.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 IcingaApplication.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 3 Hosts.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 FileLogger.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 NotificationComponent.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 ApiListener.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 GraphiteWriter.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 PerfdataWriter.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 CheckerComponent.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 4 Zones.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 2 Endpoints.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 2 ApiUsers.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 1 IdoMysqlConnection.
[2019-02-11 01:45:50 +0800] information/ConfigItem: Instantiated 215 CheckCommands.
[2019-02-11 01:45:50 +0800] information/ScriptGlobal: Dumping variables to file '/var/cache/icinga2/icinga2.vars'
[2019-02-11 01:45:50 +0800] information/cli: Finished validating the configuration file(s)

My /etc/icingaweb2/modules/grafana/graph.ini is empty and below are the contents of my /etc/icingaweb2/modules/grafana/config.ini:
> [grafana]
> version = "1"
> host = "192.168.0.233:3000"
> protocol = "http"
> timerangeAll = "24h"
> defaultdashboardpanelid = "1"
> defaultorgid = "1"
> shadows = "0"
> theme = "light"
> datasource = "influxdb"
> accessmode = "direct"
> debug = "0"
> defaultdashboard = "icinga2-with-influxdb"
> height = "280"
> width = "640"
> enableLink = "yes"
> usepublic = "no"
> defaultdashboarduid = "fhtfYhXik"
> directrefresh = "no"

@Mikesch-mp
Copy link
Owner

That dashboard is not made to use with the module. please use the provided default dashboard.

@mdazmir
Copy link

mdazmir commented Feb 13, 2019

The reason I imported the "Icinga2 with InfluxDB" dashboard was because I'm not able to follow the steps of "Import dashboards" within your Guide

The Grafana v5.4.3 that I'm using showed a different interface for importing dashboard. Refer to the screenshot

I hope you can assist me as I'm new to Icinga2 + InfluxDB + Grafana.

@Mikesch-mp
Copy link
Owner

I have to take some new screenshots, but technicaly the steps are the same, Import dashboard, point to the file or paste json, select data source.

@martinadolfi
Copy link

martinadolfi commented May 25, 2019

Had that same issue, it was all about setting up the right pannel and the right variables to make it show correctly. I agree that the default dashboard will get it working in most cases, without other interaction, but if you don't want the default dashboard, you should get the same results setting up the correct variables, pannelId, and org in the module configuration. (if you can't see it from the web interface, check config.ini).

For me the best way to diagnose it is to look at the url that the render is getting it's data from, so you can see for yourself where's the problem.

What I didn't get right away was the check_command part. Perhaps that part would need a little help from the code. I mean, InfluxWriter uses check_command as the name of the measurement. So you need that info passed to grafana if you want the graph to render correctly. I know you can do it setting up a new grafana graph in icingaweb2, but it seems a little to hard, giving that it's almost the default config as I see it, and maybe it would be better if it works right away. (also, maybe for another thread, not this one, but one service always has one and just one possible check, so I know why it's there, you need it, but there's no point in having a check_command selection on the grafana dashboard... but I couldn't figure out how to NOT use it, but i figured out how to make it not bother that much, setting the query in the variable to this so that when you select the service, it gets the right command right away> SHOW measurements where hostname =~ /^$hostname$/ and service =~ /^$service$/)

@martinadolfi
Copy link

Forget everything about the check_command part i've just metioned, I've just figured out that I didn't have the latest module version, I was using 1.1.7. Sorry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants