Skip to content

Commit

Permalink
Merge remote-tracking branch 'gh/jewel'
Browse files Browse the repository at this point in the history
  • Loading branch information
liewegas committed Mar 3, 2016
2 parents 3a1b307 + ea45099 commit be3544f
Show file tree
Hide file tree
Showing 4 changed files with 82 additions and 73 deletions.
146 changes: 74 additions & 72 deletions ceph.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -814,75 +814,8 @@ mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/ceph/bootstrap-rgw
%clean
rm -rf $RPM_BUILD_ROOT

%pre
%if 0%{?_with_systemd}
%if 0%{?suse_version}
# service_add_pre and friends don't work with parameterized systemd service
# instances, only with single services or targets, so we always pass
# ceph.target to these macros
%service_add_pre ceph.target
%endif
%endif


%post
/sbin/ldconfig
%if 0%{?_with_systemd}
%if 0%{?suse_version}
%fillup_only
%service_add_post ceph.target
%endif
%else
/sbin/chkconfig --add ceph
%endif

%preun
%if 0%{?_with_systemd}
%if 0%{?suse_version}
%service_del_preun ceph.target
%endif
# Disable and stop on removal.
if [ $1 = 0 ] ; then
SERVICE_LIST=$(systemctl | grep -E '^ceph-mon@|^ceph-create-keys@|^ceph-osd@|^ceph-mds@|^ceph-disk-' | cut -d' ' -f1)
if [ -n "$SERVICE_LIST" ]; then
for SERVICE in $SERVICE_LIST; do
/usr/bin/systemctl --no-reload disable $SERVICE > /dev/null 2>&1 || :
/usr/bin/systemctl stop $SERVICE > /dev/null 2>&1 || :
done
fi
fi
%else
%if 0%{?rhel} || 0%{?fedora}
if [ $1 = 0 ] ; then
/sbin/service ceph stop >/dev/null 2>&1
/sbin/chkconfig --del ceph
fi
%endif
%endif

%postun
/sbin/ldconfig
%if 0%{?_with_systemd}
if [ $1 = 1 ] ; then
# Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
# "yes". In any case: if units are not running, do not touch them.
SYSCONF_CEPH=/etc/sysconfig/ceph
if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
source $SYSCONF_CEPH
fi
if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
SERVICE_LIST=$(systemctl | grep -E '^ceph-mon@|^ceph-create-keys@|^ceph-osd@|^ceph-mds@|^ceph-disk-' | cut -d' ' -f1)
if [ -n "$SERVICE_LIST" ]; then
for SERVICE in $SERVICE_LIST; do
/usr/bin/systemctl try-restart $SERVICE > /dev/null 2>&1 || :
done
fi
fi
fi
%endif

#################################################################################
# files
# files and systemd scriptlets
#################################################################################
%files

Expand Down Expand Up @@ -955,8 +888,74 @@ rm -rf $RPM_BUILD_ROOT
%attr(770,ceph,ceph) %dir %{_localstatedir}/run/ceph
%endif

%pre base
%if 0%{?_with_systemd}
%if 0%{?suse_version}
# service_add_pre and friends don't work with parameterized systemd service
# instances, only with single services or targets, so we always pass
# ceph.target to these macros
%service_add_pre ceph.target
%endif
%endif

%post base
/sbin/ldconfig
%if 0%{?_with_systemd}
%if 0%{?suse_version}
%fillup_only
%service_add_post ceph.target
%endif
%else
/sbin/chkconfig --add ceph
%endif

