chentos7 编译安装keepalived 1.4.5
准备工作:
下载源码包,官方网站
下载命令:wget https://www.keepalived.org/software/keepalived-1.4.5.tar.gz
解压tar包,命令: tar zxvf keepalived-1.4.5.tar.gz
一、安装依赖包
[root@docker_node01 ~ ]# yum install -y gcc openssl-devel libnl libnl3-devel libnfnetlink-devel
二、编译安装
[root@docker_node01 ~]# cd keepalived-1.4.5
[root@docker_node01 keepalived-1.4.5]# ./configure prefix=/usr/local/keepalived [root@docker_node01 keepalived-1.4.5]# make && make install
三、创建配置文件目录
[root@docker_node01 keepalived]# cd /usr/local/keepalived/ [root@docker_node01 keepalived]# mkdir conf
四、将配置文件模板拷贝到配置文件目录
[root@docker_node01 keepalived]# cp etc/keepalived/keepalived.conf conf/
五、编辑配置文件
略
六、启动keepalived
[root@docker_node01 keepalived]# /usr/local/keepalived/sbin/keepalived -f /usr/local/keepalived/conf/keepalived.conf