diff options
author | Bill Nottingham <notting@redhat.com> | 2006-07-13 15:55:36 +0000 |
---|---|---|
committer | Bill Nottingham <notting@redhat.com> | 2006-07-13 15:55:36 +0000 |
commit | 0c9bd51b921669fc60693430ae98f9d7911a3908 (patch) | |
tree | e72f5b04262d890d0a8647b13e4444ae5e61b4dc /rc.d | |
parent | d296b7ad8e4397ff9057ad15cf7757bb6b135379 (diff) | |
download | initscripts-0c9bd51b921669fc60693430ae98f9d7911a3908.tar initscripts-0c9bd51b921669fc60693430ae98f9d7911a3908.tar.gz initscripts-0c9bd51b921669fc60693430ae98f9d7911a3908.tar.bz2 initscripts-0c9bd51b921669fc60693430ae98f9d7911a3908.tar.xz initscripts-0c9bd51b921669fc60693430ae98f9d7911a3908.zip |
SELinux works now.
- fix relabel call
- allow 'noreadonlyroot' boot option
Diffstat (limited to 'rc.d')
-rwxr-xr-x | rc.d/rc.sysinit | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit index ba14702c..4f7aaa80 100755 --- a/rc.d/rc.sysinit +++ b/rc.d/rc.sysinit @@ -454,9 +454,7 @@ if strstr "$cmdline" readonlyroot ; then READONLY=yes [ -z "$RW_MOUNT" ] && RW_MOUNT=/var/lib/stateless/writable fi -if [ "$READONLY" = "yes" -a -n "$SELINUX_STATE" ]; then - echo $"SELinux is not compatible with read-only root at this time." - echo $"Mounting read/write." +if strstr "$cmdline" noreadonlyroot ; then READONLY=no fi @@ -487,9 +485,7 @@ if [ "$READONLY" = "yes" ]; then # Common mount options for scratch space regardless of # type of backing store - if [ -n "$SELINUX_STATE" ]; then - mountopts="-o fscontext=system_u:object_r:fs_t:s0" - fi + mountopts= # Scan partitions for local scratch storage rw_mount_dev=$(blkid -t LABEL="$RW_LABEL" -o device | awk '{ print ; exit }') @@ -521,7 +517,7 @@ if [ "$READONLY" = "yes" ]; then *) ;; esac - [ -n "$SELINUX_STATE" ] && restorecon -R "$1" + [ -n "$SELINUX_STATE" -a -e "$path" ] && restorecon -R "$path" done done |