Fix SELinux directory perms in mdmonitor init script
Signed-off-by: Doug Ledford <dledford@redhat.com>
This commit is contained in:
parent
a1a27cff98
commit
43ea33bd96
@ -1,7 +1,7 @@
|
||||
Summary: The mdadm program controls Linux md devices (software RAID arrays)
|
||||
Name: mdadm
|
||||
Version: 3.2.1
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
Source: http://www.kernel.org/pub/linux/utils/raid/mdadm/mdadm-%{version}.tar.bz2
|
||||
Source1: mdmonitor.init
|
||||
Source2: raid-check
|
||||
@ -80,6 +80,10 @@ fi
|
||||
%ghost %attr(0700,root,root) %dir /var/run/mdadm
|
||||
|
||||
%changelog
|
||||
* Thu Mar 31 2011 Doug Ledford <dledford@redhat.com> - 3.2.1-3
|
||||
- Fix mdmonitor init script setup of SELinux on PIDPATH
|
||||
- Resolves: bz692559
|
||||
|
||||
* Mon Mar 28 2011 Doug Ledford <dledford@redhat.com> - 3.2.1-2
|
||||
- Restore build command to sane command instead of test command
|
||||
|
||||
|
@ -56,8 +56,9 @@ start ()
|
||||
grep '^\(MAILADDR\|PROGRAM\) .' /etc/mdadm.conf >/dev/null 2>&1 || return 6
|
||||
# Create our directory if it isn't there yet
|
||||
if [ ! -d $PIDPATH ]; then
|
||||
mkdir -m 0700 -Z system_u:object_r:mdadm_var_run_t $PIDPATH >&/dev/null
|
||||
mkdir -m 0700 $PIDPATH >&/dev/null
|
||||
RC=$?
|
||||
[ -x /sbin/restorecon ] && /sbin/restorecon $PIDPATH
|
||||
if [ $RC -ne 0 ]; then
|
||||
echo -n "Failed to create /var/run/mdadm"
|
||||
failure
|
||||
|
Loading…
Reference in New Issue
Block a user