#!/bin/bashinit(){yum install -y epel-* yum install -y wget vim git unzip python-pip epel-release golang redis pip install gunicornsystemctl start redissystemctl enable redissystemctl stop firewalldsystemctl disable firewalldsed -i "s/SELINUX=enforcing/SELINUX=disabled/" /etc/selinux/configsetenforce 0 }mysql_install(){#https://www.percona.com/downloads/Percona-Server-5.6/yum install -y http://www.percona.com/downloads/percona-release/redhat/0.1-6/percona-release-0.1-6.noarch.rpmyum install -y Percona-Server-server-56 Percona-Server-devel-56service mysql startmysqladmin -uroot password root123}falcon_pack() {export GOROOT=/usr/lib/golangexport GOPATH=/homemkdir -p $GOPATH/src/github.com/open-falconcd $GOPATH/src/github.com/open-falcongit clone https://github.com/open-falcon/falcon-plus.gitcd $GOPATH/src/github.com/open-falcon/falcon-plus/scripts/mysql/db_schema/mysql -h 127.0.0.1 -u root -proot123mysql -h 127.0.0.1 -u root -proot123mysql -h 127.0.0.1 -u root -proot123mysql -h 127.0.0.1 -u root -proot123mysql -h 127.0.0.1 -u root -proot123cd $GOPATH/src/github.com/open-falcon/falcon-plus/go get -v github.com/open-falcon/rrdlitemake allmake pack}falcon_install(){export WORKSPACE=/home/workmkdir -p $WORKSPACEcd $GOPATH/src/github.com/open-falcon/falcon-plus/tar -xzvf *.tar.gz -C $WORKSPACEsed -i 's/root:/root:root123/g' /home/work/aggregator/config/cfg.jsonsed -i 's/root:/root:root123/g' /home/work/graph/config/cfg.jsonsed -i 's/root:/root:root123/g' /home/work/hbs/config/cfg.jsonsed -i 's/root:/root:root123/g' /home/work/nodata/config/cfg.jsonsed -i 's/root:/root:root123/g' /home/work/api/config/cfg.jsonsed -i 's/root:/root:root123/g' /home/work/alarm/config/cfg.jsoncd $WORKSPACE./open-falcon start}falcon_dashboard(){export FRONTSPACE=/home/front/open-falconmkdir -p $FRONTSPACEcd $FRONTSPACEgit clone https://github.com/open-falcon/dashboard.gityum groupinstall "Development tools" -yyum install -y python-virtualenv python-devel openldap-devel openssl-devel libblockdev-crypto-develcd $FRONTSPACE/dashboard/virtualenv ./env./env/bin/pip install -r pip_requirements.txtbash control start#https://github.com/open-falcon/dashboard#修改rrd/config.py}mymon:go get -u github.com/open-falcon/mymoncd $GOPATH/src/github.com/open-falcon/mymonmake再配置IP就OKhttps://github.com/sylzd/mymon/releaseshttps://jicki.me/linux/2017/08/18/Open-Falcon/mailgo get -v github.com/zzlyzq/mail-providercd $GOPATH/src/github.com/zzlyzq/mail-providergo get./control build./control packmkdir -p /home/work/mail-providermv falcon-mail-provider-0.0.1.tar.gz /home/work/mail-providercd /home/work/mail-providertar zxvf falcon-mail-provider-0.0.1.tar.gzvi cfg.json{ "debug": true, "http": { "listen": "0.0.0.0:4000", "token": "" }, "smtp": { "addr": "smtp.exmail.qq.com:587", "username": "rdsys@123.com", "password": "FEI", "from": "rdsys@123.com" }}./control start./control tailcurl http://127.0.0.1:4000/sender/mail -d "tos=zheni@123.com&subject=xx&content=yy"钉钉https://github.com/sdvdxl/falcon-message微信https://github.com/Yanjunhui/chatlvs:yum update -y nss curl libcurl libnl3-devel libnl3go get -v github.com/mesos-utility/lvs-metricscd $GOPATH/src/github.com/mesos-utility/lvs-metrics./control build./control packmkdir -p /home/work/lvs-metricsmv lvs-metrics-v0.3.0.tar.gz /home/work/lvs-metricscd /home/work/lvs-metrics./control startmongomonhttps://github.com/ZhuoRoger/mongomoncd /home/work/git clone https://github.com/ZhuoRoger/mongomon.gitredishttps://github.com/ZhuoRoger/redismon进程数监控,端口proc.num tags: name=haproxyhttps://blog.csdn.net/cry1049208942/article/details/85264737expressionshttps://blog.kazaff.me/2016/08/10/Open-Falcon%E5%88%9D%E6%8E%A2/视频https://www.jikexueyuan.com/course/1651_4.html?ss=1