Accepting request 477365 from home:yan_gao:branches:network:ha-clustering:Factory:Test

- Build: lrmd: Include libxml/tree.h in lrmd.h
  * pacemaker-lrmd.h-include-libxml.patch

- libfencing,fencing: properly remap "action" in configuration
- libservices: ensure recurring actions table is created before using
- libservices: improve error messages when creating operation
- libservices: properly detect in-flight systemd/upstart ops when kicking
- libservices: properly cancel in-flight systemd/upstart op
- libservices: handle in-flight case first when cancelling an operation
- libservices: prevent use-after-free when freeing an operation
- libservices: ensure completed ops aren't on blocked ops list
- libcrmcommon: assert if can't generate operation key
- libcrmcommon: improve remote connection polling messages
- crmd: clear failure only for requested node
- crmd: improve message when clearing failures
- pengine,libpe_status: make failcount clearing messages more helpful
- pengine,libpe_status: don't clear same fail-count twice
- cib: properly mark variable as volatile
- libcib: avoid memory leak in query_node_uuid()
- tools: avoid NULL dereference in crm_resource debug message
- cib,libcrmcommon,lrmd: handle IP addresses better in messages
- tools: crm_attribute should prefer node name from environment
- libcrmcommon: Correctly delete XML comments according to their positions (bsc#1024037)
- libcrmcommon: Correctly compare XML comments to prevent crmd from getting into infinite election loop (bsc#1024037)
- crmd,libcrmcluster: minor log message improvements
- tools: avoid deprecated function in notifyServicelogEvent
- libcrmcommon,pengine,tools: pass local node name to resource agents
- use callback instead of sync call
- libcib: make querying node uuid more efficient
- tools: allow regular expression with crm_attribute

OBS-URL: https://build.opensuse.org/request/show/477365
OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/pacemaker?expand=0&rev=260
This commit is contained in:
Yan Gao 2017-03-07 00:32:46 +00:00 committed by Git OBS Bridge
parent de2e3d57d3
commit 559483a527
8 changed files with 251 additions and 209 deletions

View File

@ -8,10 +8,10 @@
To update to a new release, change "revision" to the desired To update to a new release, change "revision" to the desired
git commit hash and bump "version" if necessary git commit hash and bump "version" if necessary
<param name="version">1.1.15</param> <param name="version">1.1.16</param>
--> -->
<param name="versionformat">1.1.15+git%cd.%h</param> <param name="versionformat">1.1.16+git%cd.%h</param>
<param name="revision">b6f251a13fadca0cb74702b0c007a55275c8ea09</param> <param name="revision">a7825f4f0a8db272d1ce0b1f93e8044cbcaa5144</param>
</service> </service>
<service name="recompress" mode="disabled"> <service name="recompress" mode="disabled">

View File

@ -1,13 +1,17 @@
commit 41ae609accd114bc5d4a05a74a80d3213d217373 From ab4df57e195486ee651f56793470d421233a0896 Mon Sep 17 00:00:00 2001
Author: Dejan Muhamedagic <dejan@suse.de> From: =?UTF-8?q?Kristoffer=20Gr=C3=B6nlund?= <krig@koru.se>
Date: Fri Nov 25 13:11:15 2011 +0100 Date: Thu, 2 Feb 2017 09:06:00 +0100
Subject: [PATCH] Medium: NodeUtilization: Add NodeUtilization agent
Medium: RA: add NodeUtilization RA ---
extra/resources/Makefile.am | 1 +
extra/resources/NodeUtilization | 224 ++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 225 insertions(+)
create mode 100644 extra/resources/NodeUtilization
Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/Makefile.am diff --git a/extra/resources/Makefile.am b/extra/resources/Makefile.am
=================================================================== --- a/extra/resources/Makefile.am
--- pacemaker-1.1.15+git20161018.722276c.orig/extra/resources/Makefile.am +++ b/extra/resources/Makefile.am
+++ pacemaker-1.1.15+git20161018.722276c/extra/resources/Makefile.am
@@ -38,7 +38,8 @@ ocf_SCRIPTS = ClusterMon \ @@ -38,7 +38,8 @@ ocf_SCRIPTS = ClusterMon \
SysInfo \ SysInfo \
SystemHealth \ SystemHealth \
@ -18,17 +22,19 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/Makefile.am
isolationtech_SCRIPTS = docker-wrapper isolationtech_SCRIPTS = docker-wrapper
Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization diff --git a/extra/resources/NodeUtilization b/extra/resources/NodeUtilization
=================================================================== new file mode 100644
index 0000000..da5fb56
--- /dev/null --- /dev/null
+++ pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization +++ b/extra/resources/NodeUtilization
@@ -0,0 +1,230 @@ @@ -0,0 +1,224 @@
+#!/bin/sh +#!/bin/sh
+# +#
+# +#
+# NodeUtilization OCF Resource Agent +# NodeUtilization OCF Resource Agent
+# +#
+# Copyright (c) 2011 SUSE LINUX, John Shi +# Copyright (c) 2011 SUSE LINUX, John Shi
+# Copyright (c) 2016 SUSE LINUX, Kristoffer Gronlund
+# All Rights Reserved. +# All Rights Reserved.
+# +#
+# This program is free software; you can redistribute it and/or modify +# This program is free software; you can redistribute it and/or modify
@ -53,13 +59,12 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+####################################################################### +#######################################################################
+# Initialization: +# Initialization:
+ +
+: ${OCF_FUNCTIONS=${OCF_ROOT}/resource.d/heartbeat/.ocf-shellfuncs} +: ${OCF_FUNCTIONS_DIR=${OCF_ROOT}/lib/heartbeat}
+. ${OCF_FUNCTIONS} +. ${OCF_FUNCTIONS_DIR}/ocf-shellfuncs
+: ${__OCF_ACTION=$1}
+ +
+####################################################################### +#######################################################################
+ +
+meta_data() { +NodeUtilization_meta_data() {
+ cat <<END + cat <<END
+<?xml version="1.0"?> +<?xml version="1.0"?>
+<!DOCTYPE resource-agent SYSTEM "ra-api-1.dtd"> +<!DOCTYPE resource-agent SYSTEM "ra-api-1.dtd">
@ -67,56 +72,59 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+<version>1.0</version> +<version>1.0</version>
+ +
+<longdesc lang="en"> +<longdesc lang="en">
+This is an NodeUtilization Resource Agent. +The Node Utilization agent detects system parameters like available CPU, host
+This agent detects system parameters and put them into CIB by crm_attribute, +memory and hypervisor memory availability, and adds them into the CIB for each
+and it runs on every node as clone resource. +node using crm_attribute. Run the agent as a clone resource to have it populate
+these parameters on each node.
+Note: Setting hv_memory only works with Xen at the moment, using the xl or xm
+command line tools.
+</longdesc> +</longdesc>
+<shortdesc lang="en">NodeUtilization resource agent</shortdesc> +<shortdesc lang="en">Node Utilization</shortdesc>
+ +
+<parameters> +<parameters>
+<parameter name="dynamic" unique="0" required="0"> +<parameter name="dynamic" unique="0" required="0">
+<longdesc lang="en"> +<longdesc lang="en">
+If set, some of the HA parameters will be reset if there are +If set, parameters will be updated if there are differences between the HA
+difference between HA parameters and system parameters when HA monitor. +parameters and the system values when running the monitor action.
+Otherwise, the HA parameters will be set once when the resource instance starts. +If not set, the parameters will be set once when the resource instance starts.
+</longdesc> +</longdesc>
+<shortdesc lang="en">Set HA parameters when start or monitor</shortdesc> +<shortdesc lang="en">Dynamically update parameters in monitor</shortdesc>
+<content type="boolean" default="true" /> +<content type="boolean" default="true" />
+</parameter> +</parameter>
+ +
+<parameter name="utilization_cpu" unique="0" required="0"> +<parameter name="utilization_cpu" unique="0" required="0">
+<longdesc lang="en">Enable setting cpu utilization.</longdesc> +<longdesc lang="en">Enable setting node CPU utilization limit.</longdesc>
+<shortdesc lang="en">Enable setting cpu utilization.</shortdesc> +<shortdesc lang="en">Set node CPU utilization limit.</shortdesc>
+<content type="boolean" default="true" /> +<content type="boolean" default="true" />
+</parameter> +</parameter>
+ +
+<parameter name="utilization_cpu_reservation" unique="0" required="0"> +<parameter name="utilization_cpu_reservation" unique="0" required="0">
+<longdesc lang="en">CPU reserved for non-HA related usage.</longdesc> +<longdesc lang="en">Subtract this value when setting the CPU utilization parameter.</longdesc>
+<shortdesc lang="en">CPU reserved for non-HA related usage.</shortdesc> +<shortdesc lang="en">CPU reservation.</shortdesc>
+<content type="integer" default="1" /> +<content type="integer" default="1" />
+</parameter> +</parameter>
+ +
+<parameter name="utilization_host_memory" unique="0" required="0"> +<parameter name="utilization_host_memory" unique="0" required="0">
+<longdesc lang="en">Enable setting memory utilization of host.</longdesc> +<longdesc lang="en">Enable setting available host memory.</longdesc>
+<shortdesc lang="en">Enable setting memory utilization of host.</shortdesc> +<shortdesc lang="en">Set available host memory.</shortdesc>
+<content type="boolean" default="true" /> +<content type="boolean" default="true" />
+</parameter> +</parameter>
+ +
+<parameter name="utilization_host_memory_reservation" unique="0" required="0"> +<parameter name="utilization_host_memory_reservation" unique="0" required="0">
+<longdesc lang="en">Memory reserved for other services inside host, in MB.</longdesc> +<longdesc lang="en">Subtract this value when setting host memory utilization, in MB.</longdesc>
+<shortdesc lang="en">Memory reserved for other services inside host, in MB.</shortdesc> +<shortdesc lang="en">Host memory reservation, in MB.</shortdesc>
+<content type="integer" default="512" /> +<content type="integer" default="512" />
+</parameter> +</parameter>
+ +
+<parameter name="utilization_hv_memory" unique="0" required="0"> +<parameter name="utilization_hv_memory" unique="0" required="0">
+<longdesc lang="en">Enable setting the memory utilization of hypervisor.</longdesc> +<longdesc lang="en">Enable setting available hypervisor memory.</longdesc>
+<shortdesc lang="en">Enable setting the memory utilization of hypervisor.</shortdesc> +<shortdesc lang="en">Set available hypervisor memory.</shortdesc>
+<content type="boolean" default="true" /> +<content type="boolean" default="true" />
+</parameter> +</parameter>
+ +
+<parameter name="utilization_hv_memory_reservation" unique="0" required="0"> +<parameter name="utilization_hv_memory_reservation" unique="0" required="0">
+<longdesc lang="en">Memory reserved for the hypervisor, in MB.</longdesc> +<longdesc lang="en">Subtract this value when setting hypervisor memory utilization, in MB.</longdesc>
+<shortdesc lang="en">Memory reserved for the hypervisor, in MB.</shortdesc> +<shortdesc lang="en">Hypervisor memory reservation, in MB.</shortdesc>
+<content type="integer" default="512" /> +<content type="integer" default="512" />
+</parameter> +</parameter>
+</parameters> +</parameters>
@ -132,8 +140,22 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+END +END
+} +}
+ +
+Host_Total_Memory() {
+ local xentool
+
+ xentool=$(which xl 2> /dev/null || which xm 2> /dev/null)
+
+ if [ -x $xentool ]; then
+ $xentool info | awk '/total_memory/{printf("%d\n",$3);exit(0)}'
+ else
+ ocf_log warn "Can only set hv_memory for Xen hypervisor"
+ echo "0"
+ fi
+}
+
+
+set_utilization() { +set_utilization() {
+ host_name="$(hostname)" + host_name="$(ocf_local_nodename)"
+ +
+ if ocf_is_true "$OCF_RESKEY_utilization_cpu"; then + if ocf_is_true "$OCF_RESKEY_utilization_cpu"; then
+ sys_cpu=$(( $(grep -c processor /proc/cpuinfo) - $OCF_RESKEY_utilization_cpu_reservation )) + sys_cpu=$(( $(grep -c processor /proc/cpuinfo) - $OCF_RESKEY_utilization_cpu_reservation ))
@ -141,7 +163,7 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+ +
+ if [ "$sys_cpu" != "$uti_cpu" ]; then + if [ "$sys_cpu" != "$uti_cpu" ]; then
+ if ! crm_attribute -t nodes -U "$host_name" -z -n cpu -v $sys_cpu; then + if ! crm_attribute -t nodes -U "$host_name" -z -n cpu -v $sys_cpu; then
+ ocf_log err "Failed to set cpu of utilization by crm_attribute." + ocf_log err "Failed to set the cpu utilization attribute for $host_name using crm_attribute."
+ return 1 + return 1
+ fi + fi
+ fi + fi
@ -153,25 +175,23 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+ +
+ if [ "$sys_mem" != "$uti_mem" ]; then + if [ "$sys_mem" != "$uti_mem" ]; then
+ if ! crm_attribute -t nodes -U "$host_name" -z -n host_memory -v $sys_mem; then + if ! crm_attribute -t nodes -U "$host_name" -z -n host_memory -v $sys_mem; then
+ ocf_log err "Failed to set host_memory of utilization by crm_attribute." + ocf_log err "Failed to set the host_memory utilization attribute for $host_name using crm_attribute."
+ return 1 + return 1
+ fi + fi
+ fi + fi
+ fi + fi
+ +
+ if [ -x /usr/sbin/xm ]; then
+ if ocf_is_true "$OCF_RESKEY_utilization_hv_memory"; then + if ocf_is_true "$OCF_RESKEY_utilization_hv_memory"; then
+ hv_mem=$(( $(xm info | awk '/total_memory/{printf("%d\n",$3);exit(0)}') - $OCF_RESKEY_utilization_hv_memory_reservation )) + hv_mem=$(( $(Host_Total_Memory) - OCF_RESKEY_utilization_hv_memory_reservation ))
+ uti_mem=$(crm_attribute -Q -t nodes -U "$host_name" -z -n hv_memory 2>/dev/null) + uti_mem=$(crm_attribute -Q -t nodes -U "$host_name" -z -n hv_memory 2>/dev/null)
+ +
+ if [ "$hv_mem" != "$uti_mem" ]; then + if [ "$hv_mem" != "$uti_mem" ]; then
+ if ! crm_attribute -t nodes -U "$host_name" -z -n hv_memory -v $hv_mem; then + if ! crm_attribute -t nodes -U "$host_name" -z -n hv_memory -v $hv_mem; then
+ ocf_log err "Failed to set hv_memory of utilization by crm_attribute." + ocf_log err "Failed to set the hv_memory utilization attribute for $host_name using crm_attribute."
+ return 1 + return 1
+ fi + fi
+ fi + fi
+ fi + fi
+ fi
+} +}
+ +
+NodeUtilization_usage() { +NodeUtilization_usage() {
@ -183,10 +203,7 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+} +}
+ +
+NodeUtilization_start() { +NodeUtilization_start() {
+ if ! touch "$OCF_RESKEY_pidfile"; then + ha_pseudo_resource $statefile start
+ ocf_log err "Failed to touch pidfile: ${OCF_RESKEY_pidfile}."
+ exit $OCF_ERR_GENERIC
+ fi
+ if ! ocf_is_true "$OCF_RESKEY_dynamic"; then + if ! ocf_is_true "$OCF_RESKEY_dynamic"; then
+ if ! set_utilization; then + if ! set_utilization; then
+ exit $OCF_ERR_GENERIC + exit $OCF_ERR_GENERIC
@ -196,27 +213,32 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+} +}
+ +
+NodeUtilization_stop() { +NodeUtilization_stop() {
+ rm -f $OCF_RESKEY_pidfile + ha_pseudo_resource $statefile stop
+ exit $OCF_SUCCESS + exit $OCF_SUCCESS
+} +}
+ +
+NodeUtilization_monitor() { +NodeUtilization_monitor() {
+ if [ ! -f $OCF_RESKEY_pidfile ]; then + local rc
+ exit $OCF_NOT_RUNNING + ha_pseudo_resource $statefile monitor
+ fi + rc=$?
+ +
+ case $rc in
+ $OCF_SUCCESS)
+ if ocf_is_true "$OCF_RESKEY_dynamic"; then + if ocf_is_true "$OCF_RESKEY_dynamic"; then
+ if ! set_utilization; then + if ! set_utilization; then
+ exit $OCF_ERR_GENERIC + exit $OCF_ERR_GENERIC
+ fi + fi
+ fi + fi
+ exit $OCF_SUCCESS + ;;
+ *) exit $rc;;
+ esac
+} +}
+ +
+NodeUtilization_validate() { +NodeUtilization_validate() {
+ exit $OCF_SUCCESS + exit $OCF_SUCCESS
+} +}
+ +
+statefile=$OCF_RESOURCE_TYPE.$(echo $OCF_RESOURCE_INSTANCE | sed -e 's/^.*://')
+ +
+: ${OCF_RESKEY_pidfile:="$HA_VARRUN/NodeUtilization-${OCF_RESOURCE_INSTANCE}"} +: ${OCF_RESKEY_pidfile:="$HA_VARRUN/NodeUtilization-${OCF_RESOURCE_INSTANCE}"}
+: ${OCF_RESKEY_dynamic:="true"} +: ${OCF_RESKEY_dynamic:="true"}
@ -227,29 +249,6 @@ Index: pacemaker-1.1.15+git20161018.722276c/extra/resources/NodeUtilization
+: ${OCF_RESKEY_utilization_host_memory:="true"} +: ${OCF_RESKEY_utilization_host_memory:="true"}
+: ${OCF_RESKEY_utilization_host_memory_reservation="512"} +: ${OCF_RESKEY_utilization_host_memory_reservation="512"}
+ +
+if [ $# -ne 1 ]; then +OCF_REQUIRED_PARAMS=""
+ NodeUtilization_usage +OCF_REQUIRED_BINARIES=""
+ exit $OCF_ERR_ARGS +ocf_rarun $*
+fi
+
+case $__OCF_ACTION in
+meta-data) meta_data
+ exit $OCF_SUCCESS
+ ;;
+start) NodeUtilization_start
+ ;;
+stop) NodeUtilization_stop
+ ;;
+monitor) NodeUtilization_monitor
+ ;;
+validate-all) NodeUtilization_validate
+ ;;
+usage|help) NodeUtilization_usage
+ exit $OCF_SUCCESS
+ ;;
+*) NodeUtilization_usage
+ exit $OCF_ERR_UNIMPLEMENTED
+ ;;
+esac
+
+exit $?

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:f3476a30b0e6b832497b383e32182ecb0a16e66cd7689e1c1f7f98a5ec9d2f26
size 3584199

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d30636bdece960e43b562392b4f461adbd2c213c83bc6fc88aed7c7217121994
size 3602760

