This site best when viewed with a modern standards-compliant browser. We recommend Firefox Get Firefox!.

Linux-HA project logo
Providing Open Source High-Availability Software for Linux and other OSes since 1999.

USA Flag UK Flag

Japanese Flag

ホームページ

サイトについて

コンタクト情報

使用条件

協力方法

セキュリティ

This web page is no longer maintained. Information presented here exists only to avoid breaking historical links.
The Project stays maintained, and lives on: see the Linux-HA Reference Documentation.
To get rid of this notice, you may want to browse the old wiki instead.

2010.1.28
追加パッケージ集リニューアル
追加パッケージ集は、こちらから

2008.8.28
RHEL用rpm更新
更新情報はこちらから

2008.8.18
Heartbeat 2.1.4
リリース!
Downloadはこちらから

2007.11.13
Linux-ha-japan日本語ML移植しました

2007.10.5
日本語サイトOPEN
日本語MLも開設しました

2007.10.5
OSC2007 Tokyo/Fall で Heartbeat紹介
発表資料を公開しました

Last site update:
2017-12-13 11:48:09

hb_standby

This is a simple shell script that issues a failover from the node where it is running to the other node, if available. It is useful to interface with an external resource monitor, such as mon or Nagios, or any home-made-monitor-script.

hb_standby is a script that allows manual control of which node is controlling what resources at a given time. When the "standby" option is provided to the Heartbeat init script, it calls hb_standby with the "all" option.

    usage: hb_standby [all|foreign|local|failback]

The full path is usually /usr/lib/heartbeat/hb_standby. To get a list of the options to hb_standby issue the command, "/usr/lib/heartbeat/hb_standby --help". NOTE: For historical reasons, unlike most scripts where failure to specify an option gives you the list of possible options, failure to provide an option to hb_standby is equivalent to "hb_standby all".

The meaning of the options is relative. For this sample haresources file (IMPORTANT: all resources for one node on one line):

nodea drbddisk::r0 Filesystem::/dev/drbd0::/local/groups::ext3 10.0.0.1 smb
nodeb drbddisk::r1 Filesystem::/dev/drbd1::/local/ldap::ext3 10.0.0.2 ldap

hb_standby local

When run on nodea, means migrate any resources that nodea is the preferred node for. In this case Samba would be shutdown, the IP address 10.0.0.1 would be released, /local/groups would be unmounted, /dev/drbd0 would be placed into secondary and nodeb would take all these services over.

When run on nodeb, OpenLDAP would shutdown, 10.0.0.2 would be released, /local/ldap would be unmounted, /dev/drbd1 would be placed into Secondary mode and nodea would take over all these services.

hb_standby foreign

When run on nodea, means migrate any resources that nodea is NOT the preferred node for. In this case OpenLDAP would shutdown, 10.0.0.2 would be released, /local/ldap would be unmounted, /dev/drbd1 would be placed into Secondary mode and nodeb would take over all these services.

When run on nodeb, Samba would be shutdown, the IP address 10.0.0.1 would be released, /local/groups would be unmounted, /dev/drbd0 would be placed into secondary and nodea would take all these services over.

hb_standby all

Regardless of which node it's run on means to release all resources so the other node takes over all resources.

hb_standby

Without an argument is the same as "hb_standby all"

hb_standby failback

Same as "hb_standby foreign"

See Also

haresources, hb_takeover, cl_status, mon, failback