oVirt管理端高可用模式搭建

oVirt是一个分布式虚拟化解决方案,旨在管理整个企业基础架构,oVirt使用受信任的KVM管理程序
操作系统版本:centos7.5
ovirt版本:ovirt4.2
安装模式:hosted-engine管理端高可用模式,其中engine作为一台虚拟机漂在所有的node节点上,如果当engine所在的node节点锁坏,那么会自动迁移到另一个node节点上。
硬件要求:engine作为管理端,CPU不低于四核,内存不低于16G,硬盘不低于50GB以及至少为1Gbps的网络接口;因为engine端作为虚拟机漂移在所有节点,那么所有node节点硬件配置均大于engine端的硬件配置。

步骤:

一、关闭selinux(所有节点)

[root@node1 ~]#sed -i ‘s/SELINUX=enforcing/SELINUX=disabled/’ /etc/selinux/config
[root@node1 ~]#setenforce 0

二、设定好 engine 虚拟机的 ip(所有节点)

虚拟机的 ip 要提前定好,并将对应的ip和域名写到主机的/etc/hosts中(因为 Hosted-Engine 中,和 engine 虚拟机的交互使用的是 FQDN)

[root@node1 ~]# vi /etc/hosts
192.168.40.110 engine.lxkj.com engine
192.168.40.111 node1.lxkj.com node1
192.168.40.112 node2.lxkj.com node2
192.168.40.113 node3.lxkj.com node3
192.168.40.114 node3.lxkj.com node4

三、ssh互信

[root@node1 ~]#ssh-keygen
[root@node1 ~]#ssh-copy-id node1
[root@node1 ~]#ssh-copy-id node2
[root@node1 ~]#ssh-copy-id node3
[root@node1 ~]#ssh-copy-id node4

四、添加 ovirt-4.2 的源(所有节点)

[root@node1 ~]#yum install http://resources.ovirt.org/pub/yum-repo/ovirt-release42.rpm -y

五、配置存储Glusterfs服务

1. 安装glusterfs(所有节点)

[root@node1 ~]#yum install -y vdsm-gluster

2. 启动glusterfs(所有节点)

[root@node1 ~]#systemctl enable --now glusterd

3. 创建挂载目录并授权(所有节点)

[root@node1 ~]#mkdir -p /glusterfs/database/
[root@node1 ~]#chown -R vdsm:kvm /glusterfs/database/ # 为了ovirt挂载使用

4. 添加防火墙规则(所有节点)

[root@node1 ~]#firewall-cmd --add-service=glusterfs --permanent
[root@node1 ~]#firewall-cmd --reload

5. 配置信任池(仅node1)

[root@node1 ~]#gluster peer probe node2
[root@node1 ~]#gluster peer probe node3
[root@node1 ~]#gluster peer probe node4

6. 设置gluster卷(仅node1)

[root@node1 ~]#gluster volume create gfs1 replica 2 transport tcp node1:/glusterfs/database/ node2:/glusterfs/database/ node3:/glusterfs/database/ node4:/glusterfs/database/ force

7. 启动gluster卷(仅node1)

[root@node1 ~]#gluster volume start gfs1

8. 确认gluster卷状态(所有节点)

[root@node1 ~]#gluster volume info

六、安装 ovirt-hosted-engine-setup 的包(仅node1)

[root@node1 ~]#yum install -y ovirt-hosted-engine-setup

七、配置 ovirt-hosted-engine(仅node1)

使用屏幕窗口管理器来运行脚本,以避免在网络或终端中断时丢失会话。
注意:可使用Ctrl+D键盘组合中止部署。如果会话超时或连接中断,请运行screen -d -r以恢复部署会话。

[root@node1 ~]#screen

启动部署脚本

[root@node1 ~]#ovirt-hosted-engine-setup

选择“ yes”开始部署:

Are you sure you want to continue? (Yes, No)[Yes]:

配置网络,该脚本检测可能的NIC以用作环境的管理桥

Please indicate a pingable gateway IP address [192.168.40.1]:
Please indicate a nic to set ovirtmgmt bridge on: (eth0) [eth0]:

将此字段留空以使用oVirt Engine Appliance。

