Blame SPECS/sbd.spec

6f8c14
#
6f8c14
# spec file for package sbd
6f8c14
#
6f8c14
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
6f8c14
# Copyright (c) 2013 Lars Marowsky-Bree
6f8c14
#
6f8c14
# All modifications and additions to the file contributed by third parties
6f8c14
# remain the property of their copyright owners, unless otherwise agreed
6f8c14
# upon. The license for this file, and modifications and additions to the
6f8c14
# file, is the same license as for the pristine package itself (unless the
6f8c14
# license for the pristine package is not an Open Source License, in which
6f8c14
# case the license is the MIT License). An "Open Source License" is a
6f8c14
# license that conforms to the Open Source Definition (Version 1.9)
6f8c14
# published by the Open Source Initiative.
6f8c14
6f8c14
# Please submit bugfixes or comments via http://bugs.opensuse.org/
6f8c14
#
29e83d
%global commit 7f33d1a409d0a4e2cd69946688c48eaa8f3c5d26
6f8c14
%global shortcommit %(c=%{commit}; echo ${c:0:7})
6f8c14
%global github_owner Clusterlabs
29e83d
%global buildnum 15
6f8c14
6f8c14
Name:           sbd
6f8c14
Summary:        Storage-based death
6f8c14
License:        GPLv2+
6f8c14
Group:          System Environment/Daemons
29e83d
Version:        1.4.0
29e83d
Release:        %{buildnum}%{?dist}
6f8c14
Url:            https://github.com/%{github_owner}/%{name}
6f8c14
Source0:        https://github.com/%{github_owner}/%{name}/archive/%{commit}/%{name}-%{commit}.tar.gz
29e83d
Patch0:         0001-Fix-sbd-cluster-finalize-cmap-connection-if-disconne.patch
29e83d
Patch1:         0002-Fix-sbd-pacemaker-make-handling-of-cib-connection-lo.patch
29e83d
Patch2:         0003-Fix-sbd-pacemaker-bail-out-of-status-earlier.patch
29e83d
Patch3:         0004-Doc-sbd.8.pod-use-the-generic-term-cluster-services-.patch
29e83d
Patch4:         0005-Doc-sbd.sysconfig-watchdog-timeout-set-in-the-on-dis.patch
29e83d
Patch5:         0006-Refactor-fail-earlier-on-invalid-servants.patch
29e83d
Patch6:         0007-Fix-sbd-inquisitor-overhaul-device-list-parser.patch
29e83d
Patch7:         0008-Refactor-sbd-common-no-reason-for-stack-hogger-havin.patch
29e83d
Patch8:         0009-Sanity-sbd-inquisitor-free-timeout-action-on-bail-ou.patch
29e83d
Patch9:         0010-Sanity-sbd-md-prevent-unrealistic-overflow-on-sector.patch
29e83d
Patch10:        0011-Sanity-sbd-md-remove-some-left-over-code.patch
29e83d
Patch11:        0012-Fix-sbd-common-query-rt-budget-0-otherwise-try-movin.patch
29e83d
Patch12:        0013-Fix-sbd-pacemaker-assume-graceful-exit-if-leftovers-.patch
29e83d
Patch13:        0014-Fix-sbd-cluster-periodically-check-corosync-daemon-l.patch
29e83d
Patch14:        0015-build-say-library-when-missing-cmap-not-package-to-a.patch
29e83d
Patch15:        0016-Fix-sbd-pacemaker-check-for-shutdown-attribute-on-ev.patch
6f8c14
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
6f8c14
BuildRequires:  autoconf
6f8c14
BuildRequires:  automake
6f8c14
BuildRequires:  libuuid-devel
6f8c14
BuildRequires:  glib2-devel
6f8c14
BuildRequires:  libaio-devel
6f8c14
BuildRequires:  corosynclib-devel
6f8c14
BuildRequires:  pacemaker-libs-devel > 1.1.12
6f8c14
BuildRequires:  libtool
6f8c14
BuildRequires:  libuuid-devel
6f8c14
BuildRequires:  libxml2-devel
6f8c14
BuildRequires:  pkgconfig
6f8c14
BuildRequires:  systemd
6f8c14
6f8c14
%if 0%{?rhel} > 0
88d7b2
ExclusiveArch: i686 x86_64 s390x ppc64le aarch64 %{arm}
6f8c14
%endif
6f8c14
6f8c14
%if %{defined systemd_requires}
6f8c14
%systemd_requires
6f8c14
%endif
6f8c14
6f8c14
%description
6f8c14
6f8c14
This package contains the storage-based death functionality.
6f8c14
6f8c14
###########################################################
6f8c14
6f8c14
%prep
6f8c14
%autosetup -n %{name}-%{commit} -p1
6f8c14
6f8c14
###########################################################
6f8c14
6f8c14
%build
6f8c14
autoreconf -i
6f8c14
export CFLAGS="$RPM_OPT_FLAGS -Wall -Werror"
6f8c14
%configure
6f8c14
make %{?_smp_mflags}
6f8c14
6f8c14
###########################################################
6f8c14
6f8c14
%install
6f8c14
6f8c14
make DESTDIR=$RPM_BUILD_ROOT LIBDIR=%{_libdir} install
6f8c14
rm -rf ${RPM_BUILD_ROOT}%{_libdir}/stonith
6f8c14
6f8c14
%if %{defined _unitdir}
6f8c14
install -D -m 0644 src/sbd.service $RPM_BUILD_ROOT/%{_unitdir}/sbd.service
6f8c14
install -D -m 0644 src/sbd_remote.service $RPM_BUILD_ROOT/%{_unitdir}/sbd_remote.service
6f8c14
%endif
6f8c14
6f8c14
mkdir -p ${RPM_BUILD_ROOT}%{_sysconfdir}/sysconfig
6f8c14
install -m 644 src/sbd.sysconfig ${RPM_BUILD_ROOT}%{_sysconfdir}/sysconfig/sbd
6f8c14
6f8c14
###########################################################
6f8c14
6f8c14
%clean
6f8c14
rm -rf %{buildroot}
6f8c14
6f8c14
%if %{defined _unitdir}
6f8c14
%post
6f8c14
%systemd_post sbd.service
6f8c14
%systemd_post sbd_remote.service
6f8c14
if [ $1 -ne 1 ] ; then
6f8c14
	if systemctl --quiet is-enabled sbd.service 2>/dev/null
