二、安装准备
系统环境:CentOS-7.1
yum -y update
yum -y install wget telnet git net-tools deltarpm epel-release
sed -i "s/SELINUX=enforcing/SELINUX=disabled/g" /etc/selinux/config
setenforce 0
systemctl stop firewalld
systemctl disable firewalld
#安装一些系统常用软件,可免去一些麻烦
yum -y install gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel zip unzip ncurses ncurses-devel curl curl-devel e2fsprogs e2fsprogs-devel krb5-devel libidn libidn-devel openssl openssh openssl-devel libxslt-devel libevent-devel ntp libtool-ltdl bison libtool vim-enhanced python wget lsof iptraf strace lrzsz kernel-devel kernel-headers pam-devel Tcl/Tk cmake ncurses-devel bison setuptool popt-devel net-snmp screen perl-devel pcre-devel net-snmp screen tcpdump rsync sysstat man iptables sudo idconfig git system-config-network-tui bind-utils update arpscan tmux elinks numactl iftop bwm-ng
#安装pip
wget https://bootstrap.pypa.io/get-pip.py --no-check-certificate
python get-pip.py
#使用国内豆瓣源
#mkdir /root/.pip
#vi /root/.pip/pip.conf
[global]
index-url =
trusted-host = pypi.douban.com
安装数据库
wget
rpm -ivh mysql-community-release-el7-5.noarch.rpm
yum install mysql-community-server
systemctl start mysql
systemctl enable mysqld
安装redis
yum install redis
systemctl start redis
systemctl enable redis
安装go语音环境(若使用编译好的二进制文件,此步骤可忽略)
yum install golang
go version
go version go1.6.3 linux/amd64
工作目录及初始化数据库
mkdir /opt/openfalcon
cd /opt/openfalcon
git clone https://github.com/open-falcon/scripts.git
#导入表结构
mysql -h localhost -u root --password="" < db_schema/graph-db-schema.sqlmysql -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
下载编译好的组件
mkdir /opt/openfalcon/tmp
cd /opt/openfalcon/tmp
wget https://github.com/open-falcon/of-release/releases/download/v0.1.0/open-falcon-v0.1.0.tar.gz
tar -zxf open-falcon-v0.1.0.tar.gz
rm -rf open-falcon-v0.1.0.tar.gz
cd /opt/openfalcon
for x in `find ./tmp/ -name "*.tar.gz"`;do \app=`echo $x|cut -d‘-‘-f2`; \
mkdir -p $app; \
tar -zxf $x -C $app; \done
#解压完毕
三、开始安装
第一部分:绘图组件安装
组件列表:
组件名称
用途
服务端口备注
Agent
部署在目标机器采集机器监控项
http: 1988
Transfer