initramfs: fix swap size

It should be 1GB, not 1MB...

QubesOS/qubes-issues#1354
pull/2/head mm_8311e126
Marek Marczykowski-Górecki 9 years ago
parent 170d46c40d
commit 8311e1263d
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724

@ -62,7 +62,7 @@ if [ `cat /sys/block/xvda/ro` = 1 ] ; then
while ! [ -e /dev/xvdc ]; do sleep 0.1; done
VOLATILE_SIZE=$(sfdisk -s /dev/xvdc)
ROOT_SIZE=$(sfdisk -s /dev/xvda) # kbytes
SWAP_SIZE=1024 # kbytes
SWAP_SIZE=$(( 1024 * 1024 )) # kbytes
if [ $VOLATILE_SIZE -lt $(($ROOT_SIZE + $SWAP_SIZE)) ]; then
ROOT_SIZE=$(($VOLATILE_SIZE - $SWAP_SIZE))
fi

@ -21,7 +21,7 @@ if [ `cat /sys/block/xvda/ro` = 1 ] ; then
while ! [ -e /dev/xvdc ]; do sleep 0.1; done
VOLATILE_SIZE=$(sfdisk -s /dev/xvdc)
ROOT_SIZE=$(sfdisk -s /dev/xvda) # kbytes
SWAP_SIZE=1024 # kbytes
SWAP_SIZE=$(( 1024 * 1024 )) # kbytes
if [ $VOLATILE_SIZE -lt $(($ROOT_SIZE + $SWAP_SIZE)) ]; then
ROOT_SIZE=$(($VOLATILE_SIZE - $SWAP_SIZE))
fi

Loading…
Cancel
Save