6f8c14
	then
6f8c14
		systemctl --quiet reenable sbd.service 2>/dev/null || :
6f8c14
	fi
6f8c14
	if systemctl --quiet is-enabled sbd_remote.service 2>/dev/null
6f8c14
	then
6f8c14
		systemctl --quiet reenable sbd_remote.service 2>/dev/null || :
6f8c14
	fi
6f8c14
fi
6f8c14
6f8c14
%preun
6f8c14
%systemd_preun sbd.service
6f8c14
%systemd_preun sbd_remote.service
6f8c14
6f8c14
%postun
6f8c14
%systemd_postun sbd.service
6f8c14
%systemd_postun sbd_remote.service
6f8c14
%endif
6f8c14
6f8c14
%files
6f8c14
###########################################################
6f8c14
%defattr(-,root,root)
6f8c14
%config(noreplace) %{_sysconfdir}/sysconfig/sbd
6f8c14
%{_sbindir}/sbd
6f8c14
#%{_datadir}/sbd
6f8c14
%doc %{_mandir}/man8/sbd*
6f8c14
%if %{defined _unitdir}
6f8c14
%{_unitdir}/sbd.service
6f8c14
%{_unitdir}/sbd_remote.service
6f8c14
%endif
6f8c14
%doc COPYING
6f8c14
6f8c14
%changelog
29e83d
* Fri Aug 16 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-15
29e83d
- check for shutdown attribute on every cib-diff
646f31
29e83d
  Resolves: rhbz#1718296
646f31
29e83d
* Wed Jun 12 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-10
29e83d
- added missing patches to git
646f31
29e83d
  Resolves: rhbz#1702727
29e83d
  Resolves: rhbz#1718296
646f31
29e83d
* Tue Jun 11 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-9
646f31
- assume graceful pacemaker exit if leftovers are unmanaged
29e83d
- query corosync liveness via votequorum-api
29e83d
29e83d
  Resolves: rhbz#1702727
29e83d
  Resolves: rhbz#1718296
29e83d
29e83d
* Mon Jun 3 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-8
29e83d
- check for rt-budget > 0 and move to root-slice otherwise
29e83d
29e83d
  Resolves: rhbz#1713021
646f31
29e83d
* Wed Apr 10 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-7
29e83d
- add some minor fixes from upstream found by coverity
29e83d
29e83d
  Resolves: rhbz#1698056
29e83d
29e83d
* Wed Apr 10 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-6
29e83d
- add decision-context to gating.yaml
29e83d
29e83d
  Resolves: rhbz#1682137
