open-falcon初探(一)---安装部署

栏目: 数据库 · 发布时间: 5年前

内容简介:简介官网:小米运维团队出品开源监控软件,截止目前在github上已经有了4000余个星。

简介

官网: http://book.open-falcon.org/zh_0_2/

小米运维团队出品开源监控软件,截止目前在github上已经有了4000余个星。

go语言写的后端,python+flask语言写的前端。

本人应用zabbix多年,借此机会记录下学习的过程。

open-falcon安装:

使用编译好的二进制文件方式安装

centos 6.5

python 2.7.13

go1.11.5( https://golang.org/doc/install

#环境准备
yum install -y redis
yum install -y mysql-server

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 -phoolai < 1_uic-db-schema.sql
mysql -h 127.0.0.1 -u root -phoolai < 2_portal-db-schema.sql 
mysql -h 127.0.0.1 -u root -phoolai < 3_dashboard-db-schema.sql 
mysql -h 127.0.0.1 -u root -phoolai < 4_graph-db-schema.sql 
mysql -h 127.0.0.1 -u root -phoolai < 5_alarms-db-schema.sql 

#后端安装:
#下载编译好的二进制文件:
mkdir open-falcon && cd /data/open-falcon
wget https://github.com/open-falcon/falcon-plus/releases/download/v0.2.1/open-falcon-v0.2.1.tar.gz

grep -Ilr 3306  ./ | xargs -n1 -- sed -i 's/root:/real_user:real_password/g'
#real_user和real_password修改为 mysql 的用户名密码
./open-falcon start
./open-falcon check

#前端安装:
git clone https://github.com/open-falcon/dashboard.git

virtualenv ./env
./env/bin/pip install -r pip_requirements.txt -i https://pypi.douban.com/simple
#在rrd/config.py修改配置文件中关于mysql用户密码相关配置

bash control start
#小提示:注册账号能够被任何打开dashboard页面的人注册,
#所以当给相关的人注册完账号后,需要去关闭注册账号功能。
#只需要去修改api组件的配置文件cfg.json,将signup_disable配置项修改为true,重#启api即可。
#当需要给人开账号的时候,再将配置选项改回去,用完再关掉即可。

agent安装:

把agent和open-falcon打包传到被监控机上

修改 agent/config/cfg.json 中的配置

{
    "debug": true,
    "hostname": "期望的endpoint名字",  ###修改此行###
    "ip": "",
    "plugin": {
        "enabled": false,
        "dir": "./plugin",
        "git": "https://github.com/open-falcon/plugin.git",
        "logs": "./logs"
    },
    "heartbeat": {
        "enabled": true,
        "addr": "open-falcon主机的ip地址:6030",  ###修改此行###
        "interval": 60,
        "timeout": 1000
    },
    "transfer": {
        "enabled": true,
        "addrs": [
            "open-falcon主机的ip地址:8433"   ###修改此行###
        ],
        "interval": 60,
        "timeout": 1000
    },
    "http": {
        "enabled": true,
        "listen": ":1988",
        "backdoor": false
    },
    "collector": {
        "ifacePrefix": ["eth", "em"],
        "mountPoint": []
    },
    "default_tags": {
    },
    "ignore": {
        "cpu.busy": true,
        "df.bytes.free": true,
        "df.bytes.total": true,
        "df.bytes.used": true,
        "df.bytes.used.percent": true,
        "df.inodes.total": true,
        "df.inodes.free": true,
        "df.inodes.used": true,
        "df.inodes.used.percent": true,
        "mem.memtotal": true,
        "mem.memused": true,
        "mem.memused.percent": true,
        "mem.memfree": true,
        "mem.swaptotal": true,
        "mem.swapused": true,
        "mem.swapfree": true
    }
}

./open-falcon start agent启动


以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Java从入门到精通

Java从入门到精通

魔乐科技MLDN软件实训中心 / 人民邮电出版社 / 2010-4 / 59.00元

《Java从入门到精通》主要内容涵盖Java应用程序的创建及语言特点,Java开发工具Eclipse的使用,类和对象,Java程序异常处理,Java多线程,Java网络程序设计和Java数据库编程等,并通过五子棋和人事管理系统的设计两大项目讲解Java实用操作。《Java从入门到精通》在DVD光盘中赠送了Java SE类库查询手册,Java程序员职业规划,Java开发经验及技巧大汇总等丰富资源,包......一起来看看 《Java从入门到精通》 这本书的介绍吧!

HTML 压缩/解压工具
HTML 压缩/解压工具

在线压缩/解压 HTML 代码

RGB转16进制工具
RGB转16进制工具

RGB HEX 互转工具

html转js在线工具
html转js在线工具

html转js在线工具