From 188318b7b567f206d60dfb754fedbb0bfc74ef91 Mon Sep 17 00:00:00 2001 From: Boris Ranto Date: Mon, 23 May 2016 17:06:19 +0200 Subject: [PATCH] rpm: Restore /var/run/ceph context manually The fixfiles command won't fix label for /var/run/ceph (/run is probably excluded from relabel), we need to restore the context manually. Signed-off-by: Boris Ranto (cherry picked from commit 6de39ce73737f79d4511dfc4e1d10d7f3733ab1b) --- ceph.spec.in | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ceph.spec.in b/ceph.spec.in index d8d45e793da77..37669d411d7ee 100644 --- a/ceph.spec.in +++ b/ceph.spec.in @@ -1441,6 +1441,8 @@ fi # Now, relabel the files /usr/sbin/fixfiles -C ${FILE_CONTEXT}.pre restore 2> /dev/null rm -f ${FILE_CONTEXT}.pre +# The fixfiles command won't fix label for /var/run/ceph +/usr/sbin/restorecon -R /var/run/ceph > /dev/null 2>&1 # Start the daemons iff they were running before if test $STATUS -eq 0; then @@ -1475,6 +1477,8 @@ if [ $1 -eq 0 ]; then /usr/sbin/fixfiles -C ${FILE_CONTEXT}.pre restore 2> /dev/null rm -f ${FILE_CONTEXT}.pre + # The fixfiles command won't fix label for /var/run/ceph + /usr/sbin/restorecon -R /var/run/ceph > /dev/null 2>&1 # Start the daemons if they were running before if test $STATUS -eq 0; then -- 2.39.5