Blob Blame History Raw
From 3c4651ba655a7346f4e67335229b76ed24d1c917 Mon Sep 17 00:00:00 2001
From: Marek 'marx' Grac <mgrac@redhat.com>
Date: Wed, 5 Aug 2015 15:29:12 +0200
Subject: [PATCH 3/4] fencing: Fix XML metadata and their creation for
 'port_as_ip'

---
 fence/agents/dummy/fence_dummy.py      |  1 +
 fence/agents/lib/fencing.py.py         |  5 +++-
 tests/data/metadata/fence_alom.xml     |  4 +--
 tests/data/metadata/fence_amt.xml      |  4 +--
 tests/data/metadata/fence_drac.xml     |  4 +--
 tests/data/metadata/fence_dummy.xml    | 10 -------
 tests/data/metadata/fence_idrac.xml    |  4 +--
 tests/data/metadata/fence_ilo.xml      |  4 +--
 tests/data/metadata/fence_ilo2.xml     |  4 +--
 tests/data/metadata/fence_ilo3.xml     |  4 +--
 tests/data/metadata/fence_ilo3_ssh.xml |  4 +--
 tests/data/metadata/fence_ilo4.xml     |  4 +--
 tests/data/metadata/fence_ilo4_ssh.xml |  4 +--
 tests/data/metadata/fence_ilo_mp.xml   |  4 +--
 tests/data/metadata/fence_ilo_ssh.xml  |  4 +--
 tests/data/metadata/fence_imm.xml      |  4 +--
 tests/data/metadata/fence_ipmilan.xml  |  4 +--
 tests/data/metadata/fence_mpath.xml    | 54 ++++++++++++++--------------------
 tests/data/metadata/fence_rsa.xml      |  4 +--
 tests/data/metadata/fence_rsb.xml      |  4 +--
 20 files changed, 59 insertions(+), 75 deletions(-)

diff --git a/fence/agents/dummy/fence_dummy.py b/fence/agents/dummy/fence_dummy.py
index 9c4c5f1..7d6bd06 100644
--- a/fence/agents/dummy/fence_dummy.py
+++ b/fence/agents/dummy/fence_dummy.py
@@ -115,6 +115,7 @@ def main():
 	if (pinput.has_key("--type") and pinput["--type"] == "file") or (pinput.has_key("--type") == False):
 		# hack to have fence agents that require ports 'fail' and one that do not 'file'
 		device_opt.remove("port")
+		device_opt.remove("separator")
 
 	options = check_input(device_opt, process_input(device_opt))
 
diff --git a/fence/agents/lib/fencing.py.py b/fence/agents/lib/fencing.py.py
index f14d7e0..8b14cf2 100644
--- a/fence/agents/lib/fencing.py.py
+++ b/fence/agents/lib/fencing.py.py
@@ -463,7 +463,10 @@ def add_dependency_options(options):
 		if DEPENDENCY_OPT.has_key(opt):
 			added_opt.extend([y for y in DEPENDENCY_OPT[opt] if options.count(y) == 0])
 
-	if not "port" in (options + added_opt) and not "nodename" in (options + added_opt):
+	if not "port" in (options + added_opt) and \
+		not "nodename" in (options + added_opt) and \
+		"ipaddr" in (options + added_opt):
+
 		added_opt.append("port_as_ip")
 		all_opt["port"]["help"] = "-n, --plug=[ip]                IP address or hostname of fencing device " \
 			"(together with --port-as-ip)"
diff --git a/tests/data/metadata/fence_alom.xml b/tests/data/metadata/fence_alom.xml
index dfbe431..f7e2f36 100644
--- a/tests/data/metadata/fence_alom.xml
+++ b/tests/data/metadata/fence_alom.xml
@@ -8,12 +8,12 @@
 		<content type="string" default="22"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_amt.xml b/tests/data/metadata/fence_amt.xml
index 17e38fc..61b39f5 100644
--- a/tests/data/metadata/fence_amt.xml
+++ b/tests/data/metadata/fence_amt.xml
@@ -8,7 +8,7 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -18,7 +18,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_drac.xml b/tests/data/metadata/fence_drac.xml
index 37697f7..1e94dbc 100644
--- a/tests/data/metadata/fence_drac.xml
+++ b/tests/data/metadata/fence_drac.xml
@@ -8,7 +8,7 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -23,7 +23,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_dummy.xml b/tests/data/metadata/fence_dummy.xml
index eb31244..07ad2cc 100644
--- a/tests/data/metadata/fence_dummy.xml
+++ b/tests/data/metadata/fence_dummy.xml
@@ -3,11 +3,6 @@
 <longdesc>fence_dummy</longdesc>
 <vendor-url>http://www.example.com</vendor-url>
 <parameters>