29e83d
29e83d
* Mon Jan 14 2019 Klaus Wenninger <kwenning@redhat.com> - 1.4.0-5
29e83d
- rebase to upstream v1.4.0
29e83d
- finalize cmap connection if disconnected from cluster
29e83d
- make handling of cib-connection loss more robust
29e83d
- add ci test files
29e83d
- use generic term cluster-services in doc
29e83d
- stress in doc that on-disk metadata watchdog-timeout
29e83d
  takes precedence
29e83d
- fail earlier on invalid servants to make gcc 9 happy
29e83d
29e83d
  Resolves: rhbz#1698056
29e83d
  Resolves: rhbz#1682137
Pablo Greco bf5149
6f8c14
* Mon Dec 17 2018 Klaus Wenninger <kwenning@redhat.com> - 1.3.1-18
6f8c14
- make timeout-action executed by sbd configurable
6f8c14
6f8c14
  Resolves: rhbz#1660147
6f8c14
6f8c14
* Mon Dec 3 2018 Klaus Wenninger <kwenning@redhat.com> - 1.3.1-17
6f8c14
- use pacemaker's new pe api with constructors/destructors
6f8c14
6f8c14
  Resolves: rhbz#1650663
6f8c14
6f8c14
* Wed Sep 19 2018 Klaus Wenninger <kwenning@redhat.com> - 1.3.1-16
6f8c14
- avoid statting potential symlink-targets in /dev
6f8c14
6f8c14
  Resolves: rhbz#1629020
6f8c14
6f8c14
* Wed Sep 19 2018 Klaus Wenninger <kwenning@redhat.com> - 1.3.1-15
6f8c14
- rebuild against new versions of libqb (1.0.3-7.el8),
6f8c14
  corosync (2.99.3-4.el8) and pacemaker (2.0.0-9.el8)
6f8c14
6f8c14
  Related: rhbz#1615945
6f8c14
6f8c14
* Fri Sep 14 2018 Klaus Wenninger <kwenning@redhat.com> - 1.3.1-14
6f8c14
- skip symlinks pointing to dev-nodes outside of /dev
6f8c14
6f8c14
  Resolves: rhbz#1629020
6f8c14
6f8c14
* Wed Sep 5 2018 Klaus Wenninger <kwenning@redhat.com> - 1.3.1-13
6f8c14
- Require systemd-package during build to have the macros
6f8c14
6f8c14
  Resolves: rhbz#1625553
6f8c14
6f8c14
* Mon Jul 30 2018 Florian Weimer <fweimer@redhat.com> - 1.3.1-12
6f8c14
- Rebuild with fixed binutils
6f8c14
6f8c14
* Tue Jul 3 2018 <kwenning@redhat.com> - 1.3.1-11
6f8c14
- replaced tarball by version downloaded from github
6f8c14
6f8c14
* Mon Jul 2 2018 <kwenning@redhat.com> - 1.3.1-10
6f8c14
- removed unneeded python build-dependency
6f8c14
- updated legacy corosync-devel to corosynclib-devel
6f8c14
6f8c14
  Resolves: rhbz#1595856
6f8c14
6f8c14
* Fri May 4 2018 <kwenning@redhat.com> - 1.3.1-9
6f8c14
- use cib-api directly as get_cib_copy gone with
6f8c14
  pacemaker 2.0.0
6f8c14
- add sys/sysmacros.h to build with glibc-2.25
6f8c14
- enlarge string buffer to satisfy newer gcc
6f8c14
- no corosync 1 support with pacemaker 2.0.0
6f8c14
- set default to LOG_NOTICE + overhaul levels
6f8c14
- refactor proc-parsing
6f8c14
- adaptions for daemon-names changed with
6f8c14
  pacemaker 2.0.0 rc3
6f8c14
- added .do-not-sync-with-fedora
6f8c14
  Resolves: rhbz#1571797
6f8c14
6f8c14
* Mon Apr 16 2018 <kwenning@redhat.com> - 1.3.1-8
6f8c14
- Added aarch64 target
6f8c14
6f8c14
  Resolves: rhbz#1568029
6f8c14
6f8c14
* Mon Jan 15 2018 <kwenning@redhat.com> - 1.3.1-7
6f8c14
- reenable sbd on upgrade so that additional
6f8c14
  links to make pacemaker properly depend on
6f8c14
  sbd are created
6f8c14
6f8c14
  Resolves: rhbz#1525981
6f8c14
6f8c14
* Wed Jan 10 2018 <kwenning@redhat.com> - 1.3.1-5
6f8c14
- add man sections for query- & test-watchdog
6f8c14
6f8c14
  Resolves: rhbz#1462002