View File

@ -1,106 +0,0 @@
Index: pacemaker-1.1.15+git20161104.b6f251a/configure.ac
===================================================================
--- pacemaker-1.1.15+git20161104.b6f251a.orig/configure.ac
+++ pacemaker-1.1.15+git20161104.b6f251a/configure.ac
@@ -1214,58 +1214,6 @@ AC_SUBST(DBUS_LIBS)
AC_CHECK_TYPES([DBusBasicValue],,,[[#include <dbus/dbus.h>]])
-if test "x${enable_systemd}" != xno; then
- if test $HAVE_dbus = 0; then
- if test "x${enable_systemd}" = xyes; then
- AC_MSG_FAILURE([cannot enable systemd without DBus])
- else
- enable_systemd=no
- fi
- fi
- if test "x${enable_systemd}" = xtry; then
- AC_MSG_CHECKING([for systemd version query result via dbus-send])
- ret=$({ dbus-send --system --print-reply \
- --dest=org.freedesktop.systemd1 \
- /org/freedesktop/systemd1 \
- org.freedesktop.DBus.Properties.Get \
- string:org.freedesktop.systemd1.Manager \
- string:Version 2>/dev/null \
- || echo "this borked"; } | tail -n1)
- # sanitize output a bit (interested just in value, not type),
- # ret is intentionally unenquoted so as to normalize whitespace
- ret=$(echo ${ret} | cut -d' ' -f2-)
- AC_MSG_RESULT([${ret}])
- if test "x${ret}" != xborked \
- || systemctl --version 2>/dev/null | grep -q systemd; then
- enable_systemd=yes
- else
- enable_systemd=no
- fi
- fi
-fi
-
-AC_MSG_CHECKING([whether to enable support for managing resources via systemd])
-AC_MSG_RESULT([${enable_systemd}])
-if test "x${enable_systemd}" = xyes; then
- HAVE_systemd=1
- PCMK_FEATURES="$PCMK_FEATURES systemd"
-
- AC_MSG_CHECKING([for systemd path for system unit files])
- systemdunitdir="${systemdunitdir:}"
- PKG_CHECK_VAR([systemdunitdir], [systemd],
- [systemdsystemunitdir], [],[
- systemdunitdir=no
- ])
- AC_MSG_RESULT([${systemdunitdir}])
- if test "x${systemdunitdir}" = xno; then
- AC_MSG_FAILURE([cannot enable systemd when systemdunitdir unresolved])
- fi
-fi
-
-AC_DEFINE_UNQUOTED(SUPPORT_SYSTEMD, $HAVE_systemd, Support systemd based system services)
-AM_CONDITIONAL(BUILD_SYSTEMD, test $HAVE_systemd = 1)
-AC_SUBST(SUPPORT_SYSTEMD)
-
if test "x${enable_upstart}" != xno; then
if test $HAVE_dbus = 0; then
if test "x${enable_upstart}" = xyes; then
@@ -1303,6 +1251,42 @@ AC_DEFINE_UNQUOTED(SUPPORT_UPSTART, $HAV
AM_CONDITIONAL(BUILD_UPSTART, test $HAVE_upstart = 1)
AC_SUBST(SUPPORT_UPSTART)
+if test "x${enable_systemd}" != xno; then
+ if test $HAVE_dbus = 0; then
+ if test "x${enable_systemd}" = xyes; then
+ AC_MSG_FAILURE([cannot enable systemd without DBus])
+ else
+ enable_systemd=no
+ fi
+ else
+ AC_MSG_CHECKING([for systemd path for system unit files])
+ PKG_CHECK_VAR([systemdunitdir], [systemd], [systemdsystemunitdir], [
+ AC_MSG_RESULT([${systemdunitdir}])
+ ],[
+ AC_MSG_RESULT([not found])
+ systemdunitdir=no
+ ])
+ if test "x${systemdunitdir}" = xno; then
+ if test "x${enable_systemd}" = xyes; then
+ AC_MSG_FAILURE([cannot enable systemd when systemdunitdir unresolved])
+ fi
+ enable_systemd=no
+ else
+ enable_systemd=yes
+ fi
+ fi
+fi
+
+AC_MSG_CHECKING([whether to enable support for managing resources via systemd])
+AC_MSG_RESULT([${enable_systemd}])
+if test "x${enable_systemd}" = xyes; then
+ HAVE_systemd=1
+ PCMK_FEATURES="$PCMK_FEATURES systemd"
+fi
+
+AC_DEFINE_UNQUOTED(SUPPORT_SYSTEMD, $HAVE_systemd, Support systemd based system services)
+AM_CONDITIONAL(BUILD_SYSTEMD, test $HAVE_systemd = 1)
+AC_SUBST(SUPPORT_SYSTEMD)
case $SUPPORT_NAGIOS in
1|yes|true|try)

View File

@ -0,0 +1,29 @@
commit 6a9c3c80245f6fd84433e0c1c65c63b4f576350e
Author: Gao,Yan <ygao@suse.com>
Date: Tue Mar 7 00:23:03 2017 +0100
Build: lrmd: Include libxml/tree.h in lrmd.h
65d0b80 introduced "xmlNode *versioned_params" in lrmd_event_data_t but
without including libxml/tree.h in lrmd.h.
Sbd failed to build against it:
In file included from /usr/include/pacemaker/crm/common/util.h:33:0,
from sbd-inquisitor.c:19:
/usr/include/pacemaker/crm/lrmd.h:241:5: error: unknown type name xmlNode
xmlNode *versioned_params;
^
diff --git a/include/crm/lrmd.h b/include/crm/lrmd.h
index 446b39c..6f829f7 100644
--- a/include/crm/lrmd.h
+++ b/include/crm/lrmd.h
@@ -23,6 +23,7 @@
* \ingroup lrmd
*/
#include <stdbool.h>
+#include <libxml/tree.h>
#include <crm/services.h>
#ifndef LRMD__H

View File

@ -1,3 +1,113 @@
-------------------------------------------------------------------
Tue Mar 7 00:01:15 UTC 2017 - ygao@suse.com
- Build: lrmd: Include libxml/tree.h in lrmd.h
* pacemaker-lrmd.h-include-libxml.patch
-------------------------------------------------------------------
Mon Mar 6 22:58:46 UTC 2017 - ygao@suse.com
- libfencing,fencing: properly remap "action" in configuration
- libservices: ensure recurring actions table is created before using
- libservices: improve error messages when creating operation
- libservices: properly detect in-flight systemd/upstart ops when kicking
- libservices: properly cancel in-flight systemd/upstart op
- libservices: handle in-flight case first when cancelling an operation
- libservices: prevent use-after-free when freeing an operation
- libservices: ensure completed ops aren't on blocked ops list
- libcrmcommon: assert if can't generate operation key
- libcrmcommon: improve remote connection polling messages
- crmd: clear failure only for requested node
- crmd: improve message when clearing failures
- pengine,libpe_status: make failcount clearing messages more helpful
- pengine,libpe_status: don't clear same fail-count twice
- cib: properly mark variable as volatile
- libcib: avoid memory leak in query_node_uuid()
- tools: avoid NULL dereference in crm_resource debug message
- cib,libcrmcommon,lrmd: handle IP addresses better in messages
- tools: crm_attribute should prefer node name from environment
- libcrmcommon: Correctly delete XML comments according to their positions (bsc#1024037)
- libcrmcommon: Correctly compare XML comments to prevent crmd from getting into infinite election loop (bsc#1024037)
- crmd,libcrmcluster: minor log message improvements
- tools: avoid deprecated function in notifyServicelogEvent
- libcrmcommon,pengine,tools: pass local node name to resource agents
- use callback instead of sync call
- libcib: make querying node uuid more efficient
- tools: allow regular expression with crm_attribute
- attrd: support regular expressions in legacy attrd
- attrd: support Pacemaker Remote node attributes in legacy attrd
- use status scope to start node in standby mode
- attrd: ignore unsupported requests in legacy attrd
- attrd,crmd: implement peer remove requests in legacy attrd
- crmd: don't clear remote node transient attributes unnecessarily
- crm_mon: protect against non-standard or failing asctime
- libservices(sync): partially prevent killing foreign process
- libservices (sync): ensure no zombie is left behind
- cib: improve re-sync handling
- tools: implement crm_failcount command-line options correctly
- tools: use correct regular expression for fail counts in crm_resource
- cib: never disable legacy mode with corosync 1 stacks
- cib: improve warning when legacy diff fails
- libcrmcommon: ensure filename is not NULL before opening
- crmd: be more resilient when checking an LRM command's "from"
- crmd: improve crmd's LRM-related log messages
- tools: properly ignore version with crm_diff --no-version (bsc#888726)
- Ability to start node in standby
- Upstream version cs: a7825f4f0a8db272d1ce0b1f93e8044cbcaa5144
-------------------------------------------------------------------
Mon Mar 6 13:04:16 UTC 2017 - ygao@suse.com
- libservices: properly watch writable DBus handles
- tools: don't reference hidden parameter in crm_resource help text
- Alert: Set SNMP_PERSISTENT_DIR directory for the snmp-trap tool.
- dbus: Prevent lrmd from hanging on dbus calls (bsc#1015264)
- spec: add %check to run a subset of tests on rpmbuild
- crmd: update cache status for guest node whose host is fenced
- pengine: consider guest node unclean if its host is unclean
- pengine: create a pseudo-fence for guest node recovery
- pengine: guest node fencing doesn't require stonith enabled
- pengine: remove unnecessary assert
- mcp: Correction of the difference in access permission setting.
- stonith_admin: Addition of the list-targets option.
- stonith: Check for missing params in new device and dup
- libservices: treat systemd service reloading as OK
- crmd: increase severity when fencing didn't happen (bsc#1011240)
- rng: Create resources-2.7.rng to update template class validation
- libcrmcommon: Don't report error if the output file isn't syncable
- crmd: bump feature set
- pengine: disable migration for versioned resources
- add versioned parameters support
- Upstream version cs: 2817a2081e9e70e7412f0d0a253495611afab55e
-------------------------------------------------------------------
Mon Mar 6 12:58:37 UTC 2017 - ygao@suse.com
- wd: Fix to not compare NULL when environment variable is not set
- mcp,pacemaker_remote: order after time-sync
- configure: fix fouled parameter expansion
* Drop obsolete pacemaker-configure-systemd-detection.patch
- xml: rng: Keep score-attribute{,-mangle} in the existing RelaxNG schema files for graceful upgrades
- Upstream version cs: 94ff4df51a55cc30d01843ea11b3292bac755432 (Pacemaker-1.1.16)
-------------------------------------------------------------------
Mon Mar 6 12:57:23 UTC 2017 - ygao@suse.com
- RA: NodeUtilization - Use xl if available (bsc#1015842)
* bug-1015842_pacemaker-NodeUtilization-RA.patch
-------------------------------------------------------------------
Mon Mar 6 12:53:50 UTC 2017 - ygao@suse.com
- spec: Prevent overwriting existing sysconfig files by conditionally running %fillup_only (bsc#1022807)
-------------------------------------------------------------------
Mon Mar 6 12:52:25 UTC 2017 - ygao@suse.com
- spec: cts brings an RA that needs python-systemd
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Feb 22 15:39:36 UTC 2017 - dimstar@opensuse.org Wed Feb 22 15:39:36 UTC 2017 - dimstar@opensuse.org

View File

@ -47,20 +47,21 @@
%bcond_with doc %bcond_with doc
Name: pacemaker Name: pacemaker
Version: 1.1.15+git20161104.b6f251a Version: 1.1.16+git20170302.a7825f4
Release: 0 Release: 0
Summary: Scalable High-Availability cluster resource manager Summary: Scalable High-Availability cluster resource manager
# AGPL-3.0 licensed extra/clustermon.sh is not present in the binary
License: GPL-2.0 and GPL-2.0+ and LGPL-2.1+ License: GPL-2.0 and GPL-2.0+ and LGPL-2.1+
Group: Productivity/Clustering/HA Group: Productivity/Clustering/HA
# AGPL-3.0 licensed extra/clustermon.sh is not present in the binary
Url: http://www.clusterlabs.org Url: http://www.clusterlabs.org
# eg. https://github.com/ClusterLabs/pacemaker/archive/8ae45302394b039fb098e150f156df29fc0cb576/pacemaker-8ae4530.tar.gz # Hint: use "spectool -s 0 pacemaker.spec" (rpmdevtools) to check the final URL:
# https://github.com/ClusterLabs/pacemaker/archive/e91769e5a39f5cb2f7b097d3c612368f0530535e/pacemaker-e91769e.tar.gz
Source0: %{name}-%{version}.tar.bz2 Source0: %{name}-%{version}.tar.bz2
Source1: crm_report.in Source1: crm_report.in
Source100: pacemaker.rpmlintrc Source100: pacemaker.rpmlintrc
Patch1: bug-806256_pacemaker-log-level-notice.patch Patch1: bug-806256_pacemaker-log-level-notice.patch
Patch2: bug-728579_pacemaker-stonith-dev-id.patch Patch2: bug-728579_pacemaker-stonith-dev-id.patch
Patch3: pacemaker-NodeUtilization-RA.patch Patch3: bug-1015842_pacemaker-NodeUtilization-RA.patch
Patch4: pacemaker-cibsecret-tool-temp-disabled.patch Patch4: pacemaker-cibsecret-tool-temp-disabled.patch
Patch5: pacemaker-nagios-plugin-dir.patch Patch5: pacemaker-nagios-plugin-dir.patch
Patch6: bug-812269_pacemaker-fencing-device-register-messages.patch Patch6: bug-812269_pacemaker-fencing-device-register-messages.patch
@ -68,7 +69,7 @@ Patch7: pacemaker-Wno-format-signedness.patch
Patch8: bug-943295_pacemaker-lrmd-log-notice.patch Patch8: bug-943295_pacemaker-lrmd-log-notice.patch
Patch9: bug-977201_pacemaker-controld-self-fencing.patch Patch9: bug-977201_pacemaker-controld-self-fencing.patch
Patch10: bug-995365_pacemaker-cts-restart-systemd-journald.patch Patch10: bug-995365_pacemaker-cts-restart-systemd-journald.patch
Patch11: pacemaker-configure-systemd-detection.patch Patch11: pacemaker-lrmd.h-include-libxml.patch
# Required for core functionality # Required for core functionality
BuildRequires: autoconf BuildRequires: autoconf
BuildRequires: automake BuildRequires: automake
@ -89,7 +90,8 @@ BuildRequires: sed
BuildRequires: pkgconfig(bzip2) BuildRequires: pkgconfig(bzip2)
BuildRequires: pkgconfig(corosync) BuildRequires: pkgconfig(corosync)
BuildRequires: pkgconfig(dbus-1) BuildRequires: pkgconfig(dbus-1)
BuildRequires: pkgconfig(glib-2.0) ## version lower bound for: G_GNUC_INTERNAL
BuildRequires: pkgconfig(glib-2.0) >= 2.6
BuildRequires: pkgconfig(gnutls) BuildRequires: pkgconfig(gnutls)
BuildRequires: pkgconfig(libexslt) BuildRequires: pkgconfig(libexslt)
# Pacemaker requires a minimum libqb functionality # Pacemaker requires a minimum libqb functionality
@ -248,11 +250,13 @@ manager for Corosync, CMAN and/or Linux-HA.
The libpacemaker-devel package contains headers and shared libraries The libpacemaker-devel package contains headers and shared libraries
for developing tools for Pacemaker. for developing tools for Pacemaker.
# NOTE: can be noarch if lrmd_test is moved to another subpackage
%package cts %package cts
Summary: Test framework for cluster-related technologies Summary: Test framework for cluster-related technologies
Group: Productivity/Clustering/HA Group: Productivity/Clustering/HA
Requires: libpacemaker3 = %{version}-%{release} Requires: libpacemaker3 = %{version}-%{release}
Requires: python >= 2.6 Requires: python >= 2.6
Requires: python-systemd
%description cts %description cts
Test framework for cluster-related technologies like Pacemaker Test framework for cluster-related technologies like Pacemaker
@ -385,9 +389,15 @@ install -m 755 %{SOURCE1} %{buildroot}%{_sbindir}/crm_report
%service_add_pre crm_mon.service %service_add_pre crm_mon.service
%post cli %post cli
%fillup_only pacemaker if [ ! -e %{_sysconfdir}/sysconfig/pacemaker ]; then
%fillup_only -n pacemaker
fi
%service_add_post crm_mon.service %service_add_post crm_mon.service
%fillup_only crm_mon
if [ ! -e %{_sysconfdir}/sysconfig/crm_mon ]; then
%fillup_only -n crm_mon
fi
%preun cli %preun cli
%service_del_preun crm_mon.service %service_del_preun crm_mon.service