%preun base
%if 0%{?_with_systemd}
%if 0%{?suse_version}
%service_del_preun ceph.target
%endif
# Disable and stop on removal.
if [ $1 = 0 ] ; then
SERVICE_LIST=$(systemctl | grep -E '^ceph-mon@|^ceph-create-keys@|^ceph-osd@|^ceph-mds@|^ceph-disk-' | cut -d' ' -f1)
if [ -n "$SERVICE_LIST" ]; then
for SERVICE in $SERVICE_LIST; do
/usr/bin/systemctl --no-reload disable $SERVICE > /dev/null 2>&1 || :
/usr/bin/systemctl stop $SERVICE > /dev/null 2>&1 || :
done
fi
fi
%else
%if 0%{?rhel} || 0%{?fedora}
if [ $1 = 0 ] ; then
/sbin/service ceph stop >/dev/null 2>&1
/sbin/chkconfig --del ceph
fi
%endif
%endif

%postun base
/sbin/ldconfig
%if 0%{?_with_systemd}
if [ $1 = 1 ] ; then
# Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
# "yes". In any case: if units are not running, do not touch them.
SYSCONF_CEPH=/etc/sysconfig/ceph
if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
source $SYSCONF_CEPH
fi
if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
SERVICE_LIST=$(systemctl | grep -E '^ceph-mon@|^ceph-create-keys@|^ceph-osd@|^ceph-mds@|^ceph-disk-' | cut -d' ' -f1)
if [ -n "$SERVICE_LIST" ]; then
for SERVICE in $SERVICE_LIST; do
/usr/bin/systemctl try-restart $SERVICE > /dev/null 2>&1 || :
done
fi
fi
fi
%endif

#################################################################################
%files -n ceph-common
%files common
%defattr(-,root,root,-)
%{_bindir}/ceph
%{_bindir}/ceph-authtool
Expand Down Expand Up @@ -1009,7 +1008,7 @@ rm -rf $RPM_BUILD_ROOT
%attr(3770,ceph,ceph) %dir %{_localstatedir}/log/ceph/
%attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/

%pre -n ceph-common
%pre common
CEPH_GROUP_ID=""
CEPH_USER_ID=""
%if 0%{?rhel} || 0%{?fedora}
Expand All @@ -1026,18 +1025,19 @@ getent passwd ceph >/dev/null || useradd -r -g ceph -d %{_localstatedir}/lib/cep
%endif
exit 0

%post -n ceph-common
%post common
%if 0%{?_with_systemd}
%tmpfiles_create %{_tmpfilesdir}/ceph-common.conf
%endif

%postun -n ceph-common
%postun common
# Package removal cleanup
if [ "$1" -eq "0" ] ; then
rm -rf /var/log/ceph
rm -rf /etc/ceph
fi

#################################################################################
%files mds
%{_bindir}/ceph-mds
%{_bindir}/cephfs-journal-tool
Expand All @@ -1052,6 +1052,7 @@ fi
%endif
%attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mds

#################################################################################
%files mon
%{_bindir}/ceph-mon
%{_bindir}/ceph-rest-api
Expand Down Expand Up @@ -1157,6 +1158,7 @@ fi
fi
%endif

#################################################################################
%files osd
%{_bindir}/ceph-clsinfo
%{_bindir}/ceph-bluefs-tool
Expand Down
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ AC_PREREQ(2.59)
# VERSION define is not used by the code. It gets a version string
# from 'git describe'; see src/ceph_ver.[ch]

AC_INIT([ceph], [10.0.3], [[email protected]])
AC_INIT([ceph], [10.0.4], [[email protected]])

AX_CXX_COMPILE_STDCXX_11(, mandatory)

Expand Down
6 changes: 6 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
ceph (v10.0.4) stable; urgency=low

* New upstream release

-- Sage Weil <[email protected]> Thu, 03 Mar 2016 13:34:18 -0500

ceph (10.0.3) stable; urgency=low

* New upstream release
Expand Down
1 change: 1 addition & 0 deletions src/mon/MDSMonitor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,7 @@ bool MDSMonitor::preprocess_beacon(MonOpRequestRef op)
// do not match, to update our stored
if (!(pending_daemon_health[gid] == m->get_health())) {
dout(20) << __func__ << " health metrics for gid " << gid << " were updated" << dendl;
_note_beacon(m);
return false;
}

Expand Down

0 comments on commit be3544f

Please sign in to comment.