summaryrefslogtreecommitdiffstats
path: root/contrib
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2014-08-10 19:25:28 +0200
committerJakub Hrozek <jhrozek@redhat.com>2014-08-11 15:51:16 +0200
commit192027debeaa991690160c3cb68480fe54ad8fdf (patch)
treefea24b072ce4b980d10bcea82efa701ab985fb61 /contrib
parenta1e89ede4995f948abc1acc364246161df7cca2c (diff)
downloadsssd-192027debeaa991690160c3cb68480fe54ad8fdf.tar.gz
sssd-192027debeaa991690160c3cb68480fe54ad8fdf.tar.xz
sssd-192027debeaa991690160c3cb68480fe54ad8fdf.zip
RPM: Restart service in %posttrans, not %post
When upgrading from a 1.9 version with monolithic packaging to 1.10 or later with per-provider subpackage, sssd-common can be upgraded (and restarted) before the new sssd-$provider is restarted. This can lead to a startup failure, because the sssd_be process from already upgraded sssd-common would attempt to load a sssd_$provider.so from the legacy sssd package. Restarting the service in %posttrans makes sure all the packages are in place when we restart the service. Resolves: https://fedorahosted.org/sssd/ticket/2399
Diffstat (limited to 'contrib')
-rw-r--r--contrib/sssd.spec.in5
1 files changed, 2 insertions, 3 deletions
diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
index 82d8e895c..1429c263d 100644
--- a/contrib/sssd.spec.in
+++ b/contrib/sssd.spec.in
@@ -848,9 +848,8 @@ fi
%post common
/sbin/chkconfig --add %{servicename}
-if [ $1 -ge 1 ] ; then
- /sbin/service %{servicename} condrestart 2>&1 > /dev/null
-fi
+%posttrans
+/sbin/service %{servicename} condrestart 2>&1 > /dev/null
%preun common
if [ $1 = 0 ]; then