此内容没有您所选择的语言版本。

3.2. Service Policies


RGManager has three service recovery policies which may be customized by the administrator on a per-service basis.

Note

These policies also apply to virtual machine resources.

3.2.1. Start Policy

RGManager by default starts all services when RGManager boots and a quorum is present. This behavior may be altered by administrators.
  • autostart (default) - start the service when RGManager boots and a quorum forms. If set to '0', the cluster will not start the service and instead place it in to the disabled state.

3.2.2. Recovery Policy

The recovery policy is the default action RGManager takes when a service fails on a particular node. There are four available options, defined in the following list.
  • restart (default) - restart the service on the same node. If no other recovery policy is specified, this recovery policy is used. If restarting fails, RGManager falls back to relocate the service.
  • relocate - Try to start the service on other node(s) in the cluster. If no other nodes successfully start the service, the service is then placed in the stopped state.
  • disable - Do nothing. Place the service into the disabled state.
  • restart-disable - Attempt to restart the service, in place. Place the service into the disabled state if restarting fails.

3.2.3. Restart Policy Extensions

When the restart recovery policy is used, you may additionally specify a maximum threshold for how many restarts may occur on the same node in a given time. There are two parameters available for services called max_restarts and restart_expire_time which control this.
The max_restarts parameter is an integer which specifies the maximum number of restarts before giving up and relocating the service to another host in the cluster.
The restart_expire_time parameter tells RGManager how long to remember a restart event.
The use of the two parameters together creates a sliding window for the number of tolerated restarts in a given amount of time. For example:
<service name="myservice" max_restarts="3" restart_expire_time="300" ...>
  ...
</service>
The above service tolerance is 3 restarts in 5 minutes. On the fourth service failure in 300 seconds, RGManager will not restart the service and instead relocate the service to another available host in the cluster.

Note

You must specify both parameters together; the use of either parameter by itself is undefined.
Red Hat logoGithubRedditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

© 2024 Red Hat, Inc.