From: rmccabe@sourceware.org <rmccabe@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] conga/luci/site/luci/Extensions/ClusterModel M ...
Date: 22 Jan 2009 20:35:29 -0000 [thread overview]
Message-ID: <20090122203529.13061.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: conga
Branch: RHEL5
Changes by: rmccabe at sourceware.org 2009-01-22 20:35:28
Modified files:
luci/site/luci/Extensions/ClusterModel: ModelBuilder.py
Log message:
fix bz467464
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/ClusterModel/ModelBuilder.py.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.1.4.9&r2=1.1.4.10
--- conga/luci/site/luci/Extensions/ClusterModel/ModelBuilder.py 2008/08/04 21:49:31 1.1.4.9
+++ conga/luci/site/luci/Extensions/ClusterModel/ModelBuilder.py 2009/01/22 20:35:27 1.1.4.10
@@ -1,4 +1,4 @@
-# Copyright (C) 2006-2008 Red Hat, Inc.
+# Copyright (C) 2006-2009 Red Hat, Inc.
#
# This program is free software; you can redistribute
# it and/or modify it under the terms of version 2 of the
@@ -1126,22 +1126,26 @@
return True
def check_two_node(self):
- if self.getLockType() == DLM_TYPE and self.quorumd_ptr is None:
- clusternodes_count = len(self.clusternodes_ptr.getChildren())
+ if self.getLockType() == DLM_TYPE:
+ clusternodes_count = len(self.getNodes())
#Make certain that there is a cman tag in the file
#If missing, it will not hurt to add it here
if self.CMAN_ptr is None:
cman = Cman()
self.cluster_ptr.addChild(cman)
self.CMAN_ptr = cman
+
if clusternodes_count == 2:
- self.CMAN_ptr.addAttribute('two_node', '1')
- self.CMAN_ptr.addAttribute('expected_votes', '1')
+ if not self.isQuorumd():
+ self.CMAN_ptr.addAttribute('two_node', '1')
+ self.CMAN_ptr.addAttribute('expected_votes', '1')
+ else:
+ self.CMAN_ptr.removeAttribute('two_node')
+ if self.CMAN_ptr.getAttribute('expected_votes') in ('0', '1'):
+ self.CMAN_ptr.removeAttribute('expected_votes')
else:
- if self.CMAN_ptr.getAttribute('expected_votes') in ('0', '1'):
- self.CMAN_ptr.removeAttribute('expected_votes')
self.CMAN_ptr.removeAttribute('two_node')
-
+
def dual_power_fence_check(self):
# if 2 or more power controllers reside in the same fence level,
# duplicate entries must be made for every controller with an
next reply other threads:[~2009-01-22 20:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-22 20:35 rmccabe [this message]
-- strict thread matches above, loose matches on Subject: below --
2009-01-22 21:31 [Cluster-devel] conga/luci/site/luci/Extensions/ClusterModel M rmccabe
2007-09-11 19:04 rmccabe
2007-08-28 16:57 rmccabe
2007-07-26 5:57 rmccabe
2007-05-08 21:31 rmccabe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20090122203529.13061.qmail@sourceware.org \
--to=rmccabe@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.