Open-falon监控安装过程
具体参考: http://book.open-falcon.org/zh/quick_install/prepare.html
1. 安装ntp、vim编辑器、mysql、gcc、epel-release源、redis、git、wget,启动redis服务、开启时间同步服务、将时间写入bios、关闭防火墙、关闭selinux
yum install ntp vim mysql-server* mysql-d* gcc epel-release git wget -y
yum install redis -y
redis-server /etc/redis.conf
service ntpd restart
service mysqld restart
hwclock -w
2. 关闭防火墙、关闭selinux
关闭重启生效: chkconfig iptables off
关闭立即生效: service iptables stop
vi /etc/sysconfig/selinux
SELINUX=disabled 重启后生效
setenforce 0 临时关闭,重启失效
- 3. 新建普通用户授予sudo权限,
adduser mimmc
passwd openfalcon
[root@MI-MMC01 ~]# vim /etc/sudoers
- 4. 固定IP地址
- 初始化mysql表结构,安装环境参考注:安装环境进入mimmc账户
http://book.open-falcon.org/zh/install_from_src/prepare.html
5如果需升级
pyhhon 请参考
http://www.111cn.net/sys/CentOS/53297.htm
6.安装agent等组件
下载编译好的文件 http://book.open-falcon.org/zh/quick_install/prepare.html
7.安装query
添加vim graph_backends.txt 文件
安装Dashboard
mysql-python 通过easy_install mysql-python 安装
[root@MI-MMC01 dashboard]# source env/bin/activate
退出deactivate
(env)[root@MI-MMC01 dashboard]# easy_install mysql-python
pip install -r pip_requirements.txt
7.
: UserWarning: /home/server/.python-eggs is writable by group/others and vulnerable to attack when used with get_resource_filename. Consider a more secure location (set with .set_extraction_path or the PYTHON_EGG_CACHE environment variable).
warnings.warn(msg, UserWarning)
解决办法
进入 /home/server/
chmod g-wx,o-wx .python-eggs/