-	<parameter name="port" unique="0" required="1">
-		<getopt mixed="-n, --plug=[ip]" />
-		<content type="string"  />
-		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
-	</parameter>
 	<parameter name="status_file" unique="0" required="0">
 		<getopt mixed="--status-file=[file]" />
 		<content type="string" default="/tmp/fence_dummy.status"  />
@@ -63,11 +58,6 @@
 		<content type="string" default="20"  />
 		<shortdesc lang="en">Test X seconds for status change after ON/OFF</shortdesc>
 	</parameter>
-	<parameter name="port_as_ip" unique="0" required="0">
-		<getopt mixed="--port-as-ip" />
-		<content type="boolean"  />
-		<shortdesc lang="en">Make "port/plug" to be an alias to IP address</shortdesc>
-	</parameter>
 	<parameter name="delay" unique="0" required="0">
 		<getopt mixed="--delay=[seconds]" />
 		<content type="string" default="0"  />
diff --git a/tests/data/metadata/fence_idrac.xml b/tests/data/metadata/fence_idrac.xml
index b742161..0aced2a 100644
--- a/tests/data/metadata/fence_idrac.xml
+++ b/tests/data/metadata/fence_idrac.xml
@@ -12,7 +12,7 @@
 		<content type="string" default="623"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -22,7 +22,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_ilo.xml b/tests/data/metadata/fence_ilo.xml
index 891b7f1..2eead1e 100644
--- a/tests/data/metadata/fence_ilo.xml
+++ b/tests/data/metadata/fence_ilo.xml
@@ -34,12 +34,12 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_ilo2.xml b/tests/data/metadata/fence_ilo2.xml
index 7ff697f..3be62f1 100644
--- a/tests/data/metadata/fence_ilo2.xml
+++ b/tests/data/metadata/fence_ilo2.xml
@@ -34,12 +34,12 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_ilo3.xml b/tests/data/metadata/fence_ilo3.xml
index 05fd01c..67e869b 100644
--- a/tests/data/metadata/fence_ilo3.xml
+++ b/tests/data/metadata/fence_ilo3.xml
@@ -12,7 +12,7 @@
 		<content type="string" default="623"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -22,7 +22,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_ilo3_ssh.xml b/tests/data/metadata/fence_ilo3_ssh.xml
index ebdae65..8268daf 100644
--- a/tests/data/metadata/fence_ilo3_ssh.xml
+++ b/tests/data/metadata/fence_ilo3_ssh.xml
@@ -10,12 +10,12 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_ilo4.xml b/tests/data/metadata/fence_ilo4.xml
index 4f29073..b7dd31a 100644
--- a/tests/data/metadata/fence_ilo4.xml
+++ b/tests/data/metadata/fence_ilo4.xml
@@ -12,7 +12,7 @@
 		<content type="string" default="623"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -22,7 +22,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_ilo4_ssh.xml b/tests/data/metadata/fence_ilo4_ssh.xml
index 197d627..4ca2397 100644
--- a/tests/data/metadata/fence_ilo4_ssh.xml
+++ b/tests/data/metadata/fence_ilo4_ssh.xml
@@ -10,12 +10,12 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_ilo_mp.xml b/tests/data/metadata/fence_ilo_mp.xml
index d2396e9..14fc3c8 100644
--- a/tests/data/metadata/fence_ilo_mp.xml
+++ b/tests/data/metadata/fence_ilo_mp.xml
@@ -8,12 +8,12 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_ilo_ssh.xml b/tests/data/metadata/fence_ilo_ssh.xml
index 1d79308..4448d2d 100644
--- a/tests/data/metadata/fence_ilo_ssh.xml
+++ b/tests/data/metadata/fence_ilo_ssh.xml
@@ -10,12 +10,12 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_imm.xml b/tests/data/metadata/fence_imm.xml
index 0302f84..0e7588d 100644
--- a/tests/data/metadata/fence_imm.xml
+++ b/tests/data/metadata/fence_imm.xml
@@ -12,7 +12,7 @@
 		<content type="string" default="623"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -22,7 +22,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_ipmilan.xml b/tests/data/metadata/fence_ipmilan.xml