(leave it empty to skip, the setup will use ovirt-engine-appliance rpm installing it if missing):

指定Engine虚拟机的FQDN

Engine VM FQDN:  []: engine.lxkj.com
Engine VM domain: [lxkj.com]

输入Engine的root密码:

Enter root password that will be used for the engine appliance:
Confirm appliance root password:

输入一个SSH公钥,允许您以root用户身份登录Engine,并指定是否为root用户启用SSH访问:

Enter ssh public key for the root user that will be used for the engine appliance (leave it empty to skip)
Do you want to enable ssh access for the root user (yes, no, without-password) [yes]:

输入虚拟机的CPU和内存配置:

Please specify the number of virtual CPUs for the VM (Defaults to appliance OVF value): [4]:
Please specify the memory size of the VM in MB (Defaults to appliance OVF value): [16384]:

输入Engine虚拟机的MAC地址,或接受随机生成的虚拟机

You may specify a unicast MAC address for the VM or accept a randomly generated default [00:16:3e:2c:2c:39]:

输入虚拟机的网络详细信息

How should the engine VM network be configured (DHCP, Static)[DHCP]? static

静态IP地址必须与主机属于同一子网

Please enter the IP address to be used for the engine VM [192.168.40.2]: 192.168.40.110
Engine VM DNS (leave it empty to skip) [61.139.2.69,119.6.6.6]:

指定是否将Engine虚拟机和基本主机的条目添加到虚拟机的/etc/hosts文件中。

Note: ensuring that this host could resolve the engine VM hostname is still up to you (Yes, No)[No] yes

提供SMTP服务器的名称和TCP端口号,用于发送电子邮件通知的电子邮件地址以及用于接收这些通知的逗号分隔的电子邮件地址列表:

Please provide the name of the SMTP server through which we will send notifications [localhost]:
Please provide the TCP port number of the SMTP server [25]:
Please provide the email address from which notifications will be sent [root@localhost]:
Please provide a comma-separated list of email addresses which will get notifications [root@localhost]:

输入admin @ internal用户的密码以访问管理门户:

Enter engine admin password:
Confirm engine admin password:

选择要使用的存储类型:

Please specify the storage you would like to use (glusterfs, iscsi, fc, nfs)[nfs]: glusterfs

对于glusterfs,请输入完整地址和路径以及任何装载选项:

Please specify the full shared storage connection path to use (example: host:/path): 192.168.40.111:/gfs1

输入引擎磁盘大小:

Please specify the size of the VM disk in GiB: [50]: 100

清理失败的自托管引擎部署

如果自托管引擎部署中断,后续部署将失败并显示错误消息。错误将根据部署失败的阶段而有所不同。如果收到错误消息,请运行清理脚本以清除失败的部署。

运行清理脚本

运行/usr/sbin/ovirt-hosted-engine-cleanup并选择y删除失败的自托管引擎部署遗留的任何内容。

 # /usr/sbin/ovirt-hosted-engine-cleanupThis will de-configure the host to run ovirt-hosted-engine-setup from scratch.Caution, this operation should be used with care.Are you sure you want to proceed? [y/n]

清理存储域

定义是在同一共享存储设备上重新安装还是选择其他共享存储设备。
要在同一存储域上部署安装,请通过在NFS,Gluster,PosixFS或本地存储域的服务器上的相应目录中运行以下命令来清理存储域:

  # rm -rf storage_location/*

重新部署自托管引擎。

