grafana / grafana-zabbix

Zabbix plugin for Grafana dashboard
http://play.grafana-zabbix.org
Apache License 2.0
2.06k stars 458 forks source link

Problems with Zabbix Plugin in grafana 7 #1045

Closed lgaravatti closed 3 years ago

lgaravatti commented 4 years ago

Hi @alexanderzobnin !

I have one problem with zabbix plugin in grafana 7.

I installed the plugin of manually in the /var/lib/grafana/plugin and I tryed to add New Datasource but this not appear and I receive this message in grafana.log:

Could not find plugin definition for data source: alexanderzobnin-zabbix-datasource

lgaravatti commented 4 years ago

And other thing...

I'm not got to install the plugin with the command:

grafana-cli plugins install alexanderzobnin-zabbix-app

I receive this error:

installing alexanderzobnin-zabbix-app @ 4.0.1 from: https://grafana.com/api/plugins/alexanderzobnin-zabbix-app/versions/4.0.1/download into: /var/lib/grafana/plugins

Error: ✗ failed to download plugin archive: Failed to send request: Get "https://github-production-release-asset-2e65be.s3.amazonaws.com/35092819/5b649200-ed47-11ea-8e0f-b50ca38e9194?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20200903%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20200903T184550Z&X-Amz-Expires=300&X-Amz-Signature=9cff6d16be72898dcda58a6b1f089a56d0bb450c3333fa4d04dd6c1edd371b7f&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=35092819&response-content-disposition=attachment%3B%20filename%3Dalexanderzobnin-zabbix-app-4.0.1.zip&response-content-type=application%2Foctet-stream": net/http: TLS handshake timeout

I tested it with another plugin and it worked

Regards Mrs

rburkhall commented 4 years ago

Restart the grafana service or server. I was having the same issue.

  1. Remove from plugin folder
  2. Re-install via cli
  3. Restart service after installation
  4. Remove from panel affected
  5. Add to same or new panel
lgaravatti commented 4 years ago

Hi Robert I tryed this but not working!

fauust commented 4 years ago

Hi, same problem here (docker-compose instance). Re-creating the docker container and reinstalling the plugin does not work.

Here is the log:

❯ dc up grafana
zabbix_zabbix-server_1 is up-to-date
Starting zabbix_grafana_1 ... done
Attaching to zabbix_grafana_1
grafana_1        | installing alexanderzobnin-zabbix-app @ 4.0.1
grafana_1        | from: https://grafana.com/api/plugins/alexanderzobnin-zabbix-app/versions/4.0.1/download
grafana_1        | into: /var/lib/grafana/plugins
grafana_1        |
grafana_1        | ✔ Installed alexanderzobnin-zabbix-app successfully
grafana_1        |
grafana_1        | Restart grafana after installing plugins . <service grafana-server restart>
grafana_1        |
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Starting Grafana" logger=server version=7.1.5 commit=9893b8c53d branch=HEAD compiled=2020-08-25T08:27:17+0000
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Config loaded from" logger=settings file=/usr/share/grafana/conf/defaults.ini
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Config loaded from" logger=settings file=/etc/grafana/grafana.ini
....
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Path Home" logger=settings path=/usr/share/grafana
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Path Data" logger=settings path=/var/lib/grafana
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Path Logs" logger=settings path=/var/log/grafana
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Path Plugins" logger=settings path=/var/lib/grafana/plugins
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Path Provisioning" logger=settings path=/etc/grafana/provisioning
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="App mode production" logger=settings
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Connecting to DB" logger=sqlstore dbtype=mysql
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Starting DB migration" logger=migrator
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Starting plugin search" logger=plugins
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Registering plugin" logger=plugins name="Direct Input"
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=eror msg="Failed to load plugin" logger=plugins error="plugin \"alexanderzobnin-zabbix-datasource\" is unsigned" pluginPath=/var/lib/grafana/plugins/alexanderzobnin-zabbix-app/datasource-zabbix
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Registering plugin" logger=plugins name="Zabbix Problems"
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=info msg="Registering plugin" logger=plugins name=Zabbix
grafana_1        | t=2020-09-07T09:27:29+0000 lvl=warn msg="Some plugins failed to load" logger=plugins errors="[plugin \"alexanderzobnin-zabbix-datasource\" is unsigned]"
fauust commented 4 years ago

A workaround is to install the 3.12.4 version.

EvertonSSJ4 commented 4 years ago

How can i install (tutorial) manually an older version of zabbix plugin? With the automatically method I'm having the same problems.

fauust commented 4 years ago

