Hello community, here is the log from the commit of package fence-agents for openSUSE:Factory checked in at 2015-02-10 20:23:21 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/fence-agents (Old) and /work/SRC/openSUSE:Factory/.fence-agents.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "fence-agents" Changes: -------- --- /work/SRC/openSUSE:Factory/fence-agents/fence-agents.changes 2015-01-08 23:02:35.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.fence-agents.new/fence-agents.changes 2015-02-10 20:23:22.000000000 +0100 @@ -1,0 +2,11 @@ +Mon Feb 9 15:23:23 UTC 2015 - [email protected] + +- Update to 4.0.15: + * Tripp Lite PDUs are now supported by fence_tripplite_snmp (symlink to + fence_apc_snmp) + * Default values in metadata sometimes differ to those actually used, + this is fixed now + * improvements in testing +- Remove patch: 0001-Avoid-problem-with-broken-make-variable-expansion.patch + +------------------------------------------------------------------- Old: ---- 0001-Avoid-problem-with-broken-make-variable-expansion.patch fence-agents-4.0.14.tar.xz New: ---- fence-agents-4.0.15.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ fence-agents.spec ++++++ --- /var/tmp/diff_new_pack.GkMxGk/_old 2015-02-10 20:23:23.000000000 +0100 +++ /var/tmp/diff_new_pack.GkMxGk/_new 2015-02-10 20:23:23.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package fence-agents # -# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -22,12 +22,10 @@ Summary: Fence Agents for Pacemaker from RHCS License: GPL-2.0 and LGPL-2.1 Group: Productivity/Clustering/HA -Version: 4.0.14 +Version: 4.0.15 Release: 0 Url: http://git.fedorahosted.org/git/fence-agents.git Source0: %{name}-%{version}.tar.xz -# PATCH-FIX-OPENSUSE: Avoid problem with broken make variable expansion -Patch1: 0001-Avoid-problem-with-broken-make-variable-expansion.patch Requires: python-curl Requires: python-openssl @@ -157,7 +155,6 @@ %prep %setup -q -n %{name}-%{version} -%patch1 -p1 %build CFLAGS="${CFLAGS} ${RPM_OPT_FLAGS}" ++++++ fence-agents-4.0.14.tar.xz -> fence-agents-4.0.15.tar.xz ++++++ ++++ 1980 lines of diff (skipped) ++++ retrying with extended exclude list diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/.tarball-version new/fence-agents-4.0.15/.tarball-version --- old/fence-agents-4.0.14/.tarball-version 2015-01-07 14:53:02.000000000 +0100 +++ new/fence-agents-4.0.15/.tarball-version 2015-02-09 12:36:30.000000000 +0100 @@ -1 +1 @@ -4.0.14 +4.0.15 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/.version new/fence-agents-4.0.15/.version --- old/fence-agents-4.0.14/.version 2015-01-07 14:53:00.000000000 +0100 +++ new/fence-agents-4.0.15/.version 2015-02-09 12:36:28.000000000 +0100 @@ -1 +1 @@ -4.0.14 +4.0.15 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/ChangeLog new/fence-agents-4.0.15/ChangeLog --- old/fence-agents-4.0.14/ChangeLog 2015-01-07 14:53:02.000000000 +0100 +++ new/fence-agents-4.0.15/ChangeLog 2015-02-09 12:36:30.000000000 +0100 @@ -1,3 +1,33 @@ +2015-02-09 Marek 'marx' Grac <[email protected]> + + fencing: Default values of ipport in metadata + Default values were correctly set but they were not used in metadata after + previous patches. + +2015-01-14 Marek 'marx' Grac <[email protected]> + + fencing: default values for ipport #2 (--ssl-insecure, SNMP agents) + Previous patch of this problem: + * did not solve problem was --ssl-insecure + * did not work correctly with minimalist SNMP agent where snmp_version can not be set + + Problem found using unit-tests. + + [test] First attempt on unit-tests for fencing library + Focus was on unit-testing parts responsible for setting default values as + was reported in 575cbe08a6077ecc1512ceaecfc964378c1a11a6 + + fencing: default value for ipport was not always correct + Correction of metadata output lead to situation when default value of + ipport was not properly set e.g. if --ssh was not default, it's value + was ignored. This update, moves setting default value to proper function. + +2015-01-08 Marek 'marx' Grac <[email protected]> + + [build] Replace using $AWK for different use then awk binary + + fence_apc_snmp: New symlink fence_tripplite_snmp for already supported device + 2015-01-07 Marek 'marx' Grac <[email protected]> fence_mpath: Fix duplicate "getopt" which was not propagated anywhere diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/fence/agents/apc_snmp/Makefile.am new/fence-agents-4.0.15/fence/agents/apc_snmp/Makefile.am --- old/fence-agents-4.0.14/fence/agents/apc_snmp/Makefile.am 2014-11-03 12:46:32.000000000 +0100 +++ new/fence-agents-4.0.15/fence/agents/apc_snmp/Makefile.am 2015-01-08 09:34:27.000000000 +0100 @@ -2,18 +2,23 @@ TARGET = fence_apc_snmp +SYMTARGET = fence_tripplite_snmp + SRC = $(TARGET).py EXTRA_DIST = $(SRC) \ powernet369.mib \ README -sbin_SCRIPTS = $(TARGET) +sbin_SCRIPTS = $(TARGET) $(SYMTARGET) -man_MANS = $(TARGET).8 +man_MANS = $(TARGET).8 $(SYMTARGET).8 FENCE_TEST_ARGS = -l test -p test -a test -n 1 include $(top_srcdir)/make/fencebuild.mk include $(top_srcdir)/make/fenceman.mk include $(top_srcdir)/make/agentpycheck.mk + +$(SYMTARGET): $(TARGET) + cp $^ $@ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/fence/agents/lib/fencing.py.py new/fence-agents-4.0.15/fence/agents/lib/fencing.py.py --- old/fence-agents-4.0.14/fence/agents/lib/fencing.py.py 2015-01-07 14:31:42.000000000 +0100 +++ new/fence-agents-4.0.15/fence/agents/lib/fencing.py.py 2015-02-09 10:33:16.000000000 +0100 @@ -1091,12 +1091,11 @@ default_value = "23" default_string = "(default 23, 22 if --ssh option is used)" else: - tcp_ports = {"snmp_version" : "161", "secure" : "22", "telnet" : "23", "web" : "80", "ssl" : "443"} + tcp_ports = {"community" : "161", "secure" : "22", "telnet" : "23", "web" : "80", "ssl" : "443"} # all cases where next command returns multiple results are covered by previous blocks - protocol = [x for x in ["snmp_version", "secure", "ssl", "web", "telnet"] if device_opt.count(x)][0] + protocol = [x for x in ["community", "secure", "ssl", "web", "telnet"] if device_opt.count(x)][0] default_value = tcp_ports[protocol] - all_opt["ipport"]["default"] = default_value if default_string is None: all_opt["ipport"]["help"] = "-u, --ipport=[port] TCP/UDP port to use (default %s)" % \ (default_value) @@ -1104,8 +1103,30 @@ all_opt["ipport"]["help"] = "-u, --ipport=[port] TCP/UDP port to use\n" + " "*40 + default_string def _set_default_values(options): + if "ipport" in options["device_opt"]: + if not "--ipport" in options: + if "default" in all_opt["ipport"]: + options["--ipport"] = all_opt["ipport"]["default"] + elif "community" in options["device_opt"]: + options["--ipport"] = "161" + elif "--ssh" in options or all_opt["secure"].get("default", "0") == "1": + options["--ipport"] = "22" + elif "--ssl" in options or all_opt["ssl"].get("default", "0") == "1": + options["--ipport"] = "443" + elif "--ssl-secure" in options or all_opt["ssl_secure"].get("default", "0") == "1": + options["--ipport"] = "443" + elif "--ssl-insecure" in options or all_opt["ssl_insecure"].get("default", "0") == "1": + options["--ipport"] = "443" + elif "web" in options["device_opt"]: + options["--ipport"] = "80" + elif "telnet" in options["device_opt"]: + options["--ipport"] = "23" + + if "--ipport" in options: + all_opt["ipport"]["default"] = options["--ipport"] + for opt in options["device_opt"]: - if all_opt[opt].has_key("default"): + if all_opt[opt].has_key("default") and not opt == "ipport": getopt_long = "--" + all_opt[opt]["longopt"] if not options.has_key(getopt_long): options[getopt_long] = all_opt[opt]["default"] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/make/agentpycheck.mk new/fence-agents-4.0.15/make/agentpycheck.mk --- old/fence-agents-4.0.14/make/agentpycheck.mk 2014-12-04 22:58:43.000000000 +0100 +++ new/fence-agents-4.0.15/make/agentpycheck.mk 2015-01-14 15:59:00.000000000 +0100 @@ -1,19 +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--}' +AWK_VAL='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 | awk $(AWK) > $(TEMPFILE) + PYTHONPATH=$(abs_srcdir)/../lib:$(abs_builddir)/../lib python ./$(INPUT) -o metadata | $(AWK) $(AWK_VAL) > $(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 | awk $(AWK) > $(DATADIR)/$(INPUT).xml + PYTHONPATH=$(abs_srcdir)/../lib:$(abs_builddir)/../lib python ./$(INPUT) -o metadata | $(AWK) $(AWK_VAL) > $(DATADIR)/$(INPUT).xml # If test will fail, rerun fence agents to show problems delay-check.%: % diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/fence-agents-4.0.14/tests/data/metadata/fence_tripplite_snmp.xml new/fence-agents-4.0.15/tests/data/metadata/fence_tripplite_snmp.xml --- old/fence-agents-4.0.14/tests/data/metadata/fence_tripplite_snmp.xml 1970-01-01 01:00:00.000000000 +0100 +++ new/fence-agents-4.0.15/tests/data/metadata/fence_tripplite_snmp.xml 2015-01-08 09:36:09.000000000 +0100 @@ -0,0 +1,165 @@ +<?xml version="1.0" ?> +<resource-agent name="fence_tripplite_snmp" shortdesc="Fence agent for APC, Tripplite PDU over SNMP" > +<longdesc>fence_apc_snmp is an I/O Fencing agent which can be used with the APC network power switch or Tripplite PDU devices.It logs into a device via SNMP and reboots a specified outlet. It supports SNMP v1, v2c, v3 with all combinations of authenticity/privacy settings.</longdesc> +<vendor-url>http://www.apc.com</vendor-url> +<parameters> + <parameter name="action" unique="0" required="1"> + <getopt mixed="-o, --action=[action]" /> + <content type="string" default="reboot" /> + <shortdesc lang="en">Fencing Action</shortdesc> + </parameter> + <parameter name="community" unique="0" required="0"> + <getopt mixed="-c, --community=[community]" /> + <content type="string" default="private" /> + <shortdesc lang="en">Set the community string</shortdesc> + </parameter> + <parameter name="inet4_only" unique="0" required="0"> + <getopt mixed="-4, --inet4-only" /> + <content type="boolean" /> + <shortdesc lang="en">Forces agent to use IPv4 addresses only</shortdesc> + </parameter> + <parameter name="inet6_only" unique="0" required="0"> + <getopt mixed="-6, --inet6-only" /> + <content type="boolean" /> + <shortdesc lang="en">Forces agent to use IPv6 addresses only</shortdesc> + </parameter> + <parameter name="ipaddr" unique="0" required="1"> + <getopt mixed="-a, --ip=[ip]" /> + <content type="string" /> + <shortdesc lang="en">IP Address or Hostname</shortdesc> + </parameter> + <parameter name="ipport" unique="0" required="0"> + <getopt mixed="-u, --ipport=[port]" /> + <content type="string" default="161" /> + <shortdesc lang="en">TCP/UDP port to use for connection with device</shortdesc> + </parameter> + <parameter name="login" unique="0" required="0"> + <getopt mixed="-l, --username=[name]" /> + <content type="string" /> + <shortdesc lang="en">Login Name</shortdesc> + </parameter> + <parameter name="passwd" unique="0" required="0"> + <getopt mixed="-p, --password=[password]" /> + <content type="string" /> + <shortdesc lang="en">Login password or passphrase</shortdesc> + </parameter> + <parameter name="passwd_script" unique="0" required="0"> + <getopt mixed="-S, --password-script=[script]" /> + <content type="string" /> + <shortdesc lang="en">Script to retrieve password</shortdesc> + </parameter> + <parameter name="port" unique="0" required="1"> + <getopt mixed="-n, --plug=[id]" /> + <content type="string" /> + <shortdesc lang="en">Physical plug number, name of virtual machine or UUID</shortdesc> + </parameter> + <parameter name="snmp_auth_prot" unique="0" required="0"> + <getopt mixed="-b, --snmp-auth-prot=[prot]" /> + <content type="select" > + <option value="MD5" /> + <option value="SHA" /> + </content> + <shortdesc lang="en">Set authentication protocol (MD5|SHA)</shortdesc> + </parameter> + <parameter name="snmp_priv_passwd" unique="0" required="0"> + <getopt mixed="-P, --snmp-priv-passwd=[pass]" /> + <content type="string" /> + <shortdesc lang="en">Set privacy protocol password</shortdesc> + </parameter> + <parameter name="snmp_priv_passwd_script" unique="0" required="0"> + <getopt mixed="-R, --snmp-priv-passwd-script" /> + <content type="string" /> + <shortdesc lang="en">Script to run to retrieve privacy password</shortdesc> + </parameter> + <parameter name="snmp_priv_prot" unique="0" required="0"> + <getopt mixed="-B, --snmp-priv-prot=[prot]" /> + <content type="select" > + <option value="DES" /> + <option value="AES" /> + </content> + <shortdesc lang="en">Set privacy protocol (DES|AES)</shortdesc> + </parameter> + <parameter name="snmp_sec_level" unique="0" required="0"> + <getopt mixed="-E, --snmp-sec-level=[level]" /> + <content type="select" > + <option value="noAuthNoPriv" /> + <option value="authNoPriv" /> + <option value="authPriv" /> + </content> + <shortdesc lang="en">Set security level (noAuthNoPriv|authNoPriv|authPriv)</shortdesc> + </parameter> + <parameter name="snmp_version" unique="0" required="0"> + <getopt mixed="-d, --snmp-version=[version]" /> + <content type="select" default="1" > + <option value="1" /> + <option value="2c" /> + <option value="3" /> + </content> + <shortdesc lang="en">Specifies SNMP version to use (1,2c,3)</shortdesc> + </parameter> + <parameter name="verbose" unique="0" required="0"> + <getopt mixed="-v, --verbose" /> + <content type="boolean" /> + <shortdesc lang="en">Verbose mode</shortdesc> + </parameter> + <parameter name="debug" unique="0" required="0"> + <getopt mixed="-D, --debug-file=[debugfile]" /> + <content type="string" /> + <shortdesc lang="en">Write debug information to given file</shortdesc> + </parameter> + <parameter name="version" unique="0" required="0"> + <getopt mixed="-V, --version" /> + <content type="boolean" /> + <shortdesc lang="en">Display version information and exit</shortdesc> + </parameter> + <parameter name="help" unique="0" required="0"> + <getopt mixed="-h, --help" /> + <content type="boolean" /> + <shortdesc lang="en">Display help and exit</shortdesc> + </parameter> + <parameter name="separator" unique="0" required="0"> + <getopt mixed="-C, --separator=[char]" /> + <content type="string" default="," /> + <shortdesc lang="en">Separator for CSV created by operation list</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="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="power_timeout" unique="0" required="0"> + <getopt mixed="--power-timeout=[seconds]" /> + <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="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="retry_on" unique="0" required="0"> + <getopt mixed="--retry-on=[attempts]" /> + <content type="string" default="1" /> + <shortdesc lang="en">Count of attempts to retry power on</shortdesc> + </parameter> +</parameters> +<actions> + <action name="on" automatic="0"/> + <action name="off" /> + <action name="reboot" /> + <action name="status" /> + <action name="list" /> + <action name="monitor" /> + <action name="metadata" /> +</actions> +</resource-agent> -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
