Revert "Revert "swap: go back to using swapon for Linux systems""

This reverts commit 06d6701785.
After researching this further, we do need this commit. The other issue
is a bug in fstabinfo which will also need to be fixed.
This commit is contained in:
William Hubbs 2012-02-20 18:59:17 -06:00
parent 9e3fc7f3f5
commit e4146c0945

View File

@ -12,15 +12,7 @@ start()
{ {
ebegin "Activating swap devices" ebegin "Activating swap devices"
case "$RC_UNAME" in case "$RC_UNAME" in
Linux) Linux) swapon -a -e >/dev/null;;
local dev
for dev in $(fstabinfo -b -t swap); do
case "$dev" in
/dev/loop*) ;;
*) swapon $dev >/dev/null;;
esac
done
;;
NetBSD|OpenBSD) swapctl -A -t noblk >/dev/null;; NetBSD|OpenBSD) swapctl -A -t noblk >/dev/null;;
*) swapon -a >/dev/null;; *) swapon -a >/dev/null;;
esac esac