Hello community,
here is the log from the commit of package heartbeat
checked in at Thu Sep 25 01:18:51 CEST 2008.
--------
--- heartbeat/heartbeat.changes 2008-09-10 18:57:10.000000000 +0200
+++ /mounts/work_src_done/STABLE/heartbeat/heartbeat.changes 2008-09-15 16:03:10.000000000 +0200
@@ -1,0 +2,7 @@
+Mon Sep 15 13:07:50 CEST 2008 - abeekhof@suse.de
+
+- Create libheartbeat subpackage with consistent library versions
+- Update the Filesystem resource to work with new OCFS2 stack
+- Update from upstream
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ heartbeat.spec ++++++
--- /var/tmp/diff_new_pack.J12380/_old 2008-09-25 01:18:35.000000000 +0200
+++ /var/tmp/diff_new_pack.J12380/_new 2008-09-25 01:18:35.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package heartbeat (Version 2.99.9)
+# spec file for package heartbeat (Version 2.99.10)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -36,7 +36,7 @@
Name: heartbeat
Summary: The Heartbeat Subsystem for High-Availability Linux
-Version: 2.99.9
+Version: 2.99.10
Release: 1
License: GPL v2 or later; LGPL v2.1 or later
Url: http://linux-ha.org/
@@ -177,17 +177,8 @@
License: GPL v2 or later; LGPL v2.1 or later
Summary: Common heartbeat components
Group: Productivity/Clustering/HA
-# We need these when upgading from the old package structure
+Provides: %{name} = 2.1.4
Obsoletes: %{name} < 2.99
-Obsoletes: %{name}-pils < 2.99
-Obsoletes: %{name}-stonith < 2.99
-Provides: %{name}-pils = 2.1.4
-Provides: %{name}-stonith = 2.1.4
-Provides: heartbeat:%{_libdir}/libapphb.so.*
-Provides: heartbeat:%{_libdir}/liblrm.so.*
-Provides: heartbeat:%{_libdir}/libplumb.so.*
-Provides: heartbeat:%{_libdir}/libplumbgpl.so.*
-Provides: heartbeat:%{_libdir}/libstonith.so.*
%description common
Clustering components provided by the Heartbeat project that are
@@ -210,19 +201,77 @@
Sun Jiang Dong
(See doc/AUTHORS)
-%package common-devel
+%package -n libheartbeat2
License: GPL v2 or later; LGPL v2.1 or later
-Summary: Common heartbeat components
+Summary: The Heartbeat Subsystem for High-Availability Linux
Group: Productivity/Clustering/HA
-Requires: heartbeat-common = %{version}-%{release}
+Provides: %{name}-pils = 2.1.4
+Provides: %{name}-stonith = 2.1.4
+Obsoletes: %{name}-pils < 2.99
+Obsoletes: %{name}-stonith < 2.99
-%description common-devel
-Clustering components provided by the Heartbeat project that are
-generally useful regardless of which cluster stack is being used.
+%description -n libheartbeat2
+heartbeat is a sophisticated multinode resource manager for High
+Availability clusters.
-Include a local (non-cluster-aware) resource manager, a basic
-(non-cluster-aware) STONITH framework and some useful libraries for
-asyncronous, non-blocking IPC and using gmainloop().
+It can failover arbitrary resources, ranging from IP addresses over NFS
+to databases that are tied in via resource scripts. The resources can
+have arbitrary dependencies for ordering or placement between them.
+
+heartbeat contains a cluster membership layer, fencing, and local and
+clusterwide resource management functionality.
+
+1.2/1.0 based 2-node only configurations are supported in a legacy
+mode.
+
+heartbeat implements the following kinds of heartbeats:
+
+- Serial ports
+
+- UDP/IPv4 broadcast, multi-cast, and unicast
+
+- IPv4 "ping" pseudo-cluster members.
+
+
+
+Authors:
+--------
+ Alan Robertson
+ Andrew Beekhof
+ Guochun Shi
+ Horms
+ Huang Zhen
+ Lars Marowsky-Bree
+ Sun Jiang Dong
+ (See doc/AUTHORS)
+
+%package -n libheartbeat-devel
+License: GPL v2 or later; LGPL v2.1 or later
+Summary: The Heartbeat Subsystem for High-Availability Linux
+Group: Productivity/Clustering/HA
+Requires: libheartbeat2 = %{version}-%{release}
+
+%description -n libheartbeat-devel
+heartbeat is a sophisticated multinode resource manager for High
+Availability clusters.
+
+It can failover arbitrary resources, ranging from IP addresses over NFS
+to databases that are tied in via resource scripts. The resources can
+have arbitrary dependencies for ordering or placement between them.
+
+heartbeat contains a cluster membership layer, fencing, and local and
+clusterwide resource management functionality.
+
+1.2/1.0 based 2-node only configurations are supported in a legacy
+mode.
+
+heartbeat implements the following kinds of heartbeats:
+
+- Serial ports
+
+- UDP/IPv4 broadcast, multi-cast, and unicast
+
+- IPv4 "ping" pseudo-cluster members.
@@ -242,7 +291,6 @@
Summary: A Monitoring Daemon for Maintaining High Availability Resources
Group: Productivity/Clustering/HA
Requires: %{SSLeay} perl-libwww-perl ipvsadm
-Obsoletes: heartbeat-ldirectd
%if 0%{?fedora_version}
Requires(post): /sbin/chkconfig
Requires(preun):/sbin/chkconfig
@@ -296,6 +344,7 @@
Summary: The Heartbeat Subsystem for High-Availability Linux
Group: Productivity/Clustering/HA
Requires: %{name} = %{version}-%{release}
+Requires: libheartbeat-devel = %{version}-%{release}
%description devel
heartbeat is a sophisticated multinode resource manager for High
@@ -467,13 +516,15 @@
%endif
%endif
###########################################################
+%if 0%{?suse_version}
%preun
-%if %{stop_start_script}
-%if 0%{?suse_version}
%stop_on_removal heartbeat
%endif
%if 0%{?fedora_version}
+
+%preun
+%if %{stop_start_script}
/sbin/chkconfig --del heartbeat
%endif
%endif
@@ -492,14 +543,27 @@
test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} || :
%endif
###########################################################
-%if 0%{?fedora_version}
+%if 0%{?suse_version}
-%post ldirectord
- /sbin/chkconfig --add ldirectord
+%preun ldirectord
+ %stop_on_removal ldirectord
+%endif
+%if 0%{?fedora_version}
%preun ldirectord
+%if %{stop_start_script}
/sbin/chkconfig --del ldirectord
%endif
+%endif
+%if 0%{?fedora_version}
+
+%post ldirectord
+ /sbin/chkconfig --add ldirectord
+%endif
+
+%post -n libheartbeat2 -p /sbin/ldconfig
+
+%postun -n libheartbeat2 -p /sbin/ldconfig
%files
###########################################################
@@ -586,11 +650,17 @@
%{_datadir}/doc/packages/heartbeat/ha.cf
###########################################################
+%files -n libheartbeat2
+%defattr(-,root,root)
+%{_libdir}/libstonith.so.*
+%{_libdir}/libpils.so.*
+%{_libdir}/libapphb.so.*
+%{_libdir}/liblrm.so.*
+%{_libdir}/libplumb.so.*
+%{_libdir}/libplumbgpl.so.*
+
%files common
%defattr(-,root,root)
-%doc %{_datadir}/doc/packages/heartbeat/README
-%doc %{_datadir}/doc/packages/heartbeat/COPYING
-%doc %{_datadir}/doc/packages/heartbeat/COPYING.LGPL
%dir %{_libdir}/heartbeat
%dir %{_libdir}/heartbeat/plugins
%dir %{_datadir}/heartbeat
@@ -602,14 +672,8 @@
%{_sbindir}/hb_report
%{_sbindir}/ocf-tester
%{_sbindir}/sbd
-%{_libdir}/libstonith.so.*
%{_libdir}/stonith
%{_libdir}/pils
-%{_libdir}/libpils.so.*
-%{_libdir}/libapphb.so.*
-%{_libdir}/liblrm.so.*
-%{_libdir}/libplumb.so.*
-%{_libdir}/libplumbgpl.so.*
%{_libdir}/heartbeat/findif
%{_libdir}/heartbeat/ha_logd
%{_libdir}/heartbeat/ha_logger
@@ -618,13 +682,15 @@
%{_libdir}/heartbeat/ocf-returncodes
%{_libdir}/heartbeat/ocf-shellfuncs
%{_libdir}/heartbeat/plugins/RAExec
-%{_libdir}/heartbeat/send_arp
%{_libdir}/heartbeat/utillib.sh
%doc %{_mandir}/man8/apphbd.8*
%doc %{_mandir}/man8/stonith.8*
%doc %{_mandir}/man8/meatclient.8*
%doc %{_mandir}/man8/ha_logd.8*
-%{_datadir}/doc/packages/heartbeat/AUTHORS
+%doc %{_datadir}/doc/packages/heartbeat/AUTHORS
+%doc %{_datadir}/doc/packages/heartbeat/README
+%doc %{_datadir}/doc/packages/heartbeat/COPYING
+%doc %{_datadir}/doc/packages/heartbeat/COPYING.LGPL
%exclude %{_datadir}/doc/packages/heartbeat/ChangeLog
%{_datadir}/doc/packages/heartbeat/logd.cf
%{_datadir}/heartbeat/utillib.sh
@@ -634,7 +700,7 @@
%dir %attr (0700, nobody, %{nogroup}) %{_var}/lib/heartbeat/cores/nobody
%dir %attr (0700, %{uname}, %{gname}) %{_var}/lib/heartbeat/cores/%{uname}
-%files common-devel
+%files -n libheartbeat-devel
%defattr(-,root,root)
%dir %{_includedir}/heartbeat
%{_includedir}/pils
@@ -666,9 +732,9 @@
%{_includedir}/heartbeat/HBauth.h
%{_includedir}/heartbeat/HBcomm.h
%{_includedir}/heartbeat/hb_api.h
-%{_libdir}/libccmclient*.so
-%{_libdir}/libclm*.so
-%{_libdir}/libhbclient*.so
+%exclude %{_libdir}/libclm*.so
+%exclude %{_libdir}/libhbclient*.so
+%exclude %{_libdir}/libccmclient*.so
#%{_libdir}/heartbeat/quorumdtest
%{_libdir}/heartbeat/clmtest
%{_libdir}/heartbeat/api_test
@@ -694,8 +760,9 @@
%dir /usr/lib/ocf
%dir /usr/lib/ocf/resource.d
/usr/lib/ocf/resource.d/heartbeat
-%exclude %{_libdir}/heartbeat/ra-api-1.dtd
+%{_libdir}/heartbeat/send_arp
%{_datadir}/heartbeat/ra-api-1.dtd
+%exclude %{_libdir}/heartbeat/ra-api-1.dtd
###########################################################
# Files for ldirectord
@@ -715,6 +782,10 @@
%config(noreplace) %{_sysconfdir}/logrotate.d/ldirectord
%changelog
+* Mon Sep 15 2008 abeekhof@suse.de
+- Create libheartbeat subpackage with consistent library versions
+- Update the Filesystem resource to work with new OCFS2 stack
+- Update from upstream
* Wed Sep 10 2008 abeekhof@suse.de
- Updated to upstream 2.99.09 (dev tree: e8154a602bf4)
- Resolve many rpmlint errors and warnings
++++++ heartbeat.tar.gz ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/configure.in new/heartbeat/configure.in
--- old/heartbeat/configure.in 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/configure.in 2008-09-15 13:12:56.000000000 +0200
@@ -1163,7 +1163,6 @@
dnl
SNMPLIB=""
-SNMPAGENTLIB=""
SNMPCONFIG=""
ENABLE_SNMP="yes"
@@ -1186,12 +1185,6 @@
else
AC_MSG_CHECKING(for special snmp libraries)
SNMPLIB=`net-snmp-config --libs`
- # KLUDGE!!
- # Apparently some versions of SUSE Linux don't include -lwrap in $SNMPAGENTLIB
- case $SNMPAGENTLIB in
- *wrap*) ;;
- *) SNMPAGENTLIB="$SNMPAGENTLIB -lwrap";;
- esac
AC_MSG_RESULT($SNMPLIB)
fi
elif test "x${ac_cv_header_ucd_snmp_snmp_h}" = "xyes"; then
@@ -1212,118 +1205,6 @@
ENABLE_SNMP="no"
fi
-check_snmp_libs ()
-{
- OLDLIBS="$LIBS"
- LIBS="$LIBS $@"
- AC_MSG_CHECKING(snmp libraries: $LIBS)
- AC_LINK_IFELSE([AC_LANG_PROGRAM([], [])], ,
- AC_MSG_ERROR(cannot link with requested libraries ($LIBS). Reported errors follow:
- $(cat conftest.err)))
- AC_MSG_RESULT(ok)
- LIBS="$OLDLIBS"
-}
-
-SNMPLIBSET=""
-if test "$ENABLE_SNMP" = "yes"; then
- check_snmp_libs $SNMPLIB
- SNMPLIBSET="$SNMPLIB"
-fi
-
-dnl
-dnl There are more sophisticated and general ways of doing this, that
-dnl are more general - but this is better than nothing.
-dnl
-dnl The right procedure would be to locate the libraries that we've been
-dnl told are needed, then do an RPM query on each of these libraries
-dnl to find out what package owns the library (file)
-dnl That'll be a good project for some long, cold winter evening.
-dnl
-dnl Some food for thought from the 'ld' manual page:
-dnl
-dnl The linker uses the following search paths to locate required
-dnl shared libraries.
-dnl
-dnl Ignore steps 1-2, because they involve rpath options
-dnl (which we don't care about)
-dnl
-dnl 3. On an ELF system, if the -rpath and "rpath-link" options
-dnl were not used, search the contents of the environment variable
-dnl "LD_RUN_PATH". It is for the native linker only.
-dnl
-dnl 4. On SunOS, if the -rpath option was not used, search any
-dnl directories specified using -L options.
-dnl
-dnl 5. For a native linker, the contents of the environment variable
-dnl "LD_LIBRARY_PATH".
-dnl
-dnl 6. For a native ELF linker, the directories in "DT_RUNPATH" or
-dnl "DT_RPATH" of a shared library are searched for shared
-dnl libraries needed by it. The "DT_RPATH" entries are ignored if
-dnl "DT_RUNPATH" entries exist.
-dnl
-dnl 7. The default directories, normally /lib and /usr/lib.
-dnl
-dnl 8. For a native linker on an ELF system, if the file
-dnl /etc/ld.so.conf exists, the list of directories found in
-dnl that file.
-dnl
-dnl If the required shared library is not found, the linker will
-dnl issue a warning and continue with the link.
-dnl
-dnl
-libs2packages() {
- for arg
- do
- case $arg in
- -ldl|-lm|-L*|-lc|-lpthread|-lnsl) ;;
- -lresolv|-lcrypt|-lutil|-Wl,-E|-wL,-rpath) ;;
- -lcrypto) echo openssl ;;
- -lnetsnmp) echo net-snmp ;;
- -lsnmp) echo net-snmp ;;
- -lnetsnmpagent) echo net-snmp ;;
- -lnetsnmphelpers) echo net-snmp ;;
- -lnetsnmpmibs) echo net-snmp ;;
- -lrpm) echo rpm ;;
- -lrpmio) echo rpm ;;
- -lpopt) echo popt ;;
- -lsensors) case $host_vendor in
- suse|SUSE|SuSE)
- echo sensors;;
- *) echo lm_sensors
- esac ;;
- -lwrap) case $host_vendor in
- suse|SUSE|SuSE)
- echo tcpd;;
- *) echo tcp_wrappers;;
- esac ;;
- -lz) echo zlib ;;
- -lperl|-l/*perl*/auto/DynaLoader/DynaLoader*)
- echo perl ;;
- *) AC_MSG_WARN([SNMP library $arg not included in RPM build dependencies])
- esac
- done
-}
-
-AC_MSG_CHECKING(What packages are needed for SNMP at compile time for RPMs);
-PKGSET=`libs2packages $SNMPLIBSET | tr ' ' '\012' | sort -u`
-PKGSET=`echo $PKGSET`
-AC_MSG_RESULT($PKGSET)
-
-if test -z "$PKGSET"; then
- SNMP_RPM_BUILD_REQUIRES="BuildRequires: ${CC}"
-else
- SNMP_RPM_BUILD_REQUIRES="BuildRequires: $PKGSET"
-fi
-AC_MSG_RESULT($SNMP_RPM_BUILD_REQUIRES)
-
-AC_SUBST(SNMP_RPM_BUILD_REQUIRES)
-
-AC_ARG_WITH(mibsdir,
- [ --with-miBsdir=DIR directory for mib files. ],
- [ MIBS_DIR="$withval" ])
-
-AC_SUBST(SNMPCONFIG)
AC_SUBST(SNMPLIB)
AM_CONDITIONAL(USE_APC_SNMP, test "$ENABLE_SNMP" = "yes")
@@ -2917,7 +2798,6 @@
AC_MSG_RESULT([ HA user user id = "${HA_CCMUID}"])
AC_MSG_RESULT([ SNMP libraries = "${SNMPLIB}"])
-AC_MSG_RESULT([ ucd_snmp_devel name = "${UCDSNMPDEVEL}"])
AC_MSG_RESULT([ Build CRM = "${enable_crm}"])
AC_MSG_RESULT([ Build LRM = "${enable_lrm}"])
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/debian/changelog new/heartbeat/debian/changelog
--- old/heartbeat/debian/changelog 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/debian/changelog 2008-09-15 13:12:56.000000000 +0200
@@ -2,7 +2,32 @@
* New Upstream
- -- Simon Horman Mon, 18 Aug 2008 22:12:16 +1000
+ -- Simon Horman Sat, 30 Aug 2008 11:16:30 +1000
+
+heartbeat (2.1.4-2) unstable; urgency=low
+
+ * Dependancy on uuid-runtime for heartbeat-gui
+
+ Unfortuantely the 2.1.3-7 of this fix made it into upstream 2.1.4
+ but not the 2.1.3-8 version of the fix. This should rectify this
+ problem, again...
+
+ Patch: medium_debian_uuid-duntime__e2fsprogs_dependancy_for_heartbeat-gui.patch
+ Upstream-status: Pending
+ (closes: #484868)
+
+ * Dependancy on ${shlibs:Depends} for heartbeat-gui
+ As per lintian error "missing-dependency-on-libc"
+
+ * Dependancy on python-xml for heartbeat-gui
+ (closes: #496951)
+
+ * Pass --enable-libc-malloc to configure.
+ --enable-glib-malloc was a typo.
+
+ Upstream-satatus: Pending
+
+ -- Simon Horman Fri, 29 Aug 2008 04:34:10 +0000
heartbeat (2.1.4-1) unstable; urgency=low
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/debian/rules new/heartbeat/debian/rules
--- old/heartbeat/debian/rules 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/debian/rules 2008-09-15 13:12:56.000000000 +0200
@@ -53,10 +53,10 @@
debian/ldirectord.default
# Add here commands to clean up after the build process.
- -$(MAKE) clean
- -$(MAKE) distclean
+ [ ! -f Makefile ] || $(MAKE) clean
+ [ ! -f Makefile ] || $(MAKE) distclean
rm -f tools/ccdv
- -find . -name '*.py[co]' | xargs rm -f
+ find . -name '*.py[co]' | xargs rm -f
# Zero autoconf foo
rm -f config.status libltdl/config.log libltdl/config.status
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/.hg_archival.txt new/heartbeat/.hg_archival.txt
--- old/heartbeat/.hg_archival.txt 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/.hg_archival.txt 2008-09-15 13:12:56.000000000 +0200
@@ -1,2 +1,2 @@
repo: 8448b17e67437947c48c639c6faa4371c4a14b3b
-node: e8154a602bf43be0cf864f363e9b463e35cbf24c
+node: 28869f4835db932df7a685f75e9a56fe0061870a
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/ldirectord/ldirectord.in new/heartbeat/ldirectord/ldirectord.in
--- old/heartbeat/ldirectord/ldirectord.in 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/ldirectord/ldirectord.in 2008-09-15 13:12:56.000000000 +0200
@@ -184,6 +184,15 @@
If defined in a virtual server section then the global value is overridden.
+BI<path to script>B<">
+
+If this directive is defined, the supplied script is executed whenever all
+real servers for a virtual service are down or when the first real server
+comes up again. In the first case, it is called with "start" as its first
+argument, in the latter with "stop".
+
+If defined in a virtual server section then the global value is overridden.
+
BIB<">|syslog_facility
An alternative logfile might be specified with this directive. If the logfile
@@ -618,6 +627,7 @@
$CONFIG
$DEBUG
$FALLBACK
+ $FALLBACKCOMMAND
$SUPERVISED
$IPVSADM
$checksum
@@ -1303,6 +1313,9 @@
$vsrv{fallback} =
parse_fallback($line, $1,
\%vsrv);
+ } elsif ($rcmd =~ /^fallbackcommand\s*=\s*(.*)/) {
+ $1 =~ /(.+)/ or &config_error($line, "invalid fallback command");
+ $vsrv{fallbackcommand} = $1;
} elsif ($rcmd =~ /^quiescent\s*=\s*(.*)/) {
($1 eq "yes" || $1 eq "no")
or &config_error($line, "quiescent must be 'yes' or 'no'");
@@ -1381,6 +1394,9 @@
&_ld_read_config_fallback_resolve($line, "tcp", $tcp);
&_ld_read_config_fallback_resolve($line, "udp", $udp);
$FALLBACK = { "tcp" => $tcp, "udp" => $udp };
+ } elsif ($linedata =~ /^fallbackcommand\s*=\s*(.*)/) {
+ $1 =~ /(.+)/ or &config_error($line, "invalid fallback command");
+ $FALLBACKCOMMAND = $1;
} elsif ($linedata =~ /^autoreload\s*=\s*(.*)/) {
($1 eq "yes" || $1 eq "no")
or &config_error($line,
@@ -3652,14 +3668,16 @@
my $fallback=&fallback_find($v);
- if (! defined($fallback) or (! _status_up($v, $fallback, "fallback")
- and ! defined($force))) {
- return;
+ if (defined($fallback) and (_status_up($v, $fallback, "fallback")
+ or defined($force))) {
+ &_restore_service($v, $fallback->{server} . ":" . $fallback->{port},
+ get_forward_flag($fallback->{forward}),
+ "1", "fallback");
}
- &_restore_service($v, $fallback->{server} . ":" . $fallback->{port},
- get_forward_flag($fallback->{forward}),
- "1", "fallback");
+ if (!defined ($v->{real_status})) {
+ &do_fallback_command($v, "start");
+ }
}
@@ -3675,14 +3693,16 @@
my $fallback=&fallback_find($v);
- if (! defined($fallback) or (! _status_down($v, $fallback, "fallback")
- and ! defined($force))) {
- return;
+ if (defined($fallback) and (_status_down($v, $fallback, "fallback")
+ or defined($force))) {
+ &_remove_service($v, $fallback->{server} . ":" . $fallback->{port},
+ get_forward_flag($fallback->{forward}),
+ "fallback");
}
- &_remove_service($v, $fallback->{server} . ":" . $fallback->{port},
- get_forward_flag($fallback->{forward}),
- "fallback");
+ if (defined ($v->{real_status})) {
+ &do_fallback_command($v, "stop");
+ }
}
@@ -3717,6 +3737,27 @@
}
+# fallback_command
+# Execute the fallback command with the given status if it wasn't executed
+# with this status already for the supplied virtual service.
+
+sub do_fallback_command()
+{
+ my ($v, $status) = (@_);
+
+ if (defined $v->{fallbackcommand_status} and $v->{fallbackcommand_status} eq $status) {
+ return;
+ }
+
+ $v->{fallbackcommand_status} = $status;
+
+ if (defined($v->{fallbackcommand})) {
+ &system_wrapper($v->{fallbackcommand} . " " . $status);
+ } elsif (defined($FALLBACKCOMMAND)) {
+ &system_wrapper($FALLBACKCOMMAND . " " . $status);
+ }
+}
+
# Used during stop, start and reload to remove stale real servers from LVS
sub purge_untracked_service
{
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/lib/apphb/Makefile.am new/heartbeat/lib/apphb/Makefile.am
--- old/heartbeat/lib/apphb/Makefile.am 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/lib/apphb/Makefile.am 2008-09-15 13:12:56.000000000 +0200
@@ -38,4 +38,4 @@
libapphb_la_CFLAGS = -lpthread
endif
-libapphb_la_LDFLAGS = -version-info 0:0:0
+libapphb_la_LDFLAGS = -version-info 2:0:0
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/lib/lrm/Makefile.am new/heartbeat/lib/lrm/Makefile.am
--- old/heartbeat/lib/lrm/Makefile.am 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/lib/lrm/Makefile.am 2008-09-15 13:12:56.000000000 +0200
@@ -33,6 +33,7 @@
lib_LTLIBRARIES = liblrm.la
liblrm_la_SOURCES = lrm_msg.c clientlib.c racommon.c
+liblrm_la_LDFLAGS = -version-info 2:0:0
liblrm_la_LDFLAGS = $(COMMONLIBS)
liblrm_la_CFLAGS = $(INCLUDES)
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/lib/pils/Makefile.am new/heartbeat/lib/pils/Makefile.am
--- old/heartbeat/lib/pils/Makefile.am 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/lib/pils/Makefile.am 2008-09-15 13:12:56.000000000 +0200
@@ -50,7 +50,7 @@
plugin_LTLIBRARIES = test.la
libpils_la_SOURCES = pils.c
-libpils_la_LDFLAGS = -version-info 1:0:0
+libpils_la_LDFLAGS = -version-info 2:0:0
libpils_la_LIBADD = $(top_builddir)/replace/libreplace.la \
@LIBLTDL@ $(GLIBLIB)
test_la_SOURCES = test.c
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/lib/stonith/sbd.c new/heartbeat/lib/stonith/sbd.c
--- old/heartbeat/lib/stonith/sbd.c 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/lib/stonith/sbd.c 2008-09-15 13:12:56.000000000 +0200
@@ -685,11 +685,6 @@
close(2);
(void)open(devnull, O_WRONLY);
cl_cdtocoredir();
- if (getsid(0) != pid) {
- if (setsid() < 0) {
- cl_perror("setsid() failure.");
- }
- }
cl_make_realtime(-1, -1, 128, 128);
}
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/resources/OCF/Filesystem new/heartbeat/resources/OCF/Filesystem
--- old/heartbeat/resources/OCF/Filesystem 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/resources/OCF/Filesystem 2008-09-15 13:12:56.000000000 +0200
@@ -127,26 +127,6 @@
<content type="string" default="" />
</parameter>
-<parameter name="ocfs2_cluster">
-<longdesc lang="en">
-The name (UUID) of the OCFS2 cluster this filesystem is part of,
-iff this is an OCFS2 resource and there's more than one cluster. You
-should not need to specify this.
-</longdesc>
-<shortdesc lang="en">OCFS2 cluster name/UUID</shortdesc>
-<content type="string" default="" />
-</parameter>
-
-<parameter name="ocfs2_configfs">
-<longdesc lang="en">
-Mountpoint of the cluster hierarchy below configfs. You should not
-need to specify this.
-</longdesc>
-<shortdesc lang="en">OCFS2 configfs root</shortdesc>
-<content type="string" default="" />
-</parameter>
-</parameters>
-
<actions>
<action name="start" timeout="60" />
<action name="stop" timeout="60" />
@@ -210,133 +190,11 @@
list_mounts | grep " $1/" | cut -d' ' -f2 | sort -r
}
-ocfs2_del_cache() {
- if [ -e "$_OCFS2_uuid_cache" ]; then
- rm -f $_OCFS2_uuid_cache 2>/dev/null
- fi
-}
-
-ocfs2_cleanup() {
- # We'll never see the post-stop notification. We're gone now,
- # have unmounted, and thus should remove the membership.
- #
- # (Do so regardless of whether we were unmounted already,
- # because the admin might have manually unmounted but not
- # cleared up the membership directory. Bad admin, no cookie.)
- #
- if [ ! -d "$OCFS2_FS_ROOT" ]; then
- ocf_log info "$OCFS2_FS_ROOT: Filesystem membership already gone."
- else
- ocf_log info "$OCFS2_FS_ROOT: Removing membership directory."
- rm -rf $OCFS2_FS_ROOT/
- fi
-
- ocfs2_del_cache
-}
-
-ocfs2_fetch_uuid() {
- mounted.ocfs2 -d $DEVICE|tail -1|awk '{print $3}'|tr -d -- -|tr '[a-z]' '[A-Z]'
-}
-
-ocfs2_set_uuid() {
- _OCFS2_uuid_cache="$HA_RSCTMP/Filesystem.ocfs2_uuid.$(echo $DEVICE|tr / .)"
-
- if [ "$OP" != "start" -a -e "$_OCFS2_uuid_cache" ]; then
- # Trust the cache.
- OCFS2_UUID=$(cat $_OCFS2_uuid_cache 2>/dev/null)
- return 0
- fi
-
- OCFS2_UUID=$(ocfs2_fetch_uuid)
- if [ -n "$OCFS2_UUID" -a "$OCFS2_UUID" != "UUID" ]; then
- # UUID valid:
- echo $OCFS2_UUID > $_OCFS2_uuid_cache
- return 0
- fi
-
- # Ok, no UUID still, but that's alright for stop, because it
- # very likely means we never got started -
- if [ "$OP" = "stop" ]; then
- ocf_log warn "$DEVICE: No UUID; assuming never started!"
- OCFS2_UUID="UUID_NOT_SET"
- return 0
- fi
-
- # Everything else - wrong:
- ocf_log err "$DEVICE: Could not determine ocfs2 UUID for device."
- exit $OCF_ERR_GENERIC
-}
-
-ocfs2_init()
-{
- # Check & initialize the OCFS2 specific variables.
-
- if [ $OP != "stop" ]; then
- if [ -z "$OCF_RESKEY_CRM_meta_clone" ]; then
- ocf_log err "ocfs2 must be run as a clone."
- exit $OCF_ERR_GENERIC
- fi
- fi
-
- if [ $blockdevice = "no" ]; then
- ocf_log err "$DEVICE: ocfs2 needs a block device instead."
- exit $OCF_ERR_GENERIC
- fi
-
- for f in "$OCF_RESKEY_ocfs2_configfs" /sys/kernel/config/cluster /configfs/cluster ; do
- if [ -n "$f" -a -d "$f" ]; then
- OCFS2_CONFIGFS="$f"
- break
- fi
- done
- if [ ! -d "$OCFS2_CONFIGFS" ]; then
- ocf_log err "ocfs2 needs configfs mounted."
- exit $OCF_ERR_GENERIC
- fi
-
- ocfs2_set_uuid
-
- if [ -n "$OCF_RESKEY_ocfs2_cluster" ]; then
- OCFS2_CLUSTER=$(echo $OCF_RESKEY_ocfs2_cluster)
- else
- OCFS2_CLUSTER=$(find "$OCFS2_CONFIGFS" -maxdepth 1 -mindepth 1 -type d -printf %f 2>/dev/null)
- set -- $OCFS2_CLUSTER
- local n; n="$#"
- if [ $n -gt 1 ]; then
- ocf_log err "$OCFS2_CLUSTER: several clusters found."
- exit $OCF_ERR_GENERIC
- fi
- if [ $n -eq 0 ]; then
- ocf_log err "$OCFS2_CONFIGFS: no clusters found."
- exit $OCF_ERR_GENERIC
- fi
- fi
-
- OCFS2_CLUSTER_ROOT="$OCFS2_CONFIGFS/$OCFS2_CLUSTER"
- if [ ! -d "$OCFS2_CLUSTER_ROOT" ]; then
- ocf_log err "$OCFS2_CLUSTER: Cluster doesn't exist. Maybe o2cb hasn't been run?"
- exit $OCF_ERR_GENERIC
- fi
-
- OCFS2_FS_ROOT=$OCFS2_CLUSTER_ROOT/heartbeat/$OCFS2_UUID
-}
-
#
# START: Start up the filesystem
#
Filesystem_start()
{
- if [ "$FSTYPE" = "ocfs2" ]; then
- # "start" now has the notification data available; that
- # we're being started means we didn't get the
- # pre-notification, because we weren't running, so
- # process the information now first.
- ocf_log info "$OCFS2_UUID: Faking pre-notification on start."
- OCF_RESKEY_CRM_meta_notify_type="pre"
- OCF_RESKEY_CRM_meta_notify_operation="start"
- Filesystem_notify
- fi
-
# See if the device is already mounted.
if Filesystem_status >/dev/null 2>&1 ; then
ocf_log info "Filesystem $MOUNTPOINT is already mounted."
@@ -374,7 +232,7 @@
if
case $FSTYPE in
- ext3|reiserfs|reiser4|nss|xfs|jfs|vfat|fat|nfs|cifs|smbfs|ocfs2|lustre) false;;
+ ext3|reiserfs|reiser4|nss|xfs|jfs|vfat|fat|nfs|cifs|smbfs|ocfs2|gfs2|lustre) false;;
*) true;;
esac
then
@@ -409,164 +267,11 @@
if [ $? -ne 0 ]; then
ocf_log err "Couldn't mount filesystem $DEVICE on $MOUNTPOINT"
- if [ "$FSTYPE" = "ocfs2" ]; then
- ocfs2_cleanup
- fi
return $OCF_ERR_GENERIC
fi
return 0
}
-# end of Filesystem_start
-
-Filesystem_notify() {
- # Process notifications; this is the essential glue level for
- # giving user-space membership events to a cluster-aware
- # filesystem. Right now, only OCFS2 is supported.
- #
- # When we get a pre-start notification, we set up all the nodes
- # which will be active in our membership for the filesystem.
- # (For the resource to be started, this happens at the time of
- # the actual 'start' operation.)
- #
- # At a post-start, actually there's nothing to do for us really,
- # but no harm done in re-syncing either.
- #
- # pre-stop is meaningless; we can't remove any node yet, it
- # first needs to unmount.
- #
- # post-stop: the node is removed from the membership of the
- # other nodes.
- #
- # Note that this expects that the base cluster is already
- # active; ie o2cb has been started and populated
- # $OCFS2_CLUSTER_ROOT/node/ already. This can be achieved by
- # simply having o2cb run on all nodes by the CRM too. This
- # probably ought to be mentioned somewhere in the to be written
- # documentation. ;-)
- #
-
- if [ "$FSTYPE" != "ocfs2" ]; then
- # One of the cases which shouldn't occur; it should have
- # been caught much earlier. Still, you know ...
- ocf_log warn "$DEVICE: Notification received for non-ocfs2 mount."
- return $OCF_ERR_UNIMPLEMENTED
- fi
-
- local n_type; n_type="$OCF_RESKEY_CRM_meta_notify_type"
- local n_op; n_op="$OCF_RESKEY_CRM_meta_notify_operation"
- local n_active; n_active="$OCF_RESKEY_CRM_meta_notify_active_uname"
- local n_stop; n_stop="$OCF_RESKEY_CRM_meta_notify_stop_uname"
- local n_start; n_start="$OCF_RESKEY_CRM_meta_notify_start_uname"
-
- ocf_log info "$OCFS2_UUID: notify: $n_type for $n_op"
- ocf_log info "$OCFS2_UUID: notify active: $n_active"
- ocf_log info "$OCFS2_UUID: notify stop: $n_stop"
- ocf_log info "$OCFS2_UUID: notify start: $n_start"
-
- case "$n_type" in
- pre)
- case "$n_op" in
- stop)
- ocf_log info "$OCFS2_UUID: ignoring pre-notify for stop."
- return $OCF_SUCCESS
- ;;
- start)
- # These are about to become active; prepare to
- # communicate with them.
- # Duplicate removal - start can contain nodes
- # already on the active list, confusing the
- # script later on:
- for UNAME in $n_active; do
- n_start=`echo ${n_start} | sed s/$UNAME//`
- done
- # Merge pruned lists again:
- n_active="$n_active $n_start"
- ;;
- esac
- ;;
- post)
- case "$n_op" in
- stop)
- # remove unames from notify_stop_uname; these have been
- # stopped and can no longer be considered active.
- for UNAME in $n_stop; do
- n_active=`echo ${n_active} | sed s/$UNAME//`
- done
- ;;
- start)
- if [ "$n_op" = "start" ]; then
- ocf_log info "$OCFS2_UUID: ignoring post-notify for start."
- return $OCF_SUCCESS
- fi
- ;;
- esac
- ;;
- esac
-
- ocf_log info "$OCFS2_UUID: post-processed active: $n_active"
-
- local n_myself; n_myself=${HA_CURHOST:-$(uname -n | tr '[A-Z]' '[a-z]')}
- ocf_log info "$OCFS2_UUID: I am node $n_myself."
-
- case " $n_active " in
- *" $n_myself "*) ;;
- *) ocf_log err "$OCFS2_UUID: $n_myself (local) not on active list!"
- return $OCF_ERR_GENERIC
- ;;
- esac
-
- if [ -d "$OCFS2_FS_ROOT" ]; then
- entry_prefix=$OCFS2_FS_ROOT/
- for entry in $OCFS2_FS_ROOT/* ; do
- n_fs="${entry##$entry_prefix}"
- # ocf_log info "$OCFS2_UUID: Found current node $n_fs"
- case " $n_active " in
- *" $n_fs "*)
- # Construct a list of nodes which are present
- # already in the membership.
- n_exists="$n_exists $n_fs"
- ocf_log info "$OCFS2_UUID: Keeping node: $n_fs"
- ;;
- *)
- # Node is in the membership currently, but not on our
- # active list. Must be removed.
- if [ "$n_op" = "start" ]; then
- ocf_log warn "$OCFS2_UUID: Removing nodes on start"
- fi
- ocf_log info "$OCFS2_UUID: Removing dead node: $n_fs"
- if ! rm -f $entry ; then
- ocf_log err "$OCFS2_UUID: Removal of $n_fs failed!"
- fi
- ;;
- esac
- done
- else
- ocf_log info "$OCFS2_UUID: heartbeat directory doesn't exist yet, creating."
- mkdir -p $OCFS2_FS_ROOT
- fi
-
- ocf_log info "$OCFS2_UUID: Existing node list: $n_exists"
-
- # (2)
- for entry in $n_active ; do
- # ocf_log info "$OCFS2_UUID: Expected active node: $entry"
- case " $n_exists " in
- *" $entry "*)
- ocf_log info "$OCFS2_UUID: Already active: $entry"
- ;;
- *)
- if [ "$n_op" = "stop" ]; then
- ocf_log warn "$OCFS2_UUID: Adding nodes on stop"
- fi
- ocf_log info "$OCFS2_UUID: Activating node: $entry"
- if ! ln -s $OCFS2_CLUSTER_ROOT/node/$entry $OCFS2_FS_ROOT/$entry ; then
- ocf_log err "$OCFS2_CLUSTER_ROOT/node/$entry: failed to link"
- fi
- ;;
- esac
- done
-}
#
# STOP: Unmount the filesystem
@@ -627,13 +332,6 @@
flushbufs $DEVICE
- if [ $rc -eq $OCF_SUCCESS ]; then
- if [ "$FSTYPE" = "ocfs2" ]; then
- ocfs2_init
- ocfs2_cleanup
- fi
- fi
-
return $rc
}
# end of Filesystem_stop
@@ -776,8 +474,7 @@
ocf_log info "Running $OP for $DEVICE on $MOUNTPOINT"
fi
-# These operations do not require the clone checking + OCFS2
-# initialization.
+# These operations do not require the clone checking
case $OP in
status|monitor) Filesystem_status
exit $?
@@ -791,15 +488,13 @@
esac
case $FSTYPE in
-ocfs2) ocfs2_init
- ;;
-nfs) : # this is kind of safe too
+bind|nfs|ocfs2|gfs2) : # this is kind of safe too
;;
*) if [ -n "$OCF_RESKEY_CRM_meta_clone" ]; then
ocf_log err "DANGER! $FSTYPE on $DEVICE is NOT cluster-aware!"
ocf_log err "DO NOT RUN IT AS A CLONE!"
ocf_log err "Politely refusing to proceed to avoid data corruption."
- exit $OCF_ERR_GENERIC
+ exit $OCF_ERR_CONFIGURED
fi
;;
esac
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/heartbeat/resources/OCF/mysql new/heartbeat/resources/OCF/mysql
--- old/heartbeat/resources/OCF/mysql 2008-09-09 21:11:23.000000000 +0200
+++ new/heartbeat/resources/OCF/mysql 2008-09-15 13:12:56.000000000 +0200
@@ -324,7 +324,7 @@
chmod 0640 $OCF_RESKEY_log
[ -x /sbin/restorecon ] && /sbin/restorecon $OCF_RESKEY_log
- if [ "$OCF_RESKEY_enable_creation" = 1 -a ! -d $OCF_RESKEY_datadir/mysql] ; then
+ if [ "$OCF_RESKEY_enable_creation" = 1 -a ! -d $OCF_RESKEY_datadir/mysql ] ; then
ocf_log info "Initializing MySQL database: "
$MYSQL_BINDIR/mysql_install_db --datadir=$OCF_RESKEY_datadir
rc=$?
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org