From 2c4ed5b2f65970cdd961e0e2ce478bd669d10fc4 Mon Sep 17 00:00:00 2001 From: Kevin Fenzi Date: Mar 03 2009 01:26:27 +0000 Subject: 2.1.4 for epel5 --- diff --git a/.cvsignore b/.cvsignore index ed37a95..3166f03 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1 +1 @@ -heartbeat-2.0.8.tar.gz +STABLE-2.1.4.tar.bz2 diff --git a/heartbeat-2.1.4-default-init.patch b/heartbeat-2.1.4-default-init.patch new file mode 100644 index 0000000..ac1c23e --- /dev/null +++ b/heartbeat-2.1.4-default-init.patch @@ -0,0 +1,12 @@ +diff -Nur Heartbeat-STABLE-2-1-STABLE-2.1.4.orig/heartbeat/init.d/heartbeat.in Heartbeat-STABLE-2-1-STABLE-2.1.4/heartbeat/init.d/heartbeat.in +--- Heartbeat-STABLE-2-1-STABLE-2.1.4.orig/heartbeat/init.d/heartbeat.in 2008-08-18 06:32:19.000000000 -0600 ++++ Heartbeat-STABLE-2-1-STABLE-2.1.4/heartbeat/init.d/heartbeat.in 2008-12-01 20:23:23.000000000 -0700 +@@ -12,7 +12,7 @@ + # We don't hate anyone, and like for everyone to use + # our software, no matter what OS or distribution you're using. + # +-# chkconfig: 2345 @HB_INITSTARTPRI@ @HB_INITSTOPPRI@ ++# chkconfig: - @HB_INITSTARTPRI@ @HB_INITSTOPPRI@ + # description: Startup script high-availability services. + # processname: heartbeat + # pidfile: @localstatedir@/run/heartbeat.pid diff --git a/heartbeat-fedora-ccmuser.patch b/heartbeat-fedora-ccmuser.patch deleted file mode 100644 index 68cbe26..0000000 --- a/heartbeat-fedora-ccmuser.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -Nur heartbeat-2.0.4.orig/cts/CM_LinuxHAv2.py.in heartbeat-2.0.4/cts/CM_LinuxHAv2.py.in ---- heartbeat-2.0.4.orig/cts/CM_LinuxHAv2.py.in 2006-02-27 10:19:42.000000000 +0100 -+++ heartbeat-2.0.4/cts/CM_LinuxHAv2.py.in 2006-03-27 19:49:36.000000000 +0200 -@@ -155,7 +155,7 @@ - "root@" + (self["CIBfile"]%node)): - raise ValueError("Can not scp file to %s "%node) - -- self.rsh.remote_python_call(node, "os", "system", "chown @HA_CCMUID@ @HA_VARLIBDIR@/heartbeat/crm/cib.xml") -+ self.rsh.remote_python_call(node, "os", "system", "chown @HA_CCMUSER@ @HA_VARLIBDIR@/heartbeat/crm/cib.xml") - - def prepare(self): - '''Finish the Initialization process. Prepare to test...''' diff --git a/heartbeat-fedora-chkconfig.patch b/heartbeat-fedora-chkconfig.patch deleted file mode 100644 index 4ae3445..0000000 --- a/heartbeat-fedora-chkconfig.patch +++ /dev/null @@ -1,63 +0,0 @@ -diff -Nur heartbeat-2.0.5.orig/heartbeat/init.d/heartbeat.in heartbeat-2.0.5/heartbeat/init.d/heartbeat.in ---- heartbeat-2.0.5.orig/heartbeat/init.d/heartbeat.in 2006-04-14 21:25:33.000000000 +0200 -+++ heartbeat-2.0.5/heartbeat/init.d/heartbeat.in 2006-04-27 20:32:29.000000000 +0200 -@@ -13,7 +13,7 @@ - # We don't hate anyone, and like for everyone to use - # our software, no matter what OS or distribution you're using. - # --# chkconfig: 2345 @HB_INITSTARTPRI@ @HB_INITSTOPPRI@ -+# chkconfig: - @HB_INITSTARTPRI@ @HB_INITSTOPPRI@ - # description: Startup script high-availability services. - # processname: heartbeat - # pidfile: @localstatedir@/run/heartbeat.pid -@@ -391,12 +391,7 @@ - StartHA - RC=$? - Echo -- if -- [ $RC -eq 0 ] -- then -- [ ! -d $LOCKDIR ] && mkdir -p $LOCKDIR -- touch $LOCKDIR/$SUBSYS -- fi -+ [ $RC -eq 0 ] && touch /var/lock/subsys/heartbeat - RunStartStop post-start $RC - ;; - -@@ -413,11 +408,7 @@ - StopHA - RC=$? - Echo -- if -- [ $RC -eq 0 ] -- then -- rm -f $LOCKDIR/$SUBSYS -- fi -+ [ $RC -eq 0 ] && rm -f /var/lock/subsys/heartbeat - RunStartStop post-stop $RC - StopLogd - ;; -diff -Nur heartbeat-2.0.5.orig/ldirectord/init.d/ldirectord heartbeat-2.0.5/ldirectord/init.d/ldirectord ---- heartbeat-2.0.5.orig/ldirectord/init.d/ldirectord 2005-10-17 14:49:21.000000000 +0200 -+++ heartbeat-2.0.5/ldirectord/init.d/ldirectord 2006-04-27 20:33:35.000000000 +0200 -@@ -2,7 +2,7 @@ - # - # ldirectord Linux Director Daemon - # --# chkconfig: 2345 92 40 -+# chkconfig: - 92 40 - # description: Start and stop ldirectord on non-heartbeat systems - # Using the config file /etc/ha.d/ldirectord.cf - # -@@ -59,9 +59,11 @@ - case "$1" in - start) - action "Starting ldirectord" $DAEMON start -+ touch /var/lock/subsys/ldirectord - ;; - stop) - action "Stopping ldirectord" $DAEMON stop -+ rm -f /var/lock/subsys/ldirectord - ;; - restart) - action "Restarting ldirectord" $DAEMON restart diff --git a/heartbeat.spec b/heartbeat.spec index 3bf02a2..5aa4cf6 100644 --- a/heartbeat.spec +++ b/heartbeat.spec @@ -5,14 +5,14 @@ %define uname hacluster Summary: Heartbeat subsystem for High-Availability Linux Name: heartbeat -Version: 2.0.8 -Release: 2%{?dist} -License: GPL/LGPL +Version: 2.1.4 +Release: 6%{?dist} +License: GPLv2 and LGPLv2+ URL: http://linux-ha.org/ Group: System Environment/Daemons -Source0: http://linux-ha.org/download/%{name}-%{version}.tar.gz +Source0: http://hg.linux-ha.org/lha-2.1/archive/STABLE-%{version}.tar.bz2 Patch0: heartbeat-fedora-pam.patch -Patch1: heartbeat-fedora-chkconfig.patch +Patch1: heartbeat-2.1.4-default-init.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: glib2-devel BuildRequires: iputils @@ -21,18 +21,21 @@ BuildRequires: libtool-ltdl-devel BuildRequires: net-snmp-devel >= 5.4 BuildRequires: bzip2-devel BuildRequires: ncurses-devel +BuildRequires: openssl-devel +BuildRequires: libtool +BuildRequires: libxml2-devel +BuildRequires: gettext +BuildRequires: bison +BuildRequires: flex %if %{ENABLE_MGMT} BuildRequires: gnutls-devel BuildRequires: pam-devel BuildRequires: python-devel BuildRequires: swig %endif -Requires: stonith = %{version}-%{release} -Requires: pils = %{version}-%{release} Requires: ldirectord = %{version}-%{release} -Requires: pygtk2 >= 2.4 -Requires(pre): fedora-usermgmt -Requires(postun): fedora-usermgmt +Requires: PyXML +Requires(pre): shadow-utils Requires(post): /sbin/chkconfig Requires(preun): /sbin/chkconfig %if %{ENABLE_MGMT} @@ -57,37 +60,42 @@ It implements the following kinds of heartbeats: - "ping" heartbeats (for routers, switches, etc.) (to be used for breaking ties in 2-node systems) -%package -n ldirectord +%package ldirectord Summary: Monitor daemon for maintaining high availability resources Group: System Environment/Daemons Requires: ipvsadm Requires(post): /sbin/chkconfig Requires(preun): /sbin/chkconfig +Provides: ldirectord = %{version}-%{release} +Obsoletes: ldirectord < 2.1.4-5 -%description -n ldirectord +%description ldirectord ldirectord is a stand-alone daemon to monitor services of real for virtual services provided by The Linux Virtual Server (http://www.linuxvirtualserver.org/). It is simple to install and works with the heartbeat code (http://www.linux-ha.org/). -%package -n stonith -Requires: pils = %{version}-%{release} +%package stonith Requires: net-snmp-libs Summary: Provides an interface to Shoot The Other Node In The Head Group: System Environment/Daemons +Provides: stonith = %{version}-%{release} +Obsoletes: stonith < 2.1.4-5 -%description -n stonith -The STONITH module (a.k.a. STOMITH) provides an extensible interface +%description stonith +The STONITH module (a.k.a. STONITH) provides an extensible interface for remotely powering down a node in the cluster. The idea is quite simple: When the software running on one machine wants to make sure another machine in the cluster is not using a resource, pull the plug on the other machine. It's simple and reliable, albeit admittedly brutal. -%package -n pils +%package pils Summary: Provides a general plugin and interface loading library Group: System Environment/Daemons +Provides: pils = %{version}-%{release} +Obsoletes: pils < 2.1.4-5 -%description -n pils +%description pils PILS is an generalized and portable open source Plugin and Interface Loading System. PILS was developed as part of the Open Cluster Framework reference implementation, and is designed to be directly usable by a wide variety of @@ -104,15 +112,27 @@ Requires: heartbeat = %{version}-%{release} %description devel Heartbeat development package +%package gui +Summary: Provides a gui interface to manage heartbeat clusters +Group: System Environment/Daemons +Requires: heartbeat = %{version}-%{release} +Requires: PyXML +Requires: pygtk2 >= 2.4 + +%description gui +GUI client for Heartbeat clusters + %prep -%setup -q +%setup -q -n Heartbeat-STABLE-2-1-STABLE-%{version} %patch0 -p1 %patch1 -p1 %build +./bootstrap # disable-fatal-warnings flag used to disable gcc4.x warnings of 'difference in signedness' CFLAGS=${RPM_OPT_FLAGS} \ %configure \ + --with-ocf-root=%{_datadir}/ocf \ --disable-fatal-warnings \ --disable-static \ %if %{ENABLE_MGMT} @@ -120,16 +140,17 @@ CFLAGS=${RPM_OPT_FLAGS} \ %else --disable-mgmt %endif -make + +# get rid of rpath +sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool +sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool + +make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT make DESTDIR=$RPM_BUILD_ROOT install -( - cd $RPM_BUILD_ROOT/etc/ha.d/resource.d - ln -s /usr/sbin/ldirectord ldirectord -) # cleanup [ -d $RPM_BUILD_ROOT/usr/man ] && rm -rf $RPM_BUILD_ROOT/usr/man @@ -142,55 +163,61 @@ chmod -x $RPM_BUILD_ROOT/%{_libdir}/heartbeat/ocf-shellfuncs chmod -x $RPM_BUILD_ROOT/%{_sysconfdir}/ha.d/shellfuncs chmod -x $RPM_BUILD_ROOT/%{_libdir}/heartbeat-gui/pymgmt.py +# fix some wrong line endings issues +sed -i 's/\r//' $RPM_BUILD_ROOT/%{_datadir}/ocf/resource.d/heartbeat/SAPDatabase +sed -i 's/\r//' $RPM_BUILD_ROOT/%{_datadir}/ocf/resource.d/heartbeat/SAPInstance + +%find_lang haclient + %clean -if [ -n "${RPM_BUILD_ROOT}" -a "${RPM_BUILD_ROOT}" != "/" ]; then - rm -rf $RPM_BUILD_ROOT -fi -rm -rf $RPM_BUILD_DIR/heartbeat-%{version} +rm -rf $RPM_BUILD_ROOT %pre -/usr/sbin/fedora-groupadd %{uid} -r %{gname} &>/dev/null || : -/usr/sbin/fedora-useradd %{uid} -r -s /sbin/nologin -d /var/lib/heartbeat/cores/hacluster -M \ - -c 'heartbeat user' -g %{gname} %{uname} &>/dev/null || : +getent group %{gname} >/dev/null || groupadd -r %{gname} +getent passwd %{uname} >/dev/null || \ +useradd -r -g %{gname} -d /var/lib/heartbeat/cores/hacluster -s /sbin/nologin \ +-c "heartbeat user" %{uname} +exit 0 %post /sbin/ldconfig /sbin/chkconfig --add heartbeat +%postun -p /sbin/ldconfig + %preun if [ $1 = 0 ] ; then /sbin/service heartbeat stop /sbin/chkconfig --del heartbeat fi -%postun -if [ "$1" -ge "1" ] ; then - /sbin/service heartbeat restart -fi /sbin/ldconfig -test "$1" != 0 || /usr/sbin/fedora-userdel %{uname} &>/dev/null || : -test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} &>/dev/null || : -%post -n ldirectord +%post ldirectord /sbin/chkconfig --add ldirectord -%preun -n ldirectord +%postun ldirectord -p /sbin/ldconfig + +%preun ldirectord /sbin/chkconfig --del ldirectord -%post -n stonith -p /sbin/ldconfig +%post stonith -p /sbin/ldconfig + +%postun stonith -p /sbin/ldconfig + +%post pils -p /sbin/ldconfig -%postun -n stonith -p /sbin/ldconfig +%postun pils -p /sbin/ldconfig -%files +%files -f haclient.lang %doc %{_datadir}/doc/%{name}-%{version} -%defattr(-,root,root) +%defattr(-,root,root,-) %dir %{_sysconfdir}/ha.d %{_sysconfdir}/ha.d/harc %config(noreplace) %{_sysconfdir}/ha.d/shellfuncs %{_sysconfdir}/ha.d/rc.d %config(noreplace) %{_sysconfdir}/ha.d/README.config %{_libdir}/heartbeat -%{_libdir}/heartbeat-gui %{_libdir}/libapphb.so.* %{_libdir}/libccmclient.so.* %{_libdir}/libcib.so.* @@ -204,7 +231,10 @@ test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} &>/dev/null || : %{_libdir}/libplumbgpl.so.* %{_libdir}/librecoverymgr.so.* %{_libdir}/libstonithd.so.* -%{_prefix}/lib/ocf +%{_libdir}/libpe_rules.so.* +%{_libdir}/libpe_status.so.* +%{_datadir}/heartbeat/ +%{_datadir}/ocf/ %{_sysconfdir}/ha.d/resource.d/ %exclude %{_sysconfdir}/ha.d/resource.d/ldirectord %{_sysconfdir}/init.d/heartbeat @@ -217,6 +247,8 @@ test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} &>/dev/null || : %dir %{_var}/run/heartbeat %attr (2755, hacluster, haclient) %{_bindir}/cl_status %{_bindir}/cl_respawn +%{_sbindir}/ciblint +%{_sbindir}/hb_report %{_sbindir}/crmadmin %{_sbindir}/cibadmin %{_sbindir}/ccm_tool @@ -233,6 +265,8 @@ test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} &>/dev/null || : %{_sbindir}/attrd_updater %{_sbindir}/crm_failcount %{_sbindir}/ocf-tester +%{_sbindir}/ha_logger +%{_sbindir}/ptest %dir %attr (755, hacluster, haclient) %{_var}/run/heartbeat/ccm %dir %attr (755, hacluster, haclient) %{_var}/run/heartbeat/crm %dir %attr (755, hacluster, haclient) %{_var}/lib/heartbeat/crm @@ -257,44 +291,41 @@ test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} &>/dev/null || : %{_libdir}/libhbmgmtcommon.so.* %{_libdir}/libhbmgmttls.so.* %config(noreplace) %{_sysconfdir}/pam.d/hbmgmtd -%{_datadir}/locale/zh_CN/LC_MESSAGES/haclient.mo %endif -%files -n ldirectord +%files ldirectord %doc doc/COPYING %doc doc/README %doc ldirectord/ldirectord.cf -%defattr(-,root,root) +%defattr(-,root,root,-) %{_sbindir}/ldirectord -%{_sbindir}/supervise-ldirectord-config %config(noreplace) %{_sysconfdir}/logrotate.d/ldirectord %{_sysconfdir}/init.d/ldirectord %{_sysconfdir}/ha.d/resource.d/ldirectord %{_mandir}/man8/ldirectord.8* -%{_mandir}/man8/supervise-ldirectord-config.8* -%files -n stonith +%files stonith %doc doc/COPYING %doc doc/README -%defattr(-,root,root) -%{_libdir}/*.so.* +%defattr(-,root,root,-) +%{_libdir}/libstonith.so.* %{_libdir}/stonith/ %{_sbindir}/stonith %{_sbindir}/meatclient %{_mandir}/man8/stonith.8* %{_mandir}/man8/meatclient.8* -%files -n pils +%files pils %doc doc/COPYING %doc doc/README -%defattr(-,root,root) +%defattr(-,root,root,-) /usr/include/pils %{_libdir}/libpils.* %{_libdir}/pils/ %files devel %doc %{_datadir}/doc/%{name}-%{version} -%defattr(-,root,root) +%defattr(-,root,root,-) %{_includedir}/heartbeat/ %{_includedir}/clplumbing/ %{_includedir}/saf/ @@ -303,7 +334,79 @@ test "$1" != 0 || /usr/sbin/fedora-groupdel %{gname} &>/dev/null || : %{_includedir}/pils/ %{_libdir}/*.so +%files gui +%defattr(-,root,root) +%{_libdir}/heartbeat-gui +%{_datadir}/heartbeat-gui +%{_bindir}/hb_gui + %changelog +* Tue Feb 24 2009 Kevin Fenzi - 2.1.4-6 +- Remove symlink thats no longer needed. + +* Mon Feb 23 2009 Kevin Fenzi - 2.1.4-5 +- Remove fedora-usermgmt +- Change subpackage names to match all the other heartbeat packages out there. + +* Sat Jan 17 2009 Kevin Fenzi - 2.1.4-4 +- Main package shouldn't require pygtk2 (#480157) + +* Fri Jan 16 2009 Tomas Mraz - 2.1.4-3 +- rebuild with new openssl + +* Thu Dec 04 2008 Ignacio Vazquez-Abrams - 2.1.4-2 +- Rebuild for Python 2.6 + +* Mon Dec 01 2008 Kevin Fenzi - 2.1.4-1 +- Update to 2.1.4 +- Drop upstreamed patch +- Add patch to disable init script by default (#441286) + +* Mon Dec 01 2008 Ignacio Vazquez-Abrams - 2.1.3-4 +- Rebuild for Python 2.6 + +* Tue Oct 21 2008 Lon Hohberger - 2.1.3-3 +- Fix requires line to include PyXML (#467807) + +* Wed Jun 25 2008 Tomas Mraz - 2.1.3-2 +- rebuild with new gnutls + +* Mon Feb 25 2008 Kevin Fenzi - 2.1.3-1 +- Update to 2.1.3 +- Add management GUI +- Drop upstreamed patches +- Add patch for IPAddr (bz #434653) + +* Tue Feb 19 2008 Fedora Release Engineering - 2.1.2-4 +- Autorebuild for GCC 4.3 + +* Fri Dec 07 2007 Release Engineering - 2.1.2-3 +- Rebuild for deps + +* Tue Aug 29 2007 Kevin Fenzi - 2.1.2-2 +- Update sources + +* Tue Aug 29 2007 Kevin Fenzi - 2.1.2-1 +- Upgrade to 2.1.2 +- Update license tag for new guidelines. +- Patch open function issues. + +* Wed Aug 29 2007 Fedora Release Engineering - 2.0.8-4 +- Rebuild for selinux ppc32 issue. + +* Tue Jun 26 2007 Kevin Fenzi - 2.0.8-3 +- Add openssl-devel BuildRequires +- Remove restart from postun (bz #223949) +- Fix up Requires (bz #245704) +- Remove duplicate libraries in subpackages (bz #245704) +- Add smp_mflags +- Fix typo in stonith subpackage description +- Simplify clean section. +- Use find_lang macro +- Fix some multilib issues with ocf dir (bz #228165) +- Kill rpath +- Add ldconfig to postun + * Fri Feb 9 2007 Joost Soeterbroek - 2.0.8-2 - change condrestart -> restart (bz #223949) diff --git a/sources b/sources index b60cb63..b569d04 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -39d7d12d2a7d5c98d1e3f8ae7977a3e6 heartbeat-2.0.8.tar.gz +2e53a9996beb1ff7611d3f7300586951 STABLE-2.1.4.tar.bz2