Hello community, here is the log from the commit of package resource-agents for openSUSE:Factory checked in at 2014-01-22 18:19:58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/resource-agents (Old) and /work/SRC/openSUSE:Factory/.resource-agents.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "resource-agents" Changes: -------- --- /work/SRC/openSUSE:Factory/resource-agents/resource-agents.changes 2014-01-14 16:35:39.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.resource-agents.new/resource-agents.changes 2014-01-23 15:55:37.000000000 +0100 @@ -1,0 +2,40 @@ +Wed Jan 22 09:53:09 UTC 2014 - [email protected] + +- Add 0001-Medium-CTDB-Default-ctdb-manages-samba-and-ctdb-mana.patch: + CTDB: Default ctdb manages samba and ctdb manages winbind to "yes", [email protected] +- Add 0002-Medium-CTDB-Add-smb_fileid_algorithm-parameter-defau.patch: + CTDB: Add smb_fileid_algorithm parameter, defaults=fsid (bnc#696978), [email protected] +- Add 0003-Medium-oracle-Create-profile-for-OCFMON-user-bnc-850.patch: + oracle: Create profile for OCFMON user (bnc#850589), [email protected] +- Add 0004-High-oracle-Make-monitoring-user-configurable-bnc-85.patch: + oracle: Make monitoring user configurable (bnc#859683), [email protected] +- Add 0006-Revert-Low-build-Move-binaries-in-usr-lib-heartbeat-.patch: + Revert move of heartbeat binaries to /usr/libexec +- ldirector: fix using service name instead of port number (bnc#836759) +- pgsql: Support for non-standard port and library locations +- Xen: retry domain lookup in repeating monitor and stop +- Xen: report error if the monitor does not find the guest +- VirtualDomain: support more virsh domstate output formats +- LVM: only remove missing PVs on stop when they belong to mirrors +- Raid1: disallow md raid arrays as clone resources to avoid data corruption +- Raid1: make clone prevention overridable similar to the Filesystem RA +- Filesystem: switch to use ocf_is_clone helper function +- varnish: Added support for ulimit -l and ulimit -n +- jboss: Monitor rotatelogs process and restart when it is stopped +- Pure-FTPd: Create pid directory if needed +- lxc: support up-to-date lxc-ps versions +- oracledb.sh: Fix process name grep in exit_idle +- oracledb.sh: Remove quotes around listener name +- oralsnr: Add tns_admin option for setting custom TNS_ADMIN path +- VirtualDomain: Fix ability to use default libvirt hypervisor without explicitly setting agent attribute +- VirtualDomain: Ensure it is possible to manage a libvirt domain defined outside of VirtualDomain +- nfsserver: nfsserver not starting due to missing etab file +- fs-lib.sh: Fixes failure to unmount local fs when process runs with cwd inside fs mount +- upstream cs: 468ed4f8 + +------------------------------------------------------------------- +Fri Jan 17 07:57:38 UTC 2014 - [email protected] + +- fix a few lines for monitor + +------------------------------------------------------------------- Old: ---- resource-agents-3.9.5.tar.bz2 New: ---- 0001-Medium-CTDB-Default-ctdb-manages-samba-and-ctdb-mana.patch 0002-Medium-CTDB-Add-smb_fileid_algorithm-parameter-defau.patch 0003-Medium-oracle-Create-profile-for-OCFMON-user-bnc-850.patch 0004-High-oracle-Make-monitoring-user-configurable-bnc-85.patch 0006-Revert-Low-build-Move-binaries-in-usr-lib-heartbeat-.patch resource-agents-3.9.5.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ resource-agents.spec ++++++ --- /var/tmp/diff_new_pack.Bhet0P/_old 2014-01-23 15:55:38.000000000 +0100 +++ /var/tmp/diff_new_pack.Bhet0P/_new 2014-01-23 15:55:38.000000000 +0100 @@ -43,7 +43,7 @@ Version: 3.9.5 Release: 0 Url: http://linux-ha.org/ -Source: resource-agents-%{version}.tar.bz2 +Source: resource-agents-%{version}.tar.xz Source1: resource-agents.conf # PATCH-FIX-OPENSUSE: fix path to mysql binary Patch1: resource-agents-mysql-sle11.patch @@ -55,6 +55,17 @@ Patch4: no-var-lock-subsys.patch # PATCH-FEATURE-OPENSUSE: add sg_persist RA, [email protected] Patch5: resource-agents-new-sg_persist.patch +# PATCH-FIX-OPENSUSE: CTDB: Default ctdb manages samba and ctdb manages winbind to "yes", [email protected] +Patch6: 0001-Medium-CTDB-Default-ctdb-manages-samba-and-ctdb-mana.patch +# PATCH-FIX-OPENSUSE: CTDB: Add smb_fileid_algorithm parameter, defaults=fsid (bnc#696978), [email protected] +Patch7: 0002-Medium-CTDB-Add-smb_fileid_algorithm-parameter-defau.patch +# PATCH-FIX-UPSTREAM: oracle: Create profile for OCFMON user (bnc#850589), [email protected] +Patch8: 0003-Medium-oracle-Create-profile-for-OCFMON-user-bnc-850.patch +# PATCH-FIX-UPSTREAM: oracle: Make monitoring user configurable (bnc#859683), [email protected] +Patch9: 0004-High-oracle-Make-monitoring-user-configurable-bnc-85.patch +# PATCH-FIX-OPENSUSE: Revert moving binaries to /usr/libexec +Patch10: 0006-Revert-Low-build-Move-binaries-in-usr-lib-heartbeat-.patch + BuildRoot: %{_tmppath}/%{name}-%{version}-build Obsoletes: heartbeat-resources Provides: heartbeat-resources @@ -112,19 +123,24 @@ ldirectord is a stand alone daemon for monitoring the services on real servers. Currently, HTTP, HTTPS, and FTP services are supported. -lditrecord is simple to install and works with the heartbeat code +ldirectord is simple to install and works with the heartbeat code (http://www.linux-ha.org/). See 'ldirectord -h' and linux-ha/doc/ldirectord for more information. %prep ########################################################### -%setup -n resource-agents -q +%setup -q %patch1 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 %patch5 -p1 +%patch6 -p1 +%patch7 -p1 +%patch8 -p1 +%patch9 -p1 +%patch10 -p1 ########################################################### %build ++++++ 0001-Medium-CTDB-Default-ctdb-manages-samba-and-ctdb-mana.patch ++++++ >From 8c78f38cec3d85d88af2b1d038b8354c4950cbf6 Mon Sep 17 00:00:00 2001 From: Tim Serong <[email protected]> Date: Wed, 22 Jan 2014 10:25:20 +0100 Subject: [PATCH 1/4] Medium: CTDB: Default ctdb manages samba and ctdb manages winbind to "yes" --- heartbeat/CTDB | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/heartbeat/CTDB b/heartbeat/CTDB index 18e6d0f6f2ce..0aaddd54ef83 100755 --- a/heartbeat/CTDB +++ b/heartbeat/CTDB @@ -72,8 +72,8 @@ ####################################################################### # Default parameter values: -: ${OCF_RESKEY_ctdb_manages_samba:=no} -: ${OCF_RESKEY_ctdb_manages_winbind:=no} +: ${OCF_RESKEY_ctdb_manages_samba:=yes} +: ${OCF_RESKEY_ctdb_manages_winbind:=yes} : ${OCF_RESKEY_ctdb_service_smb:=""} : ${OCF_RESKEY_ctdb_service_nmb:=""} : ${OCF_RESKEY_ctdb_service_winbind:=""} @@ -133,7 +133,7 @@ This will be deprecated in future, in favor of configuring a separate Samba resource. </longdesc> <shortdesc lang="en">Should CTDB manage Samba?</shortdesc> -<content type="boolean" default="no" /> +<content type="boolean" default="yes" /> </parameter> <parameter name="ctdb_manages_winbind" unique="0" required="0"> @@ -143,7 +143,7 @@ This will be deprecated in future, in favor of configuring a separate Winbind resource. </longdesc> <shortdesc lang="en">Should CTDB manage Winbind?</shortdesc> -<content type="boolean" default="no" /> +<content type="boolean" default="yes" /> </parameter> <parameter name="ctdb_service_smb" unique="0" required="0"> -- 1.8.4 ++++++ 0002-Medium-CTDB-Add-smb_fileid_algorithm-parameter-defau.patch ++++++ >From 1fe8079c11d7b0c9045678566b727d74e302f770 Mon Sep 17 00:00:00 2001 From: Tim Serong <[email protected]> Date: Wed, 22 Jan 2014 10:36:07 +0100 Subject: [PATCH 2/4] Medium: CTDB: Add smb_fileid_algorithm parameter, default=fsid (bnc#696978) --- heartbeat/CTDB | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/heartbeat/CTDB b/heartbeat/CTDB index 0aaddd54ef83..3bb9921c8c77 100755 --- a/heartbeat/CTDB +++ b/heartbeat/CTDB @@ -311,7 +311,7 @@ for OCFS2, this should be set to "fsid". Only necessary if CTDB is managing Samba. </longdesc> <shortdesc lang="en">Samba VFS fileid algorithm</shortdesc> -<content type="string" default="" /> +<content type="string" default="fsid" /> </parameter> </parameters> @@ -339,6 +339,18 @@ elif [ -f $OCF_RESKEY_ctdb_config_dir/ctdb ]; then CTDB_SYSCONFIG=$OCF_RESKEY_ctdb_config_dir/ctdb fi +if [ -n "$CTDB_SYSCONFIG" ]; then + # Automatically set default fileid:algorithm if: + # - the RA has never been run before (/etc/sysconfig/ctdb doesn't + # include our autogenerated comment) + # - the RA has been run before, with a version of the RA that supports + # this option. + if ! grep -qa '# CTDB-RA: Auto-generated' $CTDB_SYSCONFIG || \ + grep -qa '# CTDB-RA: supports fileid' $CTDB_SYSCONFIG; then + : ${OCF_RESKEY_smb_fileid_algorithm:=fsid} + fi +fi + # Backup paths CTDB_SYSCONFIG_BACKUP=${CTDB_SYSCONFIG}.ctdb-ra-orig @@ -475,6 +487,17 @@ generate_ctdb_sysconfig() { ocf_log info "Generating new $CTDB_SYSCONFIG" + # We need a "supports fileid" tag in /etc/sysconfig/ctdb, so we can + # automatically set smb_fileid_algorithm to a sensible default value + # if this tag is present. But we must not include this tag if the + # RA has been invoked previously, and has generated a config file + # that does not contain this tag, lest we break rolling upgrade. + local supports_fileid='# CTDB-RA: supports fileid' + if grep -qa '# CTDB-RA: Auto-generated' $CTDB_SYSCONFIG && \ + ! grep -qa '# CTDB-RA: supports fileid' $CTDB_SYSCONFIG; then + supports_fileid='# CTDB-RA: smb_fileid_algorithm must be set manually' + fi + # Note to maintainers and other random hackers: # Parameters may need to be set here, for CTDB event # scripts to pick up, or may need to be passed to ctdbd @@ -486,6 +509,7 @@ generate_ctdb_sysconfig() { cat >$CTDB_SYSCONFIG <<EOF # CTDB-RA: Auto-generated by ${0}, backup is at $CTDB_SYSCONFIG_BACKUP +$supports_fileid CTDB_MONITOR_FREE_MEMORY=$OCF_RESKEY_ctdb_monitor_free_memory CTDB_SAMBA_SKIP_SHARE_CHECK=$(ocf_is_true "$OCF_RESKEY_ctdb_samba_skip_share_check" && echo 'yes' || echo 'no') CTDB_MANAGES_SAMBA=$(ocf_is_true "$OCF_RESKEY_ctdb_manages_samba" && echo 'yes' || echo 'no') -- 1.8.4 ++++++ 0003-Medium-oracle-Create-profile-for-OCFMON-user-bnc-850.patch ++++++ >From 9ec32785426d3a38203737274e9514d19e593242 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristoffer=20Gr=C3=B6nlund?= <[email protected]> Date: Thu, 5 Dec 2013 13:15:47 +0100 Subject: [PATCH 3/4] Medium: oracle: Create profile for OCFMON user (bnc#850589) The OCFMON user needs to have unlimited password expiry, otherwise the agent will fail if the password expires. Create a profile OCFMONPROFILE used by the OCFMON user with unlimited password expiry. Detect a previously created OCFMON user and alter its profile to the new OCFMONPROFILE. --- heartbeat/oracle | 52 +++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 49 insertions(+), 3 deletions(-) diff --git a/heartbeat/oracle b/heartbeat/oracle index d6b2c50244a9..a643b7667195 100755 --- a/heartbeat/oracle +++ b/heartbeat/oracle @@ -325,20 +325,60 @@ getipc() { echo "oradebug tracefile_name" echo "oradebug ipc" } +show_mon_profile() { + echo "select PROFILE from dba_profiles where PROFILE='$MONPROFILE';" +} +mk_mon_profile() { + cat<<EOF +create profile $MONPROFILE limit FAILED_LOGIN_ATTEMPTS UNLIMITED PASSWORD_LIFE_TIME UNLIMITED; +EOF +} show_mon_user() { echo "select USERNAME, ACCOUNT_STATUS from dba_users where USERNAME='$MONUSR';" } mk_mon_user() { cat<<EOF -create user $MONUSR identified by $MONUSR; +create user $MONUSR identified by $MONUSR profile $MONPROFILE; grant create session to $MONUSR; grant select on v_\$instance to $MONUSR; EOF } -check_mon_user() { +show_mon_user_profile() { + echo "select PROFILE from dba_users where USERNAME='$MONUSR';" +} +set_mon_user_profile() { + cat<<EOF +alter user $MONUSR profile $MONPROFILE; +EOF +} +check_mon_profile() { local output - dbasql show_mon_user | grep -w "^$MONUSR" >/dev/null && + dbasql show_mon_profile | grep -w "^$MONPROFILE" >/dev/null && return 0 + output=`dbasql mk_mon_profile show_mon_profile` + if echo "$output" | grep -w "^$MONPROFILE" >/dev/null; then + return 0 + else + ocf_log err "could not create $MONPROFILE oracle profile" + ocf_log err "sqlplus output: $output" + return 1 + fi +} +check_mon_user() { + local output + output=`dbasql show_mon_user` + if echo "$output" | grep -w "^$MONUSR" >/dev/null; then + output=`dbasql show_mon_user_profile` + if echo "$output" | grep -w "^$MONPROFILE" >/dev/null; then + return 0 + else + dbasql set_mon_user_profile | grep -w "^User altered." >/dev/null && + return 0 + ocf_log err "could not set profile for $MONUSR oracle user" + ocf_log err "sqlplus output: $output" + return 1 + fi + fi output=`dbasql mk_mon_user show_mon_user` if echo "$output" | grep -w "^$MONUSR" >/dev/null; then return 0 @@ -541,6 +581,11 @@ oracle_start() { fi output=`dbasql dbopen` + # check/create the monitor profile + if ! check_mon_profile; then + return $OCF_ERR_GENERIC + fi + # check/create the monitor user if ! check_mon_user; then return $OCF_ERR_GENERIC @@ -650,6 +695,7 @@ show_procs() { proc_pids() { show_procs | awk '{print $1}'; } PROCS_CLEANUP_TIME="30" +MONPROFILE="OCFMONPROFILE" MONUSR="OCFMON" OCF_REQUIRED_PARAMS="sid" OCF_REQUIRED_BINARIES="sqlplus" -- 1.8.4 ++++++ 0004-High-oracle-Make-monitoring-user-configurable-bnc-85.patch ++++++ >From 001124ef37171615e3caaece9a6640c3a5c9abe5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristoffer=20Gr=C3=B6nlund?= <[email protected]> Date: Wed, 22 Jan 2014 10:14:21 +0100 Subject: [PATCH 4/6] High: oracle: Make monitoring user configurable (bnc#859683) Add parameters for monitoring user and password. This gives the administrator full control over password expiration and naming restrictions. --- heartbeat/oracle | 38 +++++++++++++++++++++++++++++++++++--- 1 file changed, 35 insertions(+), 3 deletions(-) diff --git a/heartbeat/oracle b/heartbeat/oracle index a643b7667195..421002b199c1 100755 --- a/heartbeat/oracle +++ b/heartbeat/oracle @@ -27,6 +27,8 @@ # OCF_RESKEY_ipcrm (optional; defaults to "instance") # OCF_RESKEY_clear_backupmode (optional; default to "false") # OCF_RESKEY_shutdown_method (optional; default to "checkpoint/abort") +# OCF_RESKEY_monuser (optional; defaults to "OCFMON") +# OCF_RESKEY_monpassword (optional; defaults to "OCFMON") # # Initialization: @@ -34,6 +36,12 @@ . ${OCF_FUNCTIONS_DIR}/ocf-shellfuncs . ${OCF_FUNCTIONS_DIR}/ora-common.sh +# Defaults: +OCF_RESKEY_monuser_default="OCFMON" +OCF_RESKEY_monpassword_default="OCFMON" +: ${OCF_RESKEY_monuser=${OCF_RESKEY_monuser_default}} +: ${OCF_RESKEY_monpassword=${OCF_RESKEY_monpassword_default}} + ####################################################################### oracle_usage() { @@ -100,6 +108,29 @@ If this does not work for you, just set it explicitely. <content type="string" default="" /> </parameter> +<parameter name="monuser" unique="0"> +<longdesc lang="en"> +Monitoring user name. Every connection as +sysdba is logged in an audit log. This can +result in a large number of new files created. +A new user is created (if it doesn't exist) in +the start action and subsequently used in monitor. +It should have very limited rights. Make sure +that the password for this user does not expire. +</longdesc> +<shortdesc lang="en">monuser</shortdesc> +<content type="string" default="OCFMON" /> +</parameter> + +<parameter name="monpassword" unique="0"> +<longdesc lang="en"> +Password for the monitoring user. Make sure +that the password for this user does not expire. +</longdesc> +<shortdesc lang="en">monpassword</shortdesc> +<content type="string" default="OCFMON" /> +</parameter> + <parameter name="ipcrm" unique="0"> <longdesc lang="en"> Sometimes IPC objects (shared memory segments and semaphores) @@ -250,7 +281,7 @@ dbasql() { runsql "connect / as sysdba" $* } monsql() { - runsql "connect $MONUSR/$MONUSR" $* + runsql "connect $MONUSR/$MONPWD" $* } # use dbasql_one if the query should result in a single line output # at times people stuff commands in oracle .profile @@ -338,7 +369,7 @@ show_mon_user() { } mk_mon_user() { cat<<EOF -create user $MONUSR identified by $MONUSR profile $MONPROFILE; +create user $MONUSR identified by $MONPWD profile $MONPROFILE; grant create session to $MONUSR; grant select on v_\$instance to $MONUSR; EOF @@ -696,7 +727,8 @@ proc_pids() { show_procs | awk '{print $1}'; } PROCS_CLEANUP_TIME="30" MONPROFILE="OCFMONPROFILE" -MONUSR="OCFMON" +MONUSR="$OCF_RESKEY_monuser" +MONPWD="$OCF_RESKEY_monpassword" OCF_REQUIRED_PARAMS="sid" OCF_REQUIRED_BINARIES="sqlplus" ocf_rarun $* -- 1.8.4 ++++++ 0006-Revert-Low-build-Move-binaries-in-usr-lib-heartbeat-.patch ++++++ >From 65dcc5d74aa1f4098a37fcb3961d4b13b70772a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristoffer=20Gr=C3=B6nlund?= <[email protected]> Date: Wed, 22 Jan 2014 11:20:23 +0100 Subject: [PATCH 6/6] Revert "Low: build: Move binaries in /usr/lib/heartbeat to /usr/libexec/heartbeat to avoid multi-lib inconsistencies" This reverts commit 1e79b7831d9daf9cbfa852f0d6f909d2f7ec4a2a. --- heartbeat/Makefile.am | 2 +- heartbeat/ocf-directories.in | 2 +- resource-agents.spec.in | 2 +- tools/Makefile.am | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/heartbeat/Makefile.am b/heartbeat/Makefile.am index cbaa9d9d3d02..99bda6418f81 100644 --- a/heartbeat/Makefile.am +++ b/heartbeat/Makefile.am @@ -25,7 +25,7 @@ EXTRA_DIST = $(ocf_SCRIPTS) $(ocfcommon_DATA) \ AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/linux-ha -halibdir = $(libexecdir)/heartbeat +halibdir = $(libdir)/heartbeat ocfdir = $(OCF_RA_DIR_PREFIX)/heartbeat diff --git a/heartbeat/ocf-directories.in b/heartbeat/ocf-directories.in index 6e0a9d542e2f..26004a3eebb1 100644 --- a/heartbeat/ocf-directories.in +++ b/heartbeat/ocf-directories.in @@ -11,7 +11,7 @@ exec_prefix=@exec_prefix@ : ${HA_RSCTMP:=@HA_RSCTMPDIR@} : ${HA_RSCTMP_OLD:=@HA_VARRUNDIR@/heartbeat/rsctmp} : ${HA_FIFO:=@localstatedir@/lib/heartbeat/fifo} -: ${HA_BIN:=@libexecdir@/heartbeat} +: ${HA_BIN:=@libdir@/heartbeat} : ${HA_SBIN_DIR:=@sbindir@} : ${HA_DATEFMT:="%Y/%m/%d_%T "} : ${HA_DEBUGLOG:=/dev/null} diff --git a/resource-agents.spec.in b/resource-agents.spec.in index 64557dbece0f..5c831cb5212d 100644 --- a/resource-agents.spec.in +++ b/resource-agents.spec.in @@ -255,7 +255,7 @@ rm -rf %{buildroot} %dir %{_sysconfdir}/ha.d %{_sysconfdir}/ha.d/shellfuncs -%{_libexecdir}/heartbeat +%{_libdir}/heartbeat %post -n resource-agents if [ $1 = 2 ]; then diff --git a/tools/Makefile.am b/tools/Makefile.am index 1186967cfbcb..71292bf33acc 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -23,7 +23,7 @@ SUBDIRS = ocft AM_CPPFLAGS = -I$(top_builddir)/include -I$(top_srcdir)/include -halibdir = $(libexecdir)/heartbeat +halibdir = $(libdir)/heartbeat EXTRA_DIST = ocf-tester.8 sfex_init.8 -- 1.8.4 ++++++ resource-agents-new-sg_persist.patch ++++++ --- /var/tmp/diff_new_pack.Bhet0P/_old 2014-01-23 15:55:38.000000000 +0100 +++ /var/tmp/diff_new_pack.Bhet0P/_new 2014-01-23 15:55:38.000000000 +0100 @@ -1,8 +1,23 @@ -Index: resource-agents/doc/man/Makefile.am -=================================================================== ---- resource-agents.orig/doc/man/Makefile.am 2014-01-13 15:13:47.000000000 +0800 -+++ resource-agents/doc/man/Makefile.am 2014-01-13 15:31:20.000000000 +0800 -@@ -130,7 +130,8 @@ +From 027eb4e42419ecd9a4fdffb9f7c0005d53f5b85b Mon Sep 17 00:00:00 2001 +From: Liuhua Wang <[email protected]> +Date: Wed, 22 Jan 2014 11:10:59 +0100 +Subject: [PATCH 5/5] High: rg_persist: RA for persistent SCSI reservation + +--- + doc/man/Makefile.am | 3 +- + heartbeat/Makefile.am | 3 +- + heartbeat/sg_persist | 910 +++++++++++++++++++++++++++++++++++++++++++++++++ + tools/ocft/Makefile.am | 3 +- + tools/ocft/sg_persist | 284 +++++++++++++++ + 5 files changed, 1200 insertions(+), 3 deletions(-) + create mode 100644 heartbeat/sg_persist + create mode 100644 tools/ocft/sg_persist + +diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am +index 3bf569acfd26..fe006833c9c7 100644 +--- a/doc/man/Makefile.am ++++ b/doc/man/Makefile.am +@@ -132,7 +132,8 @@ man_MANS = ocf_heartbeat_AoEtarget.7 \ ocf_heartbeat_tomcat.7 \ ocf_heartbeat_varnish.7 \ ocf_heartbeat_vmware.7 \ @@ -10,13 +25,13 @@ + ocf_heartbeat_zabbixserver.7 \ + ocf_heartbeat_sg_persist.7 - if USE_IPV6ADDR + if USE_IPV6ADDR_AGENT man_MANS += ocf_heartbeat_IPv6addr.7 -Index: resource-agents/heartbeat/Makefile.am -=================================================================== ---- resource-agents.orig/heartbeat/Makefile.am 2014-01-13 15:13:47.000000000 +0800 -+++ resource-agents/heartbeat/Makefile.am 2014-01-13 15:31:20.000000000 +0800 -@@ -121,7 +121,8 @@ +diff --git a/heartbeat/Makefile.am b/heartbeat/Makefile.am +index bc95f897ce8a..cbaa9d9d3d02 100644 +--- a/heartbeat/Makefile.am ++++ b/heartbeat/Makefile.am +@@ -127,7 +127,8 @@ ocf_SCRIPTS = ClusterMon \ WinPopup \ Xen \ Xinetd \ @@ -26,11 +41,12 @@ ocfcommondir = $(OCF_LIB_DIR_PREFIX)/heartbeat ocfcommon_DATA = ocf-shellfuncs \ -Index: resource-agents/heartbeat/sg_persist -=================================================================== ---- /dev/null 1970-01-01 00:00:00.000000000 +0000 -+++ resource-agents/heartbeat/sg_persist 2014-01-13 15:31:20.000000000 +0800 -@@ -0,0 +1,905 @@ +diff --git a/heartbeat/sg_persist b/heartbeat/sg_persist +new file mode 100644 +index 000000000000..5851da710527 +--- /dev/null ++++ b/heartbeat/sg_persist +@@ -0,0 +1,910 @@ +#!/bin/bash +# +# @@ -750,8 +766,13 @@ + if [ ${#REGISTERED_DEVS[*]} -gt 0 ] + then + if [ $RESERVATION_TYPE -eq 7 ] || [ $RESERVATION_TYPE -eq 8] -+ then -+ return $OCF_RUNNING_MASTER ++ then ++ if [ ${#DEVS_WITH_RESERVATION[*]} -gt 0 ] ++ then ++ return $OCF_RUNNING_MASTER ++ else ++ return $OCF_SUCCESS ++ fi + else + return $OCF_SUCCESS + fi @@ -936,11 +957,11 @@ + exit $OCF_ERR_ARGS + ;; +esac -Index: resource-agents/tools/ocft/Makefile.am -=================================================================== ---- resource-agents.orig/tools/ocft/Makefile.am 2014-01-13 15:13:47.000000000 +0800 -+++ resource-agents/tools/ocft/Makefile.am 2014-01-13 15:31:20.000000000 +0800 -@@ -46,7 +46,8 @@ +diff --git a/tools/ocft/Makefile.am b/tools/ocft/Makefile.am +index 2374531fe0ef..efe22e1d6767 100644 +--- a/tools/ocft/Makefile.am ++++ b/tools/ocft/Makefile.am +@@ -47,7 +47,8 @@ ocftcfgs_DATA = apache \ postfix \ tomcat \ Xinetd \ @@ -950,10 +971,11 @@ ocftdir = $(datadir)/$(PACKAGE_NAME)/ocft ocft_DATA = README \ -Index: resource-agents/tools/ocft/sg_persist -=================================================================== ---- /dev/null 1970-01-01 00:00:00.000000000 +0000 -+++ resource-agents/tools/ocft/sg_persist 2014-01-13 15:31:20.000000000 +0800 +diff --git a/tools/ocft/sg_persist b/tools/ocft/sg_persist +new file mode 100644 +index 000000000000..fa8fb122c1a4 +--- /dev/null ++++ b/tools/ocft/sg_persist @@ -0,0 +1,284 @@ +# sg_persist + @@ -1239,3 +1261,6 @@ + + AgentRun stop + AgentRun@$IP_2 stop +-- +1.8.4 + -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
