1.环境安装
本文采取rpm安装方式,大家也可以用源码包安装。
wget http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm rpm -ivh epel-release-6-8.noarch.rpm yum repolist yum install -y golang gcc* gcc-c++*
安装redis
yum install -y redis
安装mysql
yum install -y mysql-server mysql-devel
创建工作目录
export HOME=/home/work export WORKSPACE=$HOME/open-falcon mkdir -p $WORKSPACE cd $WORKSPACE
初始化mysql表结构
# open-falcon所有组件都无需root账号启动,推荐使用普通账号安装,提升安全性。此处我们使用普通账号:work来安装部署所有组件
# 当然了,使用yum安装依赖的一些lib库的时候还是要有root权限的。
#我用的是root账号
git clone https://github.com/open-falcon/scripts.git cd ./scripts/ mysql -h localhost -u root --password="" < db_schema/graph-db-schema.sql mysql -h localhost -u root --password="" < db_schema/dashboard-db-schema.sql mysql -h localhost -u root --password="" < db_schema/portal-db-schema.sql mysql -h localhost -u root --password="" < db_schema/links-db-schema.sql mysql -h localhost -u root --password="" < db_schema/uic-db-schema.sql
下载编译好的组件
wget https://github.com/open-falcon/of-release/releases/download/v0.1.0/open-falcon-v0.1.0.tar.gz
tar -zxf of-release-v0.1.0.tar.gz -C ./tmp/ for x in `find ./tmp/ -name "*.tar.gz"`;do app=`echo $x|cut -d ‘-‘ -f2`; mkdir -p $app; tar -zxf $x -C $app; done
到此基础环境和程序包就准备完毕了。
时间: 2024-11-05 11:40:09