How can i install (tutorial) manually an older version of zabbix plugin? With the automatically method I'm having the same problems.

https://grafana.com/docs/grafana/latest/administration/cli/#plugins-commands

So in the case of zabbix plugin, something like:

grafana-cli plugins remove alexanderzobnin-zabbix-app
grafana-cli plugins install alexanderzobnin-zabbix-app 3.12.4
EvertonSSJ4 commented 4 years ago

How can i install (tutorial) manually an older version of zabbix plugin? With the automatically method I'm having the same problems.

https://grafana.com/docs/grafana/latest/administration/cli/#plugins-commands

So in the case of zabbix plugin, something like:

grafana-cli plugins remove alexanderzobnin-zabbix-app
grafana-cli plugins install alexanderzobnin-zabbix-app 3.12.4

Thank's for your help.

lgaravatti commented 4 years ago

How can i install (tutorial) manually an older version of zabbix plugin? With the automatically method I'm having the same problems.

https://grafana.com/docs/grafana/latest/administration/cli/#plugins-commands

So in the case of zabbix plugin, something like:

grafana-cli plugins remove alexanderzobnin-zabbix-app
grafana-cli plugins install alexanderzobnin-zabbix-app 3.12.4

Thank's Everton!!! Worked

lgaravatti commented 4 years ago

Worked for the insert Zabbix information, but when I click in Save Test I receive this Message:

Could not connect to given url

rburkhall commented 4 years ago

Tried to downgrade to day and it didn’t seem to work.

