summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys-cluster/heartbeat/ChangeLog9
-rw-r--r--sys-cluster/heartbeat/Manifest33
-rw-r--r--sys-cluster/heartbeat/files/digest-heartbeat-2.0.7-r23
-rw-r--r--sys-cluster/heartbeat/files/heartbeat-2.0.7-update-resources-failcount.patch223
-rw-r--r--sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild8
-rw-r--r--sys-cluster/heartbeat/heartbeat-2.0.7-r2.ebuild119
6 files changed, 376 insertions, 19 deletions
diff --git a/sys-cluster/heartbeat/ChangeLog b/sys-cluster/heartbeat/ChangeLog
index 5d8e569a3641..e40b59a7853e 100644
--- a/sys-cluster/heartbeat/ChangeLog
+++ b/sys-cluster/heartbeat/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for sys-cluster/heartbeat
# Copyright 2000-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-cluster/heartbeat/ChangeLog,v 1.56 2006/09/17 22:38:42 xmerlin Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/heartbeat/ChangeLog,v 1.57 2006/09/17 22:48:05 xmerlin Exp $
+
+*heartbeat-2.0.7-r2 (17 Sep 2006)
+
+ 17 Sep 2006; Christian Zoffoli <xmerlin@gentoo.org>
+ +files/heartbeat-2.0.7-update-resources-failcount.patch,
+ heartbeat-2.0.7-r1.ebuild, +heartbeat-2.0.7-r2.ebuild:
+ Update resource failcount in all required cases, fixed bug #147435.
17 Sep 2006; Christian Zoffoli <xmerlin@gentoo.org>
-files/heartbeat-1.2.3-lvm.patch,
diff --git a/sys-cluster/heartbeat/Manifest b/sys-cluster/heartbeat/Manifest
index d47f598ebce4..54eea4ce12b4 100644
--- a/sys-cluster/heartbeat/Manifest
+++ b/sys-cluster/heartbeat/Manifest
@@ -1,6 +1,10 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
+AUX heartbeat-2.0.7-update-resources-failcount.patch 6648 RMD160 71e59accbad7883af4dae8d129ff15cdb59105fc SHA1 cc644a7d69c3d999bc440083723951cce1011b67 SHA256 0a08f4e45037724a3cc0877a16452d351535cee2d43dcb4a4bbd47c6c9ab7f3f
+MD5 d79f60a454bf23d2160a9deb419cf7b8 files/heartbeat-2.0.7-update-resources-failcount.patch 6648
+RMD160 71e59accbad7883af4dae8d129ff15cdb59105fc files/heartbeat-2.0.7-update-resources-failcount.patch 6648
+SHA256 0a08f4e45037724a3cc0877a16452d351535cee2d43dcb4a4bbd47c6c9ab7f3f files/heartbeat-2.0.7-update-resources-failcount.patch 6648
AUX heartbeat-init 1616 RMD160 2a76f26e572b0b466fa860f8eab0fad5fcb6e29f SHA1 9c20eff23ee59434b1d9f222adb587c1bc7a7e26 SHA256 98e34d2e9d6fde5e8dedb1b4d934fa39b502f2d4e603e9faa7a86b66cd0e0437
MD5 74949e88062a20f9c6c20dd01c20533b files/heartbeat-init 1616
RMD160 2a76f26e572b0b466fa860f8eab0fad5fcb6e29f files/heartbeat-init 1616
@@ -11,14 +15,18 @@ EBUILD heartbeat-1.2.5.ebuild 1986 RMD160 b25871073d61edada88a167eaf37a4de2b552d
MD5 f58c89bbad4b79cf45813b8425371891 heartbeat-1.2.5.ebuild 1986
RMD160 b25871073d61edada88a167eaf37a4de2b552d6a heartbeat-1.2.5.ebuild 1986
SHA256 66e711596a2b2dad696930abe7ccde73340e6742a09499a65795236fa1e425c0 heartbeat-1.2.5.ebuild 1986
-EBUILD heartbeat-2.0.7-r1.ebuild 3081 RMD160 f37fb7fe0ec3f3756d5c1b91c8d4a8f53659c510 SHA1 46aa5cb0c99d152c2948402c28231a5fb4ac8880 SHA256 20c61c7ab58e280bccb43b38ae431c3f46fcec85ca979cfe5a9c83d5f61b7d28
-MD5 2b6beb88a677967937913d0f90eb9e74 heartbeat-2.0.7-r1.ebuild 3081
-RMD160 f37fb7fe0ec3f3756d5c1b91c8d4a8f53659c510 heartbeat-2.0.7-r1.ebuild 3081
-SHA256 20c61c7ab58e280bccb43b38ae431c3f46fcec85ca979cfe5a9c83d5f61b7d28 heartbeat-2.0.7-r1.ebuild 3081
-MISC ChangeLog 9437 RMD160 986b84ce54968d901052b28d4ce0fd8153870b2f SHA1 3d98c996ca2f16e6de8a0b55abc44c9642f4308c SHA256 d3d80b55ae9ea88d0bcffdfa6771cbbee707a74e17278a8d008007cf2f71afbb
-MD5 607b972fcc2f07e5e10ccf40ee4a5b07 ChangeLog 9437
-RMD160 986b84ce54968d901052b28d4ce0fd8153870b2f ChangeLog 9437
-SHA256 d3d80b55ae9ea88d0bcffdfa6771cbbee707a74e17278a8d008007cf2f71afbb ChangeLog 9437
+EBUILD heartbeat-2.0.7-r1.ebuild 2974 RMD160 fd1d23ef5ffd94be642569fb8daaaa8b327ab2c6 SHA1 fb459abad2b5d90abf25462d5b59484f3570ba5b SHA256 b15613b71a255ca99355549332fefb53faac9ade794de2e4fb15d31ece6bcb13
+MD5 ad8ef101825b35126e9f8db18c85d747 heartbeat-2.0.7-r1.ebuild 2974
+RMD160 fd1d23ef5ffd94be642569fb8daaaa8b327ab2c6 heartbeat-2.0.7-r1.ebuild 2974
+SHA256 b15613b71a255ca99355549332fefb53faac9ade794de2e4fb15d31ece6bcb13 heartbeat-2.0.7-r1.ebuild 2974
+EBUILD heartbeat-2.0.7-r2.ebuild 3080 RMD160 3d80126a25239a5b9a30adf6a6aa860ac6b35ab1 SHA1 ac6868329e4d9319a280c215eb1b465f7e4326fd SHA256 bb04177af240f6ba68fe9adc02e702ed94c2e40c4c66198b28c3708f2c17acb3
+MD5 a240e0dddeb18deccf74143ddbb0e0c7 heartbeat-2.0.7-r2.ebuild 3080
+RMD160 3d80126a25239a5b9a30adf6a6aa860ac6b35ab1 heartbeat-2.0.7-r2.ebuild 3080
+SHA256 bb04177af240f6ba68fe9adc02e702ed94c2e40c4c66198b28c3708f2c17acb3 heartbeat-2.0.7-r2.ebuild 3080
+MISC ChangeLog 9713 RMD160 050a9c0f4f77151c93e2d56efe8e7d18b8a3fe2b SHA1 09e61f2b01a168b8f2aa271a168f34d9af8a6320 SHA256 b08395bbdcf00b445799706b535c54a5e0bf743f7da07af7b9cf36327a037a3d
+MD5 c588f39cab3e47c2cd385e72eecc497c ChangeLog 9713
+RMD160 050a9c0f4f77151c93e2d56efe8e7d18b8a3fe2b ChangeLog 9713
+SHA256 b08395bbdcf00b445799706b535c54a5e0bf743f7da07af7b9cf36327a037a3d ChangeLog 9713
MISC metadata.xml 339 RMD160 503ff4e79821bcf9851a8a6f8df0d43b3be8aa99 SHA1 7af6b38347db8330de0f27dbe2677156b524ebf9 SHA256 bb453c6b308cf1dfcbd818320ea43b654620a2b28dc24296c35367d803062635
MD5 469a4f6cad0c54b4faed31a2852af816 metadata.xml 339
RMD160 503ff4e79821bcf9851a8a6f8df0d43b3be8aa99 metadata.xml 339
@@ -29,10 +37,13 @@ SHA256 931bb676e4aaa9426fadcc6cea6f67a3ea9f0d9d2737abb80e89eceb9bacca04 files/di
MD5 730e170420e55cc6abbb746fb0f0ae14 files/digest-heartbeat-2.0.7-r1 250
RMD160 c33c56e13bd882781b92ac96f8a8d4fff191208e files/digest-heartbeat-2.0.7-r1 250
SHA256 4e28f3c92fda41c864ef7aaa4d6b540a751f22135d21ae4be00a89cf5c57425d files/digest-heartbeat-2.0.7-r1 250
+MD5 730e170420e55cc6abbb746fb0f0ae14 files/digest-heartbeat-2.0.7-r2 250
+RMD160 c33c56e13bd882781b92ac96f8a8d4fff191208e files/digest-heartbeat-2.0.7-r2 250
+SHA256 4e28f3c92fda41c864ef7aaa4d6b540a751f22135d21ae4be00a89cf5c57425d files/digest-heartbeat-2.0.7-r2 250
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.4 (GNU/Linux)
-iD8DBQFFDd3QgMUyd/cdjWsRAhj4AJwIfrfxubF8r4BiT0ZQ+aRpW+/yNgCeO8L+
-HqsAloIZ2FciSBd/3amtK/E=
-=6jKf
+iD8DBQFFDeAFgMUyd/cdjWsRAg0+AJ4t6rywwlqpOPDDpQl1pOzsbIr6CgCbBmbU
+Uoz0RPPESTOPBzExwQr6pm4=
+=R+GV
-----END PGP SIGNATURE-----
diff --git a/sys-cluster/heartbeat/files/digest-heartbeat-2.0.7-r2 b/sys-cluster/heartbeat/files/digest-heartbeat-2.0.7-r2
new file mode 100644
index 000000000000..8ff7ae56cec2
--- /dev/null
+++ b/sys-cluster/heartbeat/files/digest-heartbeat-2.0.7-r2
@@ -0,0 +1,3 @@
+MD5 41233e5097c42341bf2162806d4cb99c heartbeat-2.0.7.tar.gz 3327126
+RMD160 8fe70e64fc6714fef4e501ae0b240d870a51cf75 heartbeat-2.0.7.tar.gz 3327126
+SHA256 008214f51fd0c49e168d1bb262cb5c967bc166f99d0c8ff3a2623c8ba51a0ab3 heartbeat-2.0.7.tar.gz 3327126
diff --git a/sys-cluster/heartbeat/files/heartbeat-2.0.7-update-resources-failcount.patch b/sys-cluster/heartbeat/files/heartbeat-2.0.7-update-resources-failcount.patch
new file mode 100644
index 000000000000..cd1e563bac53
--- /dev/null
+++ b/sys-cluster/heartbeat/files/heartbeat-2.0.7-update-resources-failcount.patch
@@ -0,0 +1,223 @@
+--- a/crm/tengine/events.c Wed Sep 06 11:40:40 2006 +0200
++++ b/crm/tengine/events.c Tue Sep 12 18:17:10 2006 +0200
+@@ -198,51 +198,81 @@ extract_event(crm_data_t *msg)
+ }
+
+ static void
+-update_failcount(crm_action_t *action, int rc)
+-{
+- crm_data_t *rsc = NULL;
++update_failcount(crm_data_t *event, const char *event_node, int rc)
++{
+ char *attr_name = NULL;
+
+- const char *task = NULL;
+- const char *rsc_id = NULL;
+- const char *on_node = NULL;
+- const char *on_uuid = NULL;
+- const char *interval = NULL;
++ char *task = NULL;
++ char *rsc_id = NULL;
++ const char *on_node = event_node;
++ const char *on_uuid = event_node;
++ int interval = 0;
+
+ if(rc == 99) {
+ /* this is an internal code for "we're busy, try again" */
+ return;
+ }
+
+- interval = g_hash_table_lookup(
+- action->params, crm_meta_name("interval"));
+- if(interval == NULL) {
+- return;
+- }
+-
+- CRM_CHECK(action->xml != NULL, return);
+-
+- rsc = find_xml_node(action->xml, XML_CIB_TAG_RESOURCE, TRUE);
+- CRM_CHECK(rsc != NULL, return);
+- rsc_id = ID(rsc);
+- CRM_CHECK(rsc_id != NULL, return);
+-
+- task = crm_element_value(action->xml, XML_LRM_ATTR_TASK);
+- on_node = crm_element_value(action->xml, XML_LRM_ATTR_TARGET);
+- on_uuid = crm_element_value(action->xml, XML_LRM_ATTR_TARGET_UUID);
+-
+- CRM_CHECK(task != NULL, return);
+ CRM_CHECK(on_uuid != NULL, return);
+- CRM_CHECK(on_node != NULL, return);
+-
+- attr_name = crm_concat("fail-count", rsc_id, '-');
+- crm_warn("Updating failcount for %s on %s after failed %s: rc=%d",
+- rsc_id, on_node, task, rc);
+-
+- update_attr(te_cib_conn, cib_none, XML_CIB_TAG_STATUS,
+- on_uuid, NULL,NULL, attr_name, XML_NVPAIR_ATTR_VALUE"++");
+-
+- crm_free(attr_name);
++
++ CRM_CHECK(parse_op_key(ID(event), &rsc_id, &task, &interval),return);
++ CRM_CHECK(task != NULL, crm_free(rsc_id); return);
++ CRM_CHECK(rsc_id != NULL, crm_free(task); return);
++ /* CRM_CHECK(on_node != NULL, return); */
++
++ if(interval > 0) {
++ attr_name = crm_concat("fail-count", rsc_id, '-');
++ crm_warn("Updating failcount for %s on %s after failed %s: rc=%d",
++ rsc_id, on_node, task, rc);
++
++ update_attr(te_cib_conn, cib_none, XML_CIB_TAG_STATUS,
++ on_uuid, NULL,NULL, attr_name,
++ XML_NVPAIR_ATTR_VALUE"++");
++ crm_free(attr_name);
++ }
++
++ crm_free(rsc_id);
++ crm_free(task);
++}
++
++static int
++status_from_rc(crm_action_t *action, int orig_status, int rc)
++{
++ int status = orig_status;
++ const char *target_rc_s = g_hash_table_lookup(
++ action->params, crm_meta_name(XML_ATTR_TE_TARGET_RC));
++
++ if(target_rc_s != NULL) {
++ int target_rc = 0;
++ crm_debug_2("Target rc: %s vs. %d", target_rc_s, rc);
++ target_rc = crm_parse_int(target_rc_s, NULL);
++ if(target_rc == rc) {
++ crm_debug_2("Target rc: == %d", rc);
++ if(status != LRM_OP_DONE) {
++ crm_debug_2("Re-mapping op status to"
++ " LRM_OP_DONE for rc=%d", rc);
++ status = LRM_OP_DONE;
++ }
++ } else {
++ crm_debug_2("Target rc: != %d", rc);
++ if(status != LRM_OP_ERROR) {
++ crm_info("Re-mapping op status to"
++ " LRM_OP_ERROR for rc=%d", rc);
++ status = LRM_OP_ERROR;
++ }
++ }
++ }
++
++ /* 99 is the code we use for direct nack's */
++ if(rc != 99 && status != LRM_OP_DONE) {
++ const char *task, *uname;
++ task = crm_element_value(action->xml, XML_LRM_ATTR_TASK);
++ uname = crm_element_value(action->xml, XML_LRM_ATTR_TARGET);
++ crm_warn("Action %s on %s failed (target: %s vs. rc: %d): %s",
++ task, uname, target_rc_s, rc, op_status2text(status));
++ }
++
++ return status;
+ }
+
+ /*
+@@ -255,9 +285,6 @@ match_graph_event(
+ match_graph_event(
+ crm_action_t *action, crm_data_t *event, const char *event_node)
+ {
+- int log_level_fail = LOG_ERR;
+- int target_rc = 0;
+- const char *target_rc_s = NULL;
+ const char *allow_fail = NULL;
+ const char *this_action = NULL;
+ const char *this_node = NULL;
+@@ -296,15 +323,19 @@ match_graph_event(
+ crm_debug_2("Action %d : Node mismatch %s (%s) vs. %s",
+ action->id, this_node, this_uname, event_node);
+ return -1;
+-
+- }
+-
++ }
++
+ crm_debug_2("Matched action (%d) %s", action->id, this_event);
+
+ CRM_CHECK(decode_transition_magic(
+ magic, &update_te_uuid,
+ &transition_i, &op_status_i, &op_rc_i), return -2);
+
++ op_status_i = status_from_rc(action, op_status_i, op_rc_i);
++ if(op_status_i != LRM_OP_DONE) {
++ update_failcount(event, event_node, op_rc_i);
++ }
++
+ if(transition_i == -1) {
+ /* we never expect these - recompute */
+ crm_err("Detected action %s initiated outside of a transition",
+@@ -334,28 +365,6 @@ match_graph_event(
+ /* stop this event's timer if it had one */
+ stop_te_timer(action->timer);
+ action->confirmed = TRUE;
+-
+- target_rc_s = g_hash_table_lookup(
+- action->params,crm_meta_name(XML_ATTR_TE_TARGET_RC));
+- if(target_rc_s != NULL) {
+- crm_debug_2("Target rc: %s vs. %d", target_rc_s, op_rc_i);
+- target_rc = crm_parse_int(target_rc_s, NULL);
+- if(target_rc == op_rc_i) {
+- crm_debug_2("Target rc: == %d", op_rc_i);
+- if(op_status_i != LRM_OP_DONE) {
+- crm_debug_2("Re-mapping op status to"
+- " LRM_OP_DONE for %s",update_event);
+- op_status_i = LRM_OP_DONE;
+- }
+- } else {
+- crm_debug_2("Target rc: != %d", op_rc_i);
+- if(op_status_i != LRM_OP_ERROR) {
+- crm_info("Re-mapping op status to"
+- " LRM_OP_ERROR for %s", update_event);
+- op_status_i = LRM_OP_ERROR;
+- }
+- }
+- }
+
+ /* Process OP status */
+ switch(op_status_i) {
+@@ -371,18 +380,9 @@ match_graph_event(
+ case LRM_OP_DONE:
+ break;
+ case LRM_OP_ERROR:
+- /* This is the code we use for direct nack's */
+- if(op_rc_i == 99) {
+- log_level_fail = LOG_WARNING;
+- }
+- /* fall through */
+ case LRM_OP_TIMEOUT:
+ case LRM_OP_NOTSUPPORTED:
+ action->failed = TRUE;
+- crm_log_maybe(log_level_fail,
+- "Action %s on %s failed (target: %d vs. rc: %d): %s",
+- update_event, this_uname, target_rc,
+- op_rc_i, op_status2text(op_status_i));
+ break;
+ case LRM_OP_CANCELLED:
+ /* do nothing?? */
+@@ -405,10 +405,6 @@ match_graph_event(
+ }
+
+ if(action->failed) {
+- /* ignore probes */
+- if(target_rc != EXECRA_NOT_RUNNING) {
+- update_failcount(action, op_rc_i);
+- }
+ abort_transition(action->synapse->priority+1,
+ tg_restart, "Event failed", event);
+
+@@ -544,6 +540,9 @@ process_graph_event(crm_data_t *event, c
+ /* unexpected event, trigger a pe-recompute */
+ /* possibly do this only for certain types of actions */
+ crm_warn("Event not found.");
++ if(rc != EXECRA_OK) {
++ update_failcount(event, event_node, rc);
++ }
+ crm_log_xml_info(event, "match:not-found");
+ abort_transition(INFINITY, tg_restart, "Unexpected event", event);
+ return;
+
diff --git a/sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild b/sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild
index d5c371523e74..8290397ae031 100644
--- a/sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild
+++ b/sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild,v 1.1 2006/08/24 16:24:28 xmerlin Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/heartbeat/heartbeat-2.0.7-r1.ebuild,v 1.2 2006/09/17 22:48:05 xmerlin Exp $
inherit flag-o-matic eutils
@@ -43,12 +43,6 @@ DEPEND="
)
"
-src_unpack() {
- unpack ${A}
- cd ${S}
- #epatch ${FILESDIR}/${PN}-2.0.4-fix-local-DOS-attack.patch || die
-}
-
src_compile() {
append-ldflags $(bindnow-flags)
diff --git a/sys-cluster/heartbeat/heartbeat-2.0.7-r2.ebuild b/sys-cluster/heartbeat/heartbeat-2.0.7-r2.ebuild
new file mode 100644
index 000000000000..480c3b1f11e5
--- /dev/null
+++ b/sys-cluster/heartbeat/heartbeat-2.0.7-r2.ebuild
@@ -0,0 +1,119 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-cluster/heartbeat/heartbeat-2.0.7-r2.ebuild,v 1.1 2006/09/17 22:48:05 xmerlin Exp $
+
+inherit flag-o-matic eutils
+
+DESCRIPTION="Heartbeat high availability cluster manager"
+HOMEPAGE="http://www.linux-ha.org"
+SRC_URI="http://www.linux-ha.org/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 -mips ~ppc -s390 ~x86"
+IUSE="ldirectord doc snmp management"
+
+DEPEND="
+ =dev-libs/glib-2*
+ net-libs/libnet
+ dev-util/pkgconfig
+ >=dev-lang/perl-5.8.8
+ net-misc/iputils
+ virtual/ssh
+ net-libs/gnutls
+ ldirectord? ( sys-cluster/ipvsadm
+ dev-perl/Net-DNS
+ dev-perl/libwww-perl
+ dev-perl/perl-ldap
+ perl-core/libnet
+ dev-perl/Crypt-SSLeay
+ dev-perl/HTML-Parser
+ dev-perl/perl-ldap
+ dev-perl/Mail-IMAPClient
+ dev-perl/Mail-POP3Client
+ dev-perl/MailTools
+ )
+ snmp? ( net-analyzer/net-snmp )
+ net-misc/telnet-bsd
+ dev-lang/swig
+ management? (
+ >=dev-lang/python-2.4
+ >=dev-python/pygtk-2.4
+ >=sys-libs/pam-0.78-r3
+ )
+ "
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ epatch ${FILESDIR}/${P}-update-resources-failcount.patch || die
+}
+
+src_compile() {
+ append-ldflags $(bindnow-flags)
+
+ ./configure --prefix=/usr \
+ --mandir=/usr/share/man \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ --with-group-name=cluster \
+ --with-group-id=65 \
+ --with-ccmuser-name=cluster \
+ --with-ccmuser-id=65 \
+ --enable-checkpointd \
+ --enable-crm \
+ --enable-lrm \
+ $(use_enable management mgmt) \
+ || die
+ emake -j 1 || die "compile problem"
+}
+
+pkg_preinst() {
+ # check for cluster group, if it doesn't exist make it
+ if ! grep -q cluster.*65 /etc/group ; then
+ groupadd -g 65 cluster
+ fi
+ # check for cluster user, if it doesn't exist make it
+ if ! grep -q cluster.*65 /etc/passwd ; then
+ useradd -u 65 -g cluster -s /dev/null -d /var/lib/heartbeat cluster
+ fi
+}
+
+src_install() {
+ make DESTDIR=${D} install || die
+
+ # heartbeat modules need these dirs
+ #keepdir /var/lib/heartbeat/ckpt /var/lib/heartbeat/ccm /var/lib/heartbeat
+
+ keepdir /var/lib/heartbeat/crm /var/lib/heartbeat/lrm /var/lib/heartbeat/fencing
+ keepdir /var/lib/heartbeat/cores/cluster /var/lib/heartbeat/cores/root /var/lib/heartbeat/cores/nobody
+
+ keepdir /var/run/heartbeat/ccm /var/run/heartbeat/crm
+
+ keepdir /etc/ha.d/conf
+
+ dosym /usr/sbin/ldirectord /etc/ha.d/resource.d/ldirectord || die
+
+ if use management ; then
+ keepdir /var/lib/heartbeat/mgmt
+ fi
+
+ # if ! USE="ldirectord" then don't install it
+ if ! use ldirectord ; then
+ rm ${D}/etc/init.d/ldirectord
+ rm ${D}/etc/logrotate.d/ldirectord
+ rm ${D}/etc/ha.d/resource.d/ldirectord
+ rm ${D}/usr/share/man/man8/supervise-ldirectord-config.8
+ rm ${D}/usr/share/man/man8/ldirectord.8
+ rm ${D}/usr/sbin/ldirectord
+ rm ${D}/usr/sbin/supervise-ldirectord-config
+ fi
+
+ exeinto /etc/init.d
+ newexe ${FILESDIR}/heartbeat-init heartbeat
+
+ dodoc ldirectord/ldirectord.cf doc/*.cf doc/haresources doc/authkeys || die
+ if use doc ; then
+ dodoc README doc/*.txt doc/AUTHORS doc/COPYING || die
+ fi
+}