Grafana 监控Linux CPU, Memoy, disk等资源-安装prometheus

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/powerccna/article/details/86440109

下载prometheus安装包

Grafana只是一个画图工具,其支持多种数据源,我们这次用的是prometheus数据,所以我们首先安装prometheus。
wget https://github.com/prometheus/prometheus/releases/download/v2.6.0/prometheus-2.6.0.linux-amd64.tar.gz

解压后,修改prometheus.yml 文件

启动

#!/usr/bin/bash

basepath=$(cd dirname $0; pwd)
nohup ./prometheus 2> $basepath/log/prome.log &

下载grafana

wget https://dl.grafana.com/oss/release/grafana-5.4.2.linux-amd64.tar.gz
tar -zxvf grafana-5.4.2.linux-amd64.tar.gz

创建grafana数据库

create database grafana DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;

启动grafana数据库

启动grafana
#./grafana_server

安装dashboard

https://grafana.com/dashboards

猜你喜欢

转载自blog.csdn.net/powerccna/article/details/86440109
今日推荐