运维监控系统OpenFalcon部署
【环境准备】
Centos6.5
安装golang运行环境
https://my.oschina.net/guiguketang/blog/4270638
安装mysql
#yum install mysql-server
安装redis
https://my.oschina.net/guiguketang/blog/3043486
初始化基础数据
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
rm -rf /tmp/falcon-plus/
环境准备完毕!!!!
【单机安装后端】
step1:创建目录
export FALCON_HOME=/home/work
export WORKSPACE=$FALCON_HOME/open-falcon
mkdir -p $WORKSPACE
step2:下载二进制包
step3:解压
step4:修改DB配置文件(如果使用的已经存在的DB,此步尤为重要)
默认配置是DB无密码
step5:启动
./open-falcon start
检查模块启动情况
./open-falcon check
The end,后端部署
【单机安装前端】
step1:创建目录
export HOME=/home/work
export WORKSPACE=$HOME/open-falcon
mkdir -p $WORKSPACE
cd $WORKSPACE
step2:下载开源代码
cd $WORKSPACE
git clone https://github.com/open-falcon/dashboard.git
step3:安装依赖
#yum install -y python-virtualenv
#yum install -y python-devel
#yum install -y openldap-devel
#yum install -y mysql-devel
#yum groupinstall "Development tools"
#cd $WORKSPACE/dashboard/
#virtualenv ./env
#./env/bin/pip install -r pip_requirements.txt -i https://pypi.douban.com/simple
某些python版本可能会存在问题,可以选择通过沙盒方式运行
step4:修改配置文件
dashboard的配置文件为: "rrd/config.py",请根据实际情况修改
## API_ADDR 表示后端api组件的地址
API_ADDR = "http://127.0.0.1:8080/api/v1"
## 根据实际情况,修改PORTAL_DB_*, 默认用户名为root,默认密码为""
## 根据实际情况,修改ALARM_DB_*, 默认用户名为root,默认密码为""
step5:启动
#./env/bin/python wsgi.py
或
#bash control start
#bash control stop //停止
#bash control tail //查看日志
step6:浏览器访问
http://ip:8081/
直接注册创建管理员账户
The end,前端部署
【参考文献】
https://github.com/open-falcon/falcon-plus
https://github.com/open-falcon/dashboard
https://book.open-falcon.org/
以上是 运维监控系统OpenFalcon部署 的全部内容, 来源链接: utcz.com/z/516342.html