From: lgaravatti notifications@github.com Reply-To: alexanderzobnin/grafana-zabbix reply@reply.github.com Date: Tuesday, September 8, 2020 at 1:41 PM To: alexanderzobnin/grafana-zabbix grafana-zabbix@noreply.github.com Cc: "Burkhall, Robert" Robert.Burkhall@turner.com, Comment comment@noreply.github.com Subject: Re: [alexanderzobnin/grafana-zabbix] Problems with Zabbix Plugin in grafana 7 (#1045)

How can i install (tutorial) manually an older version of zabbix plugin? With the automatically method I'm having the same problems.

https://grafana.com/docs/grafana/latest/administration/cli/#plugins-commandshttps://urldefense.proofpoint.com/v2/url?u=https-3A__grafana.com_docs_grafana_latest_administration_cli_-23plugins-2Dcommands&d=DwMCaQ&c=tq9bLrSQ8zIr87VusnUS9yAL0Jw_xnDiPuZjNR4EDIQ&r=XLWsyl0KUlcSPrZHys-rJBkdRMN4yLtTdE5dprnzD40&m=2TRo52KeI7eJxKzX5UOluXMiP35IZ8RGjYePr9P1mj0&s=0ywryW1SsdwN95ZZV75vf2ONezdCgeTJY6TK8S-3euo&e=

So in the case of zabbix plugin, something like:

grafana-cli plugins remove alexanderzobnin-zabbix-app

grafana-cli plugins install alexanderzobnin-zabbix-app 3.12.4

Thank's Everton!!! Worked

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_alexanderzobnin_grafana-2Dzabbix_issues_1045-23issuecomment-2D689033026&d=DwMCaQ&c=tq9bLrSQ8zIr87VusnUS9yAL0Jw_xnDiPuZjNR4EDIQ&r=XLWsyl0KUlcSPrZHys-rJBkdRMN4yLtTdE5dprnzD40&m=2TRo52KeI7eJxKzX5UOluXMiP35IZ8RGjYePr9P1mj0&s=lk-o5uDxrV9_E0RX8PbpAdvoHv3CHQnv3qmjCKMgbeE&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AKGK44UEX7HKOGDBV3GQVDLSEZUCXANCNFSM4QVNCZEQ&d=DwMCaQ&c=tq9bLrSQ8zIr87VusnUS9yAL0Jw_xnDiPuZjNR4EDIQ&r=XLWsyl0KUlcSPrZHys-rJBkdRMN4yLtTdE5dprnzD40&m=2TRo52KeI7eJxKzX5UOluXMiP35IZ8RGjYePr9P1mj0&s=BmoNZrLr7L2QAo42C-y_A01I9HVrMPn5fpdRm2BJCVw&e=.

EvertonSSJ4 commented 4 years ago

How can i install (tutorial) manually an older version of zabbix plugin? With the automatically method I'm having the same problems.

https://grafana.com/docs/grafana/latest/administration/cli/#plugins-commands So in the case of zabbix plugin, something like:

grafana-cli plugins remove alexanderzobnin-zabbix-app
grafana-cli plugins install alexanderzobnin-zabbix-app 3.12.4

Thank's Everton!!! Worked

@fauust is who deserves the merits, he helped us. Now i hope Alexsander can see this and correct the problem in the new version of plugin Zabbix.

alexanderzobnin commented 4 years ago

Hi! Can anyone confirm the problem still exists? Does it fail for 4.0.0 version? Let me explain a bit the grafana-cli installation process:

  1. You run grafana-cli plugins install alexanderzobnin-zabbix-app.
  2. grafana-cli asks grafana.com for the latest plugin version. It's 4.0.1 for instance.
  3. Then grafana-cli gets information about this version and where to get plugin package. It's like https://github.com/grafana/grafana-plugin-repository/blob/5bfc45469420f9840b0b1b0e47e714865ab52dc2/repo.json#L368-L376:
          "version": "4.0.1",
          "url": "https://github.com/alexanderzobnin/grafana-zabbix",
          "commit": "95aee8f0488eb87b0c061f234f815e0e11f6f129",
          "download": {
            "any": {
              "url": "https://github.com/alexanderzobnin/grafana-zabbix/releases/download/v4.0.1/alexanderzobnin-zabbix-app-4.0.1.zip",
              "md5": "24f92c7c4ee898a0bdaedc9a17718e0a"
            }
          }
  4. grafana-cli gets download URL and tries to fetch package.

So in this case download url is https://github.com/alexanderzobnin/grafana-zabbix/releases/download/v4.0.1/alexanderzobnin-zabbix-app-4.0.1.zip. Problem can be in github/AWS access troubles. Try to download package manually with curl/wget from the same host where you run grafana-cli command to make sure it's accessible.

fauust commented 4 years ago

Hi, I can confirm that the problem is still there. See logs from https://github.com/alexanderzobnin/grafana-zabbix/issues/1045#issuecomment-688195672

And I am pretty sure that I am downloading the right 4.0.1 version:

faust@hz-monit:~$ wget https://github.com/alexanderzobnin/grafana-zabbix/releases/download/v4.0.1/alexanderzobnin-zabbix-app-4.0.1.zip
--2020-09-14 12:17:07--  https://github.com/alexanderzobnin/grafana-zabbix/releases/download/v4.0.1/alexanderzobnin-zabbix-app-4.0.1.zip
Resolving github.com (github.com)... 140.82.121.4
Connecting to github.com (github.com)|140.82.121.4|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://github-production-release-asset-2e65be.s3.amazonaws.com/35092819/5b649200-ed47-11ea-8e0f-b50ca38e9194?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20200914%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20200914T101610Z&X-Amz-Expires=300&X-Amz-Signature=4a0286ba20afddabd9bd880a67fb6d8be46893810f7865b2de0de2b10f619437&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=35092819&response-content-disposition=attachment%3B%20filename%3Dalexanderzobnin-zabbix-app-4.0.1.zip&response-content-type=application%2Foctet-stream [following]
--2020-09-14 12:17:07--  https://github-production-release-asset-2e65be.s3.amazonaws.com/35092819/5b649200-ed47-11ea-8e0f-b50ca38e9194?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20200914%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20200914T101610Z&X-Amz-Expires=300&X-Amz-Signature=4a0286ba20afddabd9bd880a67fb6d8be46893810f7865b2de0de2b10f619437&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=35092819&response-content-disposition=attachment%3B%20filename%3Dalexanderzobnin-zabbix-app-4.0.1.zip&response-content-type=application%2Foctet-stream
Resolving github-production-release-asset-2e65be.s3.amazonaws.com (github-production-release-asset-2e65be.s3.amazonaws.com)... 52.216.110.99
Connecting to github-production-release-asset-2e65be.s3.amazonaws.com (github-production-release-asset-2e65be.s3.amazonaws.com)|52.216.110.99|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 16584375 (16M) [application/octet-stream]
Saving to: ‘alexanderzobnin-zabbix-app-4.0.1.zip’

alexanderzobnin-zabbix-app 100%[======================================>]  15.82M  12.5MB/s    in 1.3s

2020-09-14 12:17:08 (12.5 MB/s) - ‘alexanderzobnin-zabbix-app-4.0.1.zip’ saved [16584375/16584375]

faust@hz-monit:~$ md5sum alexanderzobnin-zabbix-app-4.0.1.zip
24f92c7c4ee898a0bdaedc9a17718e0a  alexanderzobnin-zabbix-app-4.0.1.zip
fauust commented 4 years ago

Here are some screenshots:

fauust commented 4 years ago

Trying to recreate the datasource, I can't see the 4.0.1 zabbix plugin version. screenshot_20200914_123305

@alexanderzobnin If you need any debug or test from me, let me know.

jurim76 commented 4 years ago

Same issue for me.

Unable to access Zabbix datasource settings or create a new Zabbix datasource after plugin upgrade to 4.0.1 version via "grafana-cli plugins upgrade alexanderzobnin-zabbix-app" Grafana version 7.1.5

UPD. Fixed by adding "allow_loading_unsigned_plugins = alexanderzobnin-zabbix-datasource"

ricamz commented 4 years ago

Same issue here .. Zabbix plugin 4.0.1 and grafana 7.1.5. CentOS No zabbix datasource.

ricamz commented 4 years ago

I solved the issue by allowing unsigned plugins in grafana.ini. It is now working.

Although it shows as signed in the plugins section, somehow it is not signed for the datasources. I don't have the needed knowledge to know why.

komkomissarov commented 3 years ago

Приветствую. Проблема актуальна. Плагин прекрасно работал на версии Grafana 6.6.2 Решил обновится до последней (7.2.0), плагин встает без проблем, версией 4.0.1, но создать datasource нет возможности, Zabbix просто отсутствует в списке. Предложенное решение установить старую версию 3.12.4 помогло и работает.

jurim76 commented 3 years ago

Приветствую. Проблема актуальна. Плагин прекрасно работал на версии Grafana 6.6.2 Решил обновится до последней (7.2.0), плагин встает без проблем, версией 4.0.1, но создать datasource нет возможности, Zabbix просто отсутствует в списке. Предложенное решение установить старую версию 3.12.4 помогло и работает.

Нужно добавит в grafana.ini [plugins] allow_loading_unsigned_plugins = alexanderzobnin-zabbix-datasource

komkomissarov commented 3 years ago

Благодарю, @jurim76. Помогло.

fauust commented 3 years ago

Hi! Thanks @jurim76 (спасибо)!

Workaround for docker users:

GF_INSTALL_PLUGINS=alexanderzobnin-zabbix-app
GF_PLUGINS_ALLOW_LOADING_UNSIGNED_PLUGINS=alexanderzobnin-zabbix-datasource

See: https://grafana.com/docs/grafana/latest/administration/configuration/#configure-with-environment-variables

chevvi commented 3 years ago

Обновил графану до 7.2.0, установил заббикс плагин версии 4.0.1 (разрешил не подписанные). В списках плагинов (cli) плагин вижу, источники даннных вижу. Графики основанные на заббиксе вроде тоже вижу. Не работает дашборд с заббикс алертами в дашке и логах докер-контейнера (графана в докере) ошибка t=2020-09-29T11:35:34+0000 lvl=eror msg="Zabbix API request error" logger=plugins.backend pluginId=alexanderzobnin-zabbix-datasource error="Invalid params. Incorrect API \"problem\"." В датасурс при тестировании всё ок, отдает что заббикс агент 2.4.8 (Заббикс да, такой старый, переезд планируется, но графану бы хотелось обновить раньше)

Что посоветуете? Это новая версия 4.0.1 не поддерживает старый заббикс? Попробовал подсунуть старый (3.12) версии плагин, почемуто он не видися в списке совсем и соответственно не работает.

Добавлено: Судя по чейндж логу новые плагины (от 3.12 и выше) не поддерживают старые заббиксы, конкретно наш 2.4.8 Сейчас, обновив графану до 7.2.0, имея заббикс 2.4.8 и плагин версии 3.10.5 (который работал в графане 6 с тем же заббиксом, а именно позволял отобразить проблемы) не работет.

skander12 commented 3 years ago

hi alexander zobnin i cant add zabbix to data source when i try to save and test after all instuction i have error like this Connection failed: <!DOCTYPE html> Grafana

<div class="preloaderenter">
Loading Grafana

If you're seeing this Grafana has failed to load its application files

1. This could be caused by your reverse proxy settings.

2. If you host grafana under subpath make sure your grafana.ini root_url setting includes subpath. If not using a reverse proxy make sure to set serve_from_sub_path to true.

3. If you have a local dev build make sure you build frontend using: yarn start, yarn start:hot, or yarn build

4. Sometimes restarting grafana-server can help

Save & TestDeleteBack Documentation Support Community Open Source v7.2.2 (ad9d408ac2)

jonathanspw commented 3 years ago
[plugins]
allow_loading_unsigned_plugins = alexanderzobnin-zabbix-datasource

in the Grafana config file also fixes it for me.

alexanderzobnin commented 3 years ago

Closing this since plugin is signed and problem with signed apps fixed in Grafana.