Move special umount of tmpfs to the swap init script where it belongs, #149.

This commit is contained in:
Roy Marples 2009-04-19 11:15:37 +00:00
parent bb6614f4e1
commit bbd810425b
2 changed files with 6 additions and 6 deletions

View File

@ -52,12 +52,6 @@ stop()
# Flush all pending disk writes now # Flush all pending disk writes now
sync; sync sync; sync
# Try to unmount all tmpfs filesystems not in use, else a deadlock may
# occure, bug #13599.
# As $RC_SVCDIR may also be tmpfs we cd to it to lock it
cd "${RC_SVCDIR}"
umount -a -t tmpfs 2>/dev/null
. "${RC_LIBDIR}"/sh/rc-mount.sh . "${RC_LIBDIR}"/sh/rc-mount.sh
# Umount loopback devices # Umount loopback devices

View File

@ -21,6 +21,12 @@ start()
stop() stop()
{ {
ebegin "Deactivating swap devices" ebegin "Deactivating swap devices"
# Try to unmount all tmpfs filesystems not in use, else a deadlock may
# occure. As $RC_SVCDIR may also be tmpfs we cd to it to lock it
cd "${RC_SVCDIR}"
umount -a -t tmpfs 2>/dev/null
case "${RC_UNAME}" in case "${RC_UNAME}" in
NetBSD|OpenBSD) swapctl -U -t noblk >/dev/null;; NetBSD|OpenBSD) swapctl -U -t noblk >/dev/null;;
*) swapoff -a >/dev/null;; *) swapoff -a >/dev/null;;