Blue Whale Community Edition 4.0 integrated installation experience

第一次写这个,我是按照自己写的一步一步操作,部署成功,希望里面的内容对大家有所借鉴,因为开发和linux系统与我来说,我就是一个一只脚站在门口的人,所以有错误的地方或者能改进的地方也恳请大家指正出来,一起学习。下面进入正文
IP functional components
10.1.43.31 paas,cmdb,job,gse,kafka,zk,es,redis,consul,mongodb,bknetwork
10.1.43.33 license,appo,kafka,zk,es,mysql,beanstalk,consul
10.1.43.34 nginx,appt,rabbitmq,kafka,zk,es,bkdata,consul,fta

1. System environment initialization needs to be executed on each machine
1) Close NetworkManager
systemctl stop NetworkManager
systemctl disable NetworkManager
systemctl restart network

2)设置DNS
sudo echo -e "nameserver 127.0.0.1\nnameserver 202.106.0.20" >> /etc/resolv.conf

3)yum安装一些常用的东西
yum -y install vim wget iptraf sysstat lsof zlib-devel bind-utils telnet dmidecode wget openssl-devel tcpdump ntpdate gcc gcc-c++ make pcre-devel \
readline-devel pciutils openssl-devel xinetd iptables libselinux-python rsync unzip bc

4)shutdown selinux
sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
/usr/sbin/setenforce 0
echo "/usr/sbin/setenforce 0" >> /etc/rc.local

5)关闭且禁止firewall开机启动
systemctl stop firewalld.service
systemctl disable firewalld.service

6)更新时间并设置自动更新计划
timedatectl set-local-rtc 1
timedatectl set-timezone Asia/Shanghai
echo  "0 */1 * * * /usr/sbin/ntpdate time.nist.gov  &>/dev/null"  >> /var/spool/cron/root

7)更换yum源
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
wget http://mirrors.aliyun.com/repo/Centos-7.repo
mv Centos-7.repo /etc/yum.repos.d/CentOS-Base.repo
yum clean all
yum makecache
yum update

8)更换epel仓库
wget -O /etc/yum.repos.d/epel-7.repo http://mirrors.aliyun.com/repo/epel-7.repo
yum clean all
yum makecache

wget https://mirrors.ustc.edu.cn/epel/7/x86_64/Packages/e/epel-release-7-11.noarch.rpm
rpm -ivh epel-release-7-11.noarch.rpm

2. Upload the three packages downloaded from the official website to the /data directory of the central computer, and decompress them as required. #bkce_src, install_ce-master and ssl_certificates.tar
tar -xf /data/bkce_src-4.0.14.tgz -C /data/
tar -xf /data/install_ce-master-1.1.33.tgz -C /data/
tar xf ssl_certificate.tar -C /data/src/cert/

3. Configure the install.config file
[root@localhost ~]# cd /data/install
[root@localhost install]# cp install.config.3IP.sample install.config
[root@localhost install]# vim install.config #If To install the network management platform, add "bknetwork" to the end of any line in this document

Blue Whale Community Edition 4.0 integrated installation experience
4. Configure the domain name, account password of each component, and PIP source (because the default pip source can be used by me, so there is no modification)
[root@localhost install]# vim globals.env #The domain name of the network management platform is in the bkco.env file modified in

5. Configure password-free login, and enter the root password of each host as prompted to complete the password-free login configuration
[root@localhost install]# bash configure_ssh_without_pass

6. Start the installation
1) Install paas
[root@localhost install]#./bk_install paas
2) Exit ssh and then log in again and enter the installation directory, because after the paas installation is complete, the hostname of each host has changed, and you need to ssh again Click [root@localhost install]
#logout [root
@localhost ~]# cd /data/install
3) Install cmdb
[root@localhost install]#./bk_install cmdb
4) Install job
[root@paas-1 install]# . /bk_install job #The
first execution will report an error, you need to go to the job machine to start rabbitmq-server (systemctl start rabbitmq-server), and add NODENAME=rabbit@localhost to the /etc/rabbitmq/rabbitmq-env.conf file , and then go back to the central control machine to execute the installation command
5) Deploy the formal environment and test environment
[root@paas-1 install]# ./bk_install app_mgr
6) Install the blue whale data platform basic module and its dependent services
[root@paas- 1 install]# ./bk_install bkdata

7. Client access platform
1) Configure local hosts #Here I am using hosts resolution instead of DNS resolution
10.1.43.34 paas.accp.com job.accp.com cmdb.accp.com #On this machine (Windows system) Add this parsing to the hosts file of the nginx server, or copy the records in the hosts on the nginx server directly.
At this point, you can access various platforms (paas, cmdb, job, etc.) through the domain name

8. Blue Whale Community Edition V4.0 Network Management Platform Deployment Guide
Pre-deployment preparation

1).编辑 install.config文件,在任意一行末尾 新增 bknetwork模块

2).编辑 bkco.env 文件,将域名改为自己需要的域名

注意:本文档部署指南只针对蓝鲸社区版4.0 部署

3)开始部署

[root@paas-1 install]#./bkcec sync bknetwork
[root@paas-1 install]#./bkcec install bknetwork
[root@paas-1 install]#./bkcec initdata bknetwork
[root@paas-1 install]#./bkcec start bknetwork
[root@paas-1 install]#./bkcec status bknetwork

4)重启nginx服务

验证

通过 bknetwork.$BK_DOMAIN 访问(登录用户名/密码与 PaaS 一致),能正常打开界面,且使用正常即部署成功

9. After restarting the system, the service pull-up sequence
1) Start the rabbitmq-server service on the rabbitmq machine (10.1.43.34)
2) The central control machine pulls up the service in the following order:
consul
mysql
license
redis
nginx
paas
rabbitmq
appo
zk
gse
mongodb
cmdb
appt
job
es
kafka
beanstalk
bkdata

3)在appo这台机器(10.1.43.33)运行下面的脚本,用来拉起SAAS服务

#!/bin/bash
for dir in ls -l /data/bkce/paas_agent/apps/Envs/ |awk '{print $9}'
do
echo $dir
rm -rf /data/bkce/paas_agent/apps/projects/$dir/run/supervisord.sock
cd /data/bkce/paas_agent/apps/Envs/$dir/bin/
./supervisord -c /data/bkce/paas_agent/apps/projects/$dir/conf/supervisord.conf
./supervisorctl -c /data/bkce/paas_agent/apps/projects/$dir/conf/supervisord.conf start all
./supervisorctl -c /data/bkce/paas_agent/apps/projects/$dir/conf/supervisord.conf status all
done

10. Related link
installation package download: http://bk.tencent.com/download/
ssl certificate download: http://bk.tencent.com/download/#ssl
official deployment manual: http://bk.tencent. com/document/bkbuild/000421.html
SAAS application download: http://bk.tencent.com/s-mart/market
Note:
1) The agent needs to go to the SAAS application market to download the 4.0 community version dedicated, and then deploy.
2) Please read this article in conjunction with the official deployment manual, do not miss any word
3) The command to start the service on the central control machine is: ./bkcec start service name

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325858740&siteId=291194637