[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [Cluster-devel] [PATCH 1/3] fencing: new option --method



Hi Ondrej,

I have several comments:

* please include patches so they depends only on upstream or posted series (2/3 can depend on 1/3)
    [ e.g. problem with -EC_TOOL_FAIL ]

On 11/29/2013 05:32 PM, Ondrej Mular wrote:
Add new option method --method for cycle reboot

---
  fence/agents/lib/fencing.py.py | 80 ++++++++++++++++++++++++++++++------------
  1 file changed, 57 insertions(+), 23 deletions(-)

...
+def multi_reboot_cycle_fn(tn, options, reboot_cycle_fn):
+	success = False;
+	if options.has_key("--plugs"):
+		for plug in options["--plugs"]:
+			try:
+				options["--uuid"] = str(uuid.UUID(plug))
+			except ValueError:
+				pass
+			except KeyError:
+				pass
+			options["--plug"] = plug
+			plug_status = reboot_cycle_fn(tn, options)
+			if plug_status:
+				success = plug_status
+	else:
+		success = reboot_cycle_fn(tn, options)
+	return success
Although we support multiple ports (--plugs) it is possible only when using 'method=offon' because otherwise we will just reboot port #1, reboot port #2, ... so the machine with redundant power supply will not be rebooted. We should end with a failure message when users attempts to do this combination. imho it will be best to include this constrain directly to do it in check_input() in fencing library

m,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]