Dependent libraries
Go 1.6
NodeJS v4+
Sqlite3
GO Environment Building
Vi/etc/profileexport gopath= "/root/go" Export goroot= "/usr/local/go" Export path= $GOROOT/bin: $PATHexport path=$ Gopath/bin: $PATH
NodeJS Environment Construction
Download node source package from https://nodejs.org/en/
CD/USR/LOCALTAR-ZXVF node-v4.5.0-linux-x64.tarchmod-r 755 Nodevi/etc/profileexport NODE=/usr/local/nodeexport PATH= ${node}/bin: $PATH
Prepare for compilation before installation
Create the $gopath/src/github.com/grafana/grafana directory, and then git the latest code into this directory.
mkdir $GOPATH/src/github.com/grafana/grafana
Compile back-end source code steps
CD $GOPATH/src/github.com/grafana/grafanago run Build.go setupgo run Build.go Build
Compile front-end source code steps
CD $GOPATH/src/github.com/grafana/grafananpm install--REGISTRY=HTTP://REGISTRY.NPM.TAOBAO.ORGNPM install-g GRUNT-CLI--registry=http://registry.npm.taobao.orggrunt
Run
./bin/grafana-server
Open Browser (default http://localhost:3000 anonymous login < Some features have permission restrictions >)
Open the login page (default http://localhost:3000/login username/password = admin/admin feature does not have permission restrictions).
Configuration
Startup item configuration
In the/etc/grafana/directory:
Grafana.inidev.ini (if found) Custom.ini
Basic Permissions Configuration
In/usr/share/grafana/conf
Defaults.ini 2.sample.ini
Program releases each platform installation package
The release installation package relies on the FPM tool.
# # #安装GEM
sudo apt-get install rubysudo apt-get Install Ruby-dev
# # #安装FPM
Gem Install FPM
Compiling the publication
The post-release installation package (. Tar. deb. rpm file) exists under the $gopath/src/github.com/grafana/grafana/dist directory, and some temporary files exist under the/tmp directory
Go Run Build.go Build Package
For open source project Grafana, I have completed the Chinese work on it, as follows:
Https://github.com/plusplusxu/grafana
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M02/8B/29/wKiom1hGD9_xOiK7AABcARdyon8621.png-wh_500x0-wm_3 -wmp_4-s_3323303321.png "style=" Float:none; "title=" Qq20161206090533.png "alt=" wkiom1hgd9_ Xoik7aabcardyon8621.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M02/8B/29/wKiom1hGD-CySrPsAACCcQU6Pqo400.png-wh_500x0-wm_3 -wmp_4-s_1256719199.png "style=" Float:none; "title=" Qq20161206090559.png "alt=" Wkiom1hgd-cysrpsaacccqu6pqo400.png-wh_50 "/>
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M02/8B/25/wKioL1hGD-OgCNc7AAEF-VLb6hE213.png-wh_500x0-wm_3 -wmp_4-s_683965068.png "style=" Float:none; "title=" Qq20161206090648.png "alt=" Wkiol1hgd-ogcnc7aaef-vlb6he213.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M02/8B/25/wKioL1hGD-SBgU9GAABdNErLeoY864.png-wh_500x0-wm_3 -wmp_4-s_154850516.png "style=" Float:none; "title=" Qq20161206090720.png "alt=" Wkiol1hgd-sbgu9gaabdnerleoy864.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M00/8B/29/wKiom1hGD-bBX4FnAACmSAPgyJ4267.png-wh_500x0-wm_3 -wmp_4-s_4125534431.png "style=" Float:none; "title=" Qq20161206090743.png "alt=" Wkiom1hgd-bbx4fnaacmsapgyj4267.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M00/8B/25/wKioL1hGD-ei-IrJAAB2Aiy3xi0380.png-wh_500x0-wm_3 -wmp_4-s_1307035722.png "style=" Float:none; "title=" Qq20161206090830.png "alt=" Wkiol1hgd-ei-irjaab2aiy3xi0380.png-wh_50 "/>
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M00/8B/29/wKiom1hGD-jxa6xeAACKkFpHuuA977.png-wh_500x0-wm_3 -wmp_4-s_3096039737.png "style=" Float:none; "title=" Qq20161206090900.png "alt=" Wkiom1hgd-jxa6xeaackkfphuua977.png-wh_50 "/>
650) this.width=650; "Src=" Http://s2.51cto.com/wyfs02/M01/8B/29/wKiom1hGEHPxu9AWAADcUi4x6po418.png-wh_500x0-wm_3 -wmp_4-s_3107506151.png "title=" Qq20161206091200.png "alt=" Wkiom1hgehpxu9awaadcui4x6po418.png-wh_50 "/>
This article from "Tcollaboration" blog, reproduced please contact the author!
Grafana Monitoring visual environment construction