Project

General

Profile

Actions

Bug #47126

open

mgr plugin rpms unconditionally restart ceph-mgr.target on install/uninstall

Added by Dan van der Ster over 3 years ago. Updated over 3 years ago.

Status:
New
Priority:
High
Assignee:
-
Category:
-
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

In nautilus all of the mgr plugin rpms have a post install and post uninstall scriptlet which unconditionally restarts the ceph-mgr.target, e.g:

%post mgr-dashboard
if [ $1 -eq 1 ] ; then
    /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
fi

%postun mgr-dashboard
if [ $1 -eq 1 ] ; then
    /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
fi

This makes it difficult or perhaps impossible to get the upgrade ordering procedure correct (i.e. it is difficult to upgrade the mons before the mgrs.)

Actions #1

Updated by Sebastian Wagner over 3 years ago

Hm. In order to properly install a module, you have to restart the mgr.

obviously, containers solve this issues.

Actions #2

Updated by Dan van der Ster over 3 years ago

Sebastian Wagner wrote:

Hm. In order to properly install a module, you have to restart the mgr.

that's clear, but when we should restart is obviously depending on a particular deployment, most important if mon/mgr is cohosted on the same box, which I presume is very very common.

Elsewhere in the ceph.spec daemons are checking the CEPH_AUTO_RESTART_ON_UPGRADE value in /etc/sysconfig/ceph (which defaults to "no", btw), e.g.

%postun mgr
%if 0%{?suse_version}
DISABLE_RESTART_ON_UPDATE="yes" 
%service_del_postun ceph-mgr@\*.service ceph-mgr.target
%endif
%if 0%{?fedora} || 0%{?rhel}
%systemd_postun ceph-mgr@\*.service ceph-mgr.target
%endif
if [ $1 -ge 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=%{_sysconfdir}/sysconfig/ceph
  if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
    source $SYSCONF_CEPH
  fi
  if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
    /usr/bin/systemctl try-restart ceph-mgr@\*.service > /dev/null 2>&1 || :
  fi
fi
Actions #3

Updated by Neha Ojha over 3 years ago

  • Priority changed from Normal to High
Actions

Also available in: Atom PDF