diff --git a/SOURCES/bz1322702-fix-automatic-nova-evacuate.patch b/SOURCES/bz1322702-fix-automatic-nova-evacuate.patch new file mode 100644 index 0000000..adeb76b --- /dev/null +++ b/SOURCES/bz1322702-fix-automatic-nova-evacuate.patch @@ -0,0 +1,33 @@ +diff -uNr a/fence/agents/compute/fence_compute.py b/fence/agents/compute/fence_compute.py +--- a/fence/agents/compute/fence_compute.py 2016-03-30 16:07:11.600203519 +0200 ++++ b/fence/agents/compute/fence_compute.py 2016-03-30 16:09:17.184539645 +0200 +@@ -80,6 +80,7 @@ + return True + if server.image.get('id') in evac_images: + return True ++ logging.debug("Instance %s is not evacuable" % server.image.get('id')) + return False + + def _get_evacuable_flavors(): +@@ -103,10 +104,12 @@ + + def _host_evacuate(options): + result = True +- servers = nova.servers.list(search_opts={'host': options["--plug"]}) ++ servers = nova.servers.list(search_opts={'host': options["--plug"], 'all_tenants': 1 }) + if options["--instance-filtering"] == "False": ++ logging.debug("Evacuating all images and flavors") + evacuables = servers + else: ++ logging.debug("Filtering images and flavors") + flavors = _get_evacuable_flavors() + images = _get_evacuable_images() + # Identify all evacuable servers +@@ -119,6 +122,7 @@ + on_shared_storage = True + + for server in evacuables: ++ logging.debug("Processing %s" % server) + if hasattr(server, 'id'): + response = _server_evacuate(server.id, on_shared_storage) + if response["accepted"]: diff --git a/SPECS/fence-agents.spec b/SPECS/fence-agents.spec index e36425a..0a6e29f 100644 --- a/SPECS/fence-agents.spec +++ b/SPECS/fence-agents.spec @@ -16,7 +16,7 @@ Name: fence-agents Summary: Fence Agents for Red Hat Cluster Version: 4.0.11 -Release: 27%{?alphatag:.%{alphatag}}%{?dist}.5 +Release: 27%{?alphatag:.%{alphatag}}%{?dist}.7 License: GPLv2+ and LGPLv2+ Group: System Environment/Base URL: http://sourceware.org/cluster/wiki/ @@ -98,6 +98,7 @@ Patch73: bz1303698-fence_cisco_ucs-Obtain-status-of-device-from-differe.patch Patch74: bz1303698-2-fence_cisco_ucs-Add-missing-as-off.patch Patch75: bz1303698-3-fence_cisco_ucs-Update-XML-metadata.patch Patch76: bz1303698-4-fence_cisco_ucs-Update-XML-metadata.patch +Patch77: bz1322702-fix-automatic-nova-evacuate.patch %if 0%{?rhel} %global supportedagents apc apc_snmp bladecenter brocade cisco_mds cisco_ucs compute drac5 eaton_snmp emerson eps hpblade ibmblade ifmib ilo ilo_moonshot ilo_mp ilo_ssh intelmodular ipdu ipmilan mpath kdump rhevm rsa rsb scsi vmware_soap wti @@ -200,6 +201,7 @@ BuildRequires: autoconf automake libtool %patch74 -p1 -b .bz1303698-2 %patch75 -p1 -b .bz1303698-3 %patch76 -p1 -b .bz1303698-4 +%patch77 -p1 -b .bz1322702 %build ./autogen.sh @@ -767,13 +769,18 @@ The fence-agents-zvm package contains a fence agent for z/VM hypervisors %endif %changelog +* Tue Apr 05 2016 Oyvind Albrigtsen - 4.0.11-27.7 +- fence_compute: fix evacuation not working when instance was created + by non-admin user + Resolves: rhbz#1322702 + * Tue Feb 09 2016 Marek Grac - 4.0.11-27.5 - fence_cisco_ucs: Change endpoint for 'status' action - Resolves: rhb#1303698 + Resolves: rhbz#1303698 * Tue Feb 02 2016 Marek Grac - 4.0.11-27.4 - fence_cisco_ucs: Change endpoint for 'status' action - Resolves: rhb#1303698 + Resolves: rhbz#1303698 * Wed Jan 20 2016 Marek Grac - 4.0.11-30 - fence_compute: Replace with current implementation