X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=scripts%2Flive-bottom%2F13swap;h=8fc718ca60033484ed1a8a07f44487bc74ff4dca;hb=245be6d3de8a9e1239154674be4ca818781e6f10;hp=303fbbb0190157df9bc6cad54a28c2d8e9a0e06c;hpb=8225101cbf7a069f0d4ff6d5fda4677051d8821a;p=live-boot-grml.git diff --git a/scripts/live-bottom/13swap b/scripts/live-bottom/13swap index 303fbbb..8fc718c 100755 --- a/scripts/live-bottom/13swap +++ b/scripts/live-bottom/13swap @@ -20,14 +20,14 @@ esac # live-initramfs header -if [ -n "${NOSWAP}" ] || [ -n "${NOFSTAB}" ] +if [ -z "${SWAPON}" ] || [ -n "${NOFSTAB}" ] then exit 0 fi . /scripts/live-functions -log_begin_msg "Setting up swap..." +log_begin_msg "Setting up swap" # live-initramfs script @@ -41,7 +41,7 @@ do continue fi - /lib/udev/vol_id ${device%%[0-9]*} | grep -q "^ID_FS_USAGE=raid" && continue + /lib/udev/vol_id ${device%%[0-9]*} 2>/dev/null | grep -q "^ID_FS_USAGE=raid" && continue magic=$(/bin/dd if="${device}" bs=4086 skip=1 count=1 2>/dev/null | /bin/dd bs=10 count=1 2>/dev/null) || continue