#!/bin/sh #---------------------------------------------------------------------------- # /etc/rc0.d/rc960.umount - unmount all Filesystems except: # '/', '/proc', '/dev/pts' and '/sys' # # Creation: 12.05.2002 rr # Last Update: $Id$ #---------------------------------------------------------------------------- # set -x FILESYSTEMS="" while read DEV MTPT FSTYPE REST; do case "$MTPT" in /|/proc|/dev/pts|/sys) continue ;; esac case "$FSTYPE" in proc|procfs|linprocfs|devfs|sysfs|usbfs|usbdevfs|devpts) continue ;; *) FILESYSTEMS="$FILESYSTEMS $MTPT" ;; esac done < /proc/mounts colecho "unmounting file systems $FILESYSTEMS" gn sync umount -f -r $FILESYSTEMS if grep -q /dev /proc/swaps ; then colecho 'disabling swap' gn swapoff -a fi