Grafana安装和zabbix结合展示
1 环境安装
1.1 在线安装
1.2 离线安装
登陆地址 http://ip:3000
登录名密码都是admin
2 安装包详情
二进制文件 /usr/sbin/grafana-server
启动脚本 /etc/init.d/grafana-server
环境变量 /etc/sysconfig/grafana-server
配置文件 /etc/grafana/grafana.ini
systemd服务 grafana-server.service
日志 /var/log/grafana/grafana.log
sqlite3数据库 /var/lib/grafana/grafana.db
3 安装grafana-zabbix-app
enable zabbix
设置zabbix
查看测试模板
[url=][/url]
4 其他插件
在线安装
grafana-cli plugins list-remote
插件列表
id: abhisant-druid-datasource version: 0.0.2
id: alexanderzobnin-zabbix-app version: 3.2.0
id: belugacdn-app version: 1.2.0
id: bosun-app version: 0.0.25
id: bosun-datasource version: 0.0.5
id: briangann-datatable-panel version: 0.0.1
id: briangann-gauge-panel version: 0.0.2
id: btplc-alarm-box-panel version: 0.0.1
id: btplc-peak-report-panel version: 0.0.1
id: btplc-trend-box-panel version: 0.0.1
id: btplc-trend-dot-panel version: 0.0.1
id: crate-datasource version: 0.2.0
id: digiapulssi-breadcrumb-panel version: 1.0.0
id: fastweb-openfalcon-datasource version: 1.0.0
id: fetzerch-sunandmoon-datasource version: 0.1.2
id: foursquare-clouderamanager-datasource version: 0.9.2
id: grafana-belugacdn-app version: 1.1.0
id: grafana-clock-panel version: 0.0.8
id: grafana-example-app version: 1.0.1
id: grafana-influxdb-08-datasource version: 1.0.2
id: grafana-kairosdb-datasource version: 1.0.1
id: grafana-piechart-panel version: 1.1.4
id: grafana-simple-json-datasource version: 1.2.3
id: grafana-worldmap-panel version: 0.0.16
id: gridprotectionalliance-openhistorian-datasource version: 1.0.1
id: gridprotectionalliance-osisoftpi-datasource version: 1.0.0
id: hawkular-datasource version: 1.0.6
id: jdbranham-diagram-panel version: 1.4.0
id: kentik-app version: 1.1.0
id: monitoringartist-monitoringart-datasource version: 1.0.0
id: mtanda-heatmap-epoch-panel version: 0.1.7
id: mtanda-histogram-panel version: 0.1.6
id: neocat-cal-heatmap-panel version: 0.0.3
id: ns1-app version: 0.0.5
id: opennms-datasource version: 2.0.2
id: percona-percona-app version: 1.0.0
id: praj-ams-datasource version: 1.0.1
id: rackerlabs-blueflood-datasource version: 0.0.2
id: raintank-snap-app version: 0.0.4
id: raintank-worldping-app version: 1.2.0
id: ryantxu-ajax-panel version: 0.0.2
id: savantly-heatmap-panel version: 0.1.0
id: sileht-gnocchi-datasource version: 1.0.6
id: sraoss-sunburst-panel version: 1.0
id: stagemonitor-elasticsearch-app version: 0.26.0
id: udoprog-heroic-datasource version: 0.1.0
id: vonage-status-panel version: 1.0.0
id: voxter-app version: 0.0.1
插件安装
grafana-cli plugins install grafana-clock-panel
#钟表形展示
grafana-cli plugins install briangann-gauge-panel
#字符型展示
grafana-cli plugins install natel-discrete-panel
#服务器状态
grafana-cli plugins install vonage-status-panel
systemctl restart grafana-server
#安装的插件可以copy其他服务器对应目录
zabbix API 和grafana 结合
zabbixapi 获取主机数,模板数,监控项,主机组数,并在grafana上展示
1 部署
拷贝程序包到scripts目录下
修改 zabbix_agentd.win 去掉下面的#
重启zabbix-agentd
2 配置
修改config.ini
3 zabbix配置
导入模板work_monitor_details.xml
在zabbix服务器上附加模板
4 grafana配置
导入模板监控统计-1483371984794.json到grafana
代码链接
代码托管到:[ /bluetom520/ZABBIXAPI.git]bluetom520/ZABBIXAPI.git[/url]
原创: bluetom520