Gitweb:
http://git.fedorahosted.org/git/?p=fence-agents.git;a=commitdiff;h=8bd605...
Commit: 8bd6050dccf93621066c5ae5cb8ae1953c331e63
Parent: df5bcaaddc8fcb3481c0d9389417f069dc7c7674
Author: Marek 'marx' Grac <mgrac(a)redhat.com>
AuthorDate: Mon Dec 1 20:39:47 2014 +0100
Committer: Marek 'marx' Grac <mgrac(a)redhat.com>
CommitterDate: Mon Dec 1 20:39:47 2014 +0100
fence_mpath: Do not run regression test on store_path value
This is not possible because unlike the other paths this one
is dependant on ./configure --prefix XXX. With this patch,
line with value will be removed.
---
make/agentpycheck.mk | 5 ++-
tests/data/metadata/fence_mpath.xml | 46 +++++++++++++++++++----------------
2 files changed, 28 insertions(+), 23 deletions(-)
diff --git a/make/agentpycheck.mk b/make/agentpycheck.mk
index 63cb9da..090116b 100644
--- a/make/agentpycheck.mk
+++ b/make/agentpycheck.mk
@@ -1,18 +1,19 @@
TEMPFILE:=$(shell mktemp)
#DATADIR:=$(abs_top_builddir)/tests/data/metadata
DATADIR:=$(abs_top_srcdir)/tests/data/metadata
+AWK='BEGIN {store=-1} /name=\"store_path\"/ {store=2} {if (store!=0)
{print}; store--}'
check: $(TARGET:%=xml-check.%) $(SYMTARGET:%=xml-check.%) $(TARGET:%=delay-check.%)
xml-check.%: %
$(eval INPUT=$(subst xml-check.,,$@))
- PYTHONPATH=$(abs_srcdir)/../lib:$(abs_builddir)/../lib python ./$(INPUT) -o metadata
> $(TEMPFILE)
+ PYTHONPATH=$(abs_srcdir)/../lib:$(abs_builddir)/../lib python ./$(INPUT) -o metadata |
awk $(AWK) > $(TEMPFILE)
diff $(TEMPFILE) $(DATADIR)/$(INPUT).xml
rm $(TEMPFILE)
xml-upload.%: %
$(eval INPUT=$(subst xml-upload.,,$@))
- PYTHONPATH=$(abs_srcdir)/../lib:$(abs_builddir)/../lib python ./$(INPUT) -o metadata
> $(DATADIR)/$(INPUT).xml
+ PYTHONPATH=$(abs_srcdir)/../lib:$(abs_builddir)/../lib python ./$(INPUT) -o metadata |
awk $(AWK) > $(DATADIR)/$(INPUT).xml
# If test will fail, rerun fence agents to show problems
delay-check.%: %
diff --git a/tests/data/metadata/fence_mpath.xml b/tests/data/metadata/fence_mpath.xml
index c62dd49..d76c66d 100644
--- a/tests/data/metadata/fence_mpath.xml
+++ b/tests/data/metadata/fence_mpath.xml
@@ -4,6 +4,11 @@
The fence_mpath agent works by having an unique key for each pair of node and device that
has to be set also in /etc/multipath.conf. Once registered, a single node will become the
reservation holder by creating a "write exclusive, registrants only" reservation
on the device(s). The result is that only registered nodes may write to the device(s).
When a node failure occurs, the fence_mpath agent will remove the key belonging to the
failed node from the device(s). The failed node will no longer be able to write to the
device(s). A manual reboot is required.</longdesc>
<
vendor-url>https://www.sourceware.org/dm/</vendor-url>
<parameters>
+ <parameter name="action" unique="0" required="1">
+ <getopt mixed="-o, --action=[action]" />
+ <content type="string" default="off" />
+ <shortdesc lang="en">Fencing Action</shortdesc>
+ </parameter>
<parameter name="devices" unique="0" required="0">
<getopt mixed="-d, --devices=[devices]" />
<content type="string" />
@@ -14,11 +19,6 @@ The fence_mpath agent works by having an unique key for each pair of
node and de
<content type="string" />
<shortdesc lang="en">Key to use for the current operation. This key
should be unique to a node and have to be written in /etc/multipath.conf. For the
"on" action, the key specifies the key use to register the local node. For the
"off" action, this key specifies the key to be removed from the
device(s).</shortdesc>
</parameter>
- <parameter name="action" unique="0" required="1">
- <getopt mixed="-o, --action=[action]" />
- <content type="string" default="off" />
- <shortdesc lang="en">Fencing Action</shortdesc>
- </parameter>
<parameter name="verbose" unique="0" required="0">
<getopt mixed="-v, --verbose" />
<content type="boolean" />
@@ -44,15 +44,15 @@ The fence_mpath agent works by having an unique key for each pair of
node and de
<content type="string" default="0" />
<shortdesc lang="en">Wait X seconds before fencing is
started</shortdesc>
</parameter>
- <parameter name="shell_timeout" unique="0"
required="0">
- <getopt mixed="--shell-timeout=[seconds]" />
- <content type="string" default="3" />
- <shortdesc lang="en">Wait X seconds for cmd prompt after issuing
command</shortdesc>
+ <parameter name="login_timeout" unique="0"
required="0">
+ <getopt mixed="--login-timeout=[seconds]" />
+ <content type="string" default="5" />
+ <shortdesc lang="en">Wait X seconds for cmd prompt after
login</shortdesc>
</parameter>
- <parameter name="store_path" unique="0"
required="0">
- <getopt mixed="--store-path=[path]" />
- <content type="string" default="/var/run/cluster" />
- <shortdesc lang="en">Path to directory where fence agent can store
information</shortdesc>
+ <parameter name="mpathpersist_path" unique="0"
required="0">
+ <getopt mixed="--mpathpersist-path=[path]" />
+ <content type="string" default="/usr/sbin/mpathpersist" />
+ <shortdesc lang="en">Path to mpathpersist binary</shortdesc>
</parameter>
<parameter name="power_timeout" unique="0"
required="0">
<getopt mixed="--power-timeout=[seconds]" />
@@ -64,15 +64,14 @@ The fence_mpath agent works by having an unique key for each pair of
node and de
<content type="string" default="0" />
<shortdesc lang="en">Wait X seconds after issuing
ON/OFF</shortdesc>
</parameter>
- <parameter name="login_timeout" unique="0"
required="0">
- <getopt mixed="--login-timeout=[seconds]" />
- <content type="string" default="5" />
- <shortdesc lang="en">Wait X seconds for cmd prompt after
login</shortdesc>
+ <parameter name="shell_timeout" unique="0"
required="0">
+ <getopt mixed="--shell-timeout=[seconds]" />
+ <content type="string" default="3" />
+ <shortdesc lang="en">Wait X seconds for cmd prompt after issuing
command</shortdesc>
</parameter>
- <parameter name="mpathpersist_path" unique="0"
required="0">
- <getopt mixed="--mpathpersist-path=[path]" />
- <content type="string" default="/usr/sbin/mpathpersist" />
- <shortdesc lang="en">Path to mpathpersist binary</shortdesc>
+ <parameter name="store_path" unique="0"
required="0">
+ <getopt mixed="--store-path=[path]" />
+ <shortdesc lang="en">Path to directory where fence agent can store
information</shortdesc>
</parameter>
<parameter name="retry_on" unique="0" required="0">
<getopt mixed="--retry-on=[attempts]" />
@@ -84,6 +83,11 @@ The fence_mpath agent works by having an unique key for each pair of
node and de
<content type="boolean" />
<shortdesc lang="en">Use sudo (without password) when calling 3rd party
sotfware.</shortdesc>
</parameter>
+ <parameter name="sudo_path" unique="0"
required="0">
+ <getopt mixed="--sudo-path=[path]" />
+ <content type="string" default="/usr/bin/sudo" />
+ <shortdesc lang="en">Path to sudo binary</shortdesc>
+ </parameter>
</parameters>
<actions>
<action name="on" on_target="1" automatic="1"/>