Use setenforce instead of /selinux pseudo-fs
The location of the /selinux pseudo-fs has changed.  Use a
more stable interface by way of the setenforce command.
@@ -127,8 +127,8 @@ rm -rf %{buildroot}
chkconfig lustre-modules on
# disable SELinux -- it prevents both lustre and pacemaker from working
sed -ie 's/^SELINUX=.*$/SELINUX=disabled/' /etc/selinux/config
-# the above only disables on the next boot. disable it currently, also
-echo 0 > /selinux/enforce
+# the above only disables on the next boot. set to permissive currently, also
+setenforce 0
if [ $1 -eq 1 ]; then
# new install; create default agent config
@@ -138,9 +138,9 @@ elif [ $1 -eq 2 ]; then
chroma-agent convert_agent_config
fi
+%triggerin management -- kernel
# when a kernel is installed, make sure that our kernel is reset back to
# being the preferred boot kernel
-%triggerin management -- kernel
MOST_RECENT_KERNEL_VERSION=$(rpm -q kernel --qf "%{INSTALLTIME} %{VERSION}-%{RELEASE}.%{ARCH}\n" | sort -nr | sed -n -e '/_lustre/{s/.* //p;q}')
grubby --set-default=/boot/vmlinuz-$MOST_RECENT_KERNEL_VERSION
