Show Table of Contents
2.8. 集群和高可用性
本小节总结了 Red Hat Enterprise Linux 6 和 Red Hat Enterprise Linux 7 集群和高可用性支持更改以及相关配置工具。
2.8.1. Luci 替换限制(pcs)
在 Red Hat Enterprise Linux 6 中,
luci 可控制 Red Hat Enterprise Linux 5 和 Red Hat Enterprise Linux 6 高可用性集群。
Red Hat Enterprise Linux 7 移除了
luci 并使用 pcs 替换。luci 只能控制 Red Hat Enterprise Linux 7 基于 pacemaker 的集群。它不能控制 Red Hat Enterprise Linux 6 基于 rgmanger 的高可用性集群。
2.8.2. Keepalived 替换 Piranha
Red Hat Enterprise Linux 7 的负载平衡附加组件现包含
keepalived 服务,该服务可提供 piranha 中可使用的功能以及附加功能。因此在 Red Hat Enterprise Linux 7 中使用 keepalived 服务取代 piranha。
这样会造成配置文件及其格式的变化。默认情况下是使用
/etc/keepalived/keepalived.conf 文件配置 keepalived。本文件应使用的配置格式及语法请参考 keepalive.conf man page:
$ man keepalived.conf
2.8.3. 在线迁移限制
集群不支持在线从 Red Hat Enterprise Linux 6 迁移到 Red Hat Enterprise Linux 7。
另外,Red Hat Enterprise Linux 6 高可用栈与 Red Hat Enterprise Linux 7 高可用栈不兼容,因此不支持从 Red Hat Enterprise Linux 6 迁移到 Red Hat Enterprise Linux 7 高可用性集群。
2.8.4. 新资源管理程序(Pacemaker)
从 Red Hat Enterprise Linux 7 开始,使用 pacemaker 和 corosync替换 rgmanager 和 cman。
Pacemaker 是一个高可用资源管理程序,有很多有用的功能。
- 检测并回复机器和应用程序层失败。
- 支持很多冗余配置。
- 支持仲裁和资源驱动集群。
- (当多台机器失败时)处理仲裁损失的可配置策略
- 支持指定应用程序启动及关闭顺序,不考虑应用程序所在及机器。
- 支持指定一定要或者一定不要在同一台机器中运行的应用程序。
- 支持指定应在多台机器中激活的应用程序。
- 支持应用程序的多种模式,比如 master 和 slave。
- 可证明地正确响应任何失败或者集群状态。
- 状态存在前,可离线测试对所有状况的响应。
有关 Pacemaker 的详情请参考 Red Hat Enterprise Linux 7 高可用性附加组件文档,网址为 http://access.redhat.com/site/documentation/Red_Hat_Enterprise_Linux/。
2.8.5. 新功能:资源代理
Red Hat Enterprise Linux 7 引进了资源代理,该功能可提取集群资源并提供在集群环境中管理资源的标准界面。有关 Red Hat Enterprise Linux 7 资源代理的详情请查看 Red Hat Enterprise Linux 7 高可用性附加组件文档,网址为 http://access.redhat.com/site/documentation/Red_Hat_Enterprise_Linux/。
2.8.6. 更改的仲裁实施
已从 Red Hat Enterprise Linux 7 中删除了 Red Hat Enterprise Linux 6 中附带的 qdiskd。新的仲裁实施由包含在 corosync 软件包中的
votequorum 提供,且在大多数使用案例中替换了 qdiskd。扩展(wait_for_all, auto_tie_breaker 和 last_man_standing)在 votequorum.5 man page 中有详细的说明。
$ man 5 votequorum

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.