#!/bin/sh
#
# filesystems	mount all local filesystems (including swap)

case "$1" in
start)
    need multi

    # Make certain swap is enabled
    swapon -a
    echo "Mounting local filesystems"
    mount -avt nonfs,proc

    # remove stale locks (must be done after mount -a!)
    rm -f /var/lock/LCK.* /tmp/.X*lock
    rm -f /var/spool/uucp/LCK..*
    rm -rf /tmp/*
    ;;

stop)
    swapoff -a
    umount -avt noproc

    # don't forget to leave / writable
    mount -n -o remount,rw /
    ;;
*)
    echo "usage: $0 {start|stop}"
    ;;
esac