index 4ed67eb..443365c 100644
--- a/tests/data/metadata/fence_ipmilan.xml
+++ b/tests/data/metadata/fence_ipmilan.xml
@@ -12,7 +12,7 @@
 		<content type="string" default="623"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
@@ -22,7 +22,7 @@
 		<content type="boolean"  />
 		<shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
diff --git a/tests/data/metadata/fence_mpath.xml b/tests/data/metadata/fence_mpath.xml
index d3de9d5..c578f7a 100644
--- a/tests/data/metadata/fence_mpath.xml
+++ b/tests/data/metadata/fence_mpath.xml
@@ -4,25 +4,20 @@
 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="port" unique="0" required="1">
-		<getopt mixed="-n, --plug=[ip]" />
+	<parameter name="devices" unique="0" required="0">
+		<getopt mixed="-d, --devices=[devices]" />
 		<content type="string"  />
-		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</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>
+		<shortdesc lang="en">List of devices to use for current operation. Devices can be comma-separated list of device-mapper multipath devices (eg. /dev/dm-3). Each device must support SCSI-3 persistent reservations.</shortdesc>
 	</parameter>
 	<parameter name="key" unique="0" required="1">
 		<getopt mixed="-k, --key=[key]" />
 		<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="devices" unique="0" required="0">
-		<getopt mixed="-d, --devices=[devices]" />
-		<content type="string"  />
-		<shortdesc lang="en">List of devices to use for current operation. Devices can be comma-separated list of device-mapper multipath devices (eg. /dev/dm-3). Each device must support SCSI-3 persistent reservations.</shortdesc>
+	<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" />
@@ -44,31 +39,11 @@ The fence_mpath agent works by having an unique key for each pair of node and de
 		<content type="boolean"  />
 		<shortdesc lang="en">Display help and exit</shortdesc>
 	</parameter>
-	<parameter name="power_wait" unique="0" required="0">
-		<getopt mixed="--power-wait=[seconds]" />
-		<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>
-	<parameter name="port_as_ip" unique="0" required="0">
-		<getopt mixed="--port-as-ip" />
-		<content type="boolean"  />
-		<shortdesc lang="en">Make "port/plug" to be an alias to IP address</shortdesc>
-	</parameter>
 	<parameter name="delay" unique="0" required="0">
 		<getopt mixed="--delay=[seconds]" />
 		<content type="string" default="0"  />
 		<shortdesc lang="en">Wait X seconds before fencing is started</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>
 	<parameter name="shell_timeout" unique="0" required="0">
 		<getopt mixed="--shell-timeout=[seconds]" />
 		<content type="string" default="3"  />
@@ -84,6 +59,21 @@ The fence_mpath agent works by having an unique key for each pair of node and de
 		<content type="string" default="20"  />
 		<shortdesc lang="en">Test X seconds for status change after ON/OFF</shortdesc>
 	</parameter>
+	<parameter name="power_wait" unique="0" required="0">
+		<getopt mixed="--power-wait=[seconds]" />
+		<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>
+	<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="retry_on" unique="0" required="0">
 		<getopt mixed="--retry-on=[attempts]" />
 		<content type="string" default="1"  />
diff --git a/tests/data/metadata/fence_rsa.xml b/tests/data/metadata/fence_rsa.xml
index 3f3a336..2981f04 100644
--- a/tests/data/metadata/fence_rsa.xml
+++ b/tests/data/metadata/fence_rsa.xml
@@ -8,12 +8,12 @@
 		<content type="string" default="23"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
diff --git a/tests/data/metadata/fence_rsb.xml b/tests/data/metadata/fence_rsb.xml
index 36b9cdb..c27ebe4 100644
--- a/tests/data/metadata/fence_rsb.xml
+++ b/tests/data/metadata/fence_rsb.xml
@@ -8,12 +8,12 @@
 		<content type="string" default="3172"  />
 		<shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc>
 	</parameter>
-	<parameter name="ipaddr" unique="0" required="1">
+	<parameter name="ipaddr" unique="0" required="0">
 		<getopt mixed="-a, --ip=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP Address or Hostname</shortdesc>
 	</parameter>
-	<parameter name="port" unique="0" required="1">
+	<parameter name="port" unique="0" required="0">
 		<getopt mixed="-n, --plug=[ip]" />
 		<content type="string"  />
 		<shortdesc lang="en">IP address or hostname of fencing device (together with --port-as-ip)</shortdesc>
-- 
1.9.3