1.下載grafana安裝包(linux版)到 /opt/minitor/grafana 。java
下載地址:https://download.csdn.net/download/a15565772151/11111935linux
能夠私聊我一下我發你資源vim
2.運行 tar -zxvf grafana-5.3.4.linux-amd64.tar.gz ,解壓文件到當前目錄。服務器
3.進入 /opt/minitor/grafana/grafana-5.3.4/bin目錄,執行一下命令啓動grafana:spa
1
2
3
|
systemctl start grafana-server : 啓動grafana
systemctl stop grafana-server : 中止grafana
systemctl restart grafana-server : 重啓grafana
|
4.grafana默認端口號爲3000,默認的用戶名密碼爲admin/admin.net
5.登陸成功後,設置數據源rest
幾個重要的參數:code
1
2
3
4
|
Name : 能夠自定義
Type : 選Prometheus
URL : prometheus所在服務器ip地址+端口號
HTTP Method : GET
|
1
2
3
4
5
6
7
8
9
10
|
#################################### Anonymous Auth ##########################
[auth.anonymous]
# enable anonymous access
;enabled =
false
# specify organization name that should be used
for
anonymous users
;org_name = Main Org.
# Specify role
for
anonymous users. Defaults to Viewer, other valid options are Editor and Admin
;org_role = Viewer
|