1.环境准备。
redis和mysql是必备的,nginx最后做反向代理用。
yum install -y redis mysql-server nginx
chkconfig redis on
chkconfig mysqld on
chkconfig nginx on
service redis start
service mysqld start
service nginx start
2.数据库初始化和数据导入
cd /tmp/ && git clone https://github.com/open-falcon/falcon-plus.git
cd /tmp/falcon-plus/scripts/mysql/db_schema/
mysql -h 127.0.0.1 -u root -p < 1_uic-db-schema.sql
mysql -h 127.0.0.1 -u root -p < 2_portal-db-schema.sql
mysql -h 127.0.0.1 -u root -p < 3_dashboard-db-schema.sql
mysql -h 127.0.0.1 -u root -p < 4_graph-db-schema.sql
mysql -h 127.0.0.1 -u root -p < 5_alarms-db-schema.sql
如果从v1升级到当前版本v2,那么只需要执行如下命令:
mysql -h 127.0.0.1 -u root -p < 5_alarms-db-schema.sql
3.准备go语言环境,因为我是源码编译安装的,go版本必须是1.6以上,不然编译的时候回提示缺少包什么的。
wget https://www.golangtc.com/static/go/1.9.2/go1.9.2.linux-amd64.tar.gz
tar xvf https://www.go