6f8c14
6f8c14
* Wed Dec 20 2017 <kwenning@redhat.com> - 1.3.1-3
6f8c14
- mention timeout caveat with SBD_DELAY_START
6f8c14
  in configuration template
6f8c14
- make systemd wait for sbd-start to finish
6f8c14
  before starting pacemaker or dlm
6f8c14
6f8c14
  Resolves: rhbz#1525981
6f8c14
6f8c14
* Fri Nov 3 2017 <kwenning@redhat.com> - 1.3.1-2
6f8c14
- rebase to upstream v1.3.1
6f8c14
6f8c14
  Resolves: rhbz#1499864
6f8c14
            rhbz#1468580
6f8c14
            rhbz#1462002
6f8c14
6f8c14
* Wed Jun 7 2017 <kwenning@redhat.com> - 1.3.0-3
6f8c14
- prevent creation of duplicate servants
6f8c14
- check 2Node flag in corosync to support
6f8c14
  2-node-clusters with shared disk fencing
6f8c14
- move disk-triggered reboot/off/crashdump
6f8c14
  to inquisitor to have sysrq observed by watchdog
6f8c14
6f8c14
  Resolves: rhbz#1413951
6f8c14
6f8c14
* Sun Mar 26 2017 <kwenning@redhat.com> - 1.3.0-1
6f8c14
- rebase to upstream v1.3.0
6f8c14
- remove watchdog-limitation from description
6f8c14
  Resolves: rhbz#1413951
6f8c14
6f8c14
* Mon Feb 27 2017 <kwenning@redhat.com> - 1.2.1-23
6f8c14
- if shared-storage enabled check for node-name <= 63 chars
6f8c14
  Resolves: rhbz#1413951
6f8c14
6f8c14
* Tue Jan 31 2017 <kwenning@redhat.com> - 1.2.1-22
6f8c14
- Rebuild with shared-storage enabled
6f8c14
- Package original manpage
6f8c14
- Added ppc64le target
6f8c14
  Resolves: rhbz#1413951
6f8c14
6f8c14
* Fri Apr 15 2016 <kwenning@redhat.com> - 1.2.1-21
6f8c14
- Rebuild for new pacemaker
6f8c14
  Resolves: rhbz#1320400
6f8c14
6f8c14
* Fri Apr 15 2016 <kwenning@redhat.com> - 1.2.1-20
6f8c14
- tarball updated to c511b0692784a7085df4b1ae35748fb318fa79ee
6f8c14
  from https://github.com/Clusterlabs/sbd
6f8c14
  Resolves: rhbz#1324240
6f8c14
6f8c14
* Thu Jul 23 2015 <abeekhof@redhat.com> - 1.2.1-5
6f8c14
- Rebuild for pacemaker
6f8c14
6f8c14
* Tue Jun 02 2015 <abeekhof@redhat.com> - 1.2.1-4
6f8c14
- Include the dist tag in the release string
6f8c14
- Rebuild for new pacemaker
6f8c14
6f8c14
* Mon Jan 12 2015 <abeekhof@redhat.com> - 1.2.1-3
6f8c14
- Correctly parse SBD_WATCHDOG_TIMEOUT into seconds (not milliseconds)
6f8c14
6f8c14
* Mon Oct 27 2014 <abeekhof@redhat.com> - 1.2.1-2
6f8c14
- Correctly enable /proc/pid validation for sbd_lock_running()
6f8c14
6f8c14
* Fri Oct 24 2014 <abeekhof@redhat.com> - 1.2.1-1
6f8c14
- Further improve integration with the el7 environment
6f8c14
6f8c14
* Thu Oct 16 2014 <abeekhof@redhat.com> - 1.2.1-0.5.872e82f3.git
6f8c14
- Disable unsupported functionality (for now)
6f8c14
6f8c14
* Wed Oct 15 2014 <abeekhof@redhat.com> - 1.2.1-0.4.872e82f3.git
6f8c14
- Improved integration with the el7 environment
6f8c14
6f8c14
* Tue Sep 30 2014 <abeekhof@redhat.com> - 1.2.1-0.3.8f912945.git
6f8c14
- Only build on archs supported by the HA Add-on
6f8c14
6f8c14
* Fri Aug 29 2014 <abeekhof@redhat.com> - 1.2.1-0.2.8f912945.git
6f8c14
- Remove some additional SUSE-isms
6f8c14
6f8c14
* Fri Aug 29 2014 <abeekhof@redhat.com> - 1.2.1-0.1.8f912945.git
6f8c14
- Prepare for package review