oVirt管理端高可用模式搭建(hosted-engine)相关推荐

  1. 美团点评基于MGR的CMDB高可用架构搭建之路【转】

    王志朋 美团点评DBA 曾在京东金融担任DBA,目前就职于美团点评,主要负责金融业务线数据库及基础组件数据库的运维. MySQL Group Replication(以下简称MGR),于5.7.17版 ...

  2. MHA+keepalive高可用环境搭建

    MHA+keepalive高可用环境搭建 2017年02月17日 14:05:57 阅读数:2582 MHA(Master HighAvailability)目前在MySQL高可用方面是一个相对成熟的 ...

  3. Hadoop HA+Federation 高可用联邦模式搭建指南

    为什么80%的码农都做不了架构师?>>>    简述 Hadoop 集群一共有4种部署模式,详见<Hadoop 生态圈介绍>. HA联邦模式解决了单纯HA模式的性能瓶颈( ...

  4. hadoop高可用hdfs搭建(三节点)

    hadoop高可用HDFS搭建(三节点) 一:准备工作 本次搭建使用的hadoop版本是2.6.5,使用虚拟机准备三个干净的节点服务器,我们从零开始搭建.规范下三个节点的主机名分别是node003,n ...

  5. 阿里移动|《蚂蚁金服移动端高可用技术实践》

    摘要:对于移动技术而言,2017年是继往开来之年.一方面是移动技术领域进入深水区,另一方面移动技术边界和内涵被不断重塑.阿里巴巴希望进一步推动移动应用研发事实标准落地,从而赋能整个行业开发者.在201 ...

  6. Spark的安装(Standalone模式,高可用模式,基于Yarn模式)

    目录 spark的Standalone模式安装 一.安装流程 1.将spark-2.2.0-bin-hadoop2.7.tgz  上传到 /usr/local/spark/ 下,然后解压 2.进入到c ...

  7. MHA高可用架构搭建

    MHA高可用架构搭建 1.环境软件版本 2.环境架构介绍 3.MySQL主从搭建 3.1 MySQL安装(3台) 3.2 关闭防火墙 3.3 MySQL主从配置 Master节点 Slave1节点 S ...

  8. 基于Docker运行弹性集群的五个关键点第一篇:运行高可用模式

    原文来源:Rancher Labs 类似Rancher这种的容器管理和编排工具,它可以很快地让每个组织获得高效的弹性集群管理能力.当前技术世界的发展形势就是让开发人员从繁琐的应用配置和管理中解放出来, ...

  9. 14、高可用keepalived搭建及切换

    14.高可用keepalived搭建及切换 keepalived主从切换试验: 1.先搭建192.168.1.20与192.168.1.21的主主架构     192.168.1.76为VIP 2.在 ...

最新文章

  1. .NET 页面间传值的几种方法
  2. portal商品展示功能逻辑
  3. 快速下单!简化EcStore的购物结算流程
  4. C++容器的insert()函数有以下三种用法: 最终*it=val;
  5. 【POJ - 2392】Space Elevator (dp,优秀的背包问题)
  6. python 数学基础_Python3数学基础 - 随笔分类 - 既生喻何生亮 - 博客园
  7. 计算机图形学E5——OpenGL 扫描线填充
  8. mysql sqlserver 拷贝_SQLyog工具进行SQLSERVER表结构或数据拷贝到MySQL数据库
  9. 环洋调研报告-2021年全球MEMS射频开关行业调研及趋势分析报告
  10. 华为网络工程师认证有哪些?值不值得考?
  11. ping源码分析(超详细,多图,带背景分析)
  12. JS+CSS实现幻灯片
  13. 【网页截图亲测可用】Linux + python3 + selenium + chrome + chrome-driver 服务器端网页截图
  14. 10、PIC系列-输出比较-PWM脉宽调制模式
  15. 作业2.EVE ensp 模拟器CONSOLE接口密码设置
  16. 微信小程序-小程序的宿主环境
  17. OBS Studio 27.0.1版本编译
  18. 新入职一家公司如何快速进入工作状态
  19. mysql实现自增字符串_Mysql实现字符串主键自增示例教程-Go语言中文社区
  20. Python期末考试总复习资料

热门文章

  1. 用proteus来玩二极管或门电路
  2. php导出excel字体加粗,phpexcel 导出格式,字体调整
  3. 龙ol一键端服务器维护,龙OL一键端纯一键点两下OK问题及解答汇总贴.doc
  4. 计算显卡算力测试软件,380显卡算力多少
  5. 移除未排序链表中的重复节点,保留最开始出现的节点
  6. python高级工程师证书_Amireux
  7. 操作系统管理计算机资源
  8. html img素材,html使用img标签和背景图片之间的区别
  9. JVM中如何排查CPU飙高的问题
  10. 心形尺寸比例图解_标识牌尺寸大小及空间比例关系示意图与人体工程学