Commit fcf08586 authored by Benjamin Slade's avatar Benjamin Slade

change zfs limit arc method to a grub cmdline option

- the rc.local method seems to have stopped (?!) working
- minor change to xbps-install to specify xbps, to future-proof in case
  xbps ends up being updated with all other packages, because we don't need
  to update everything else at this point – just xbps – before installing
  cryptsetup, grub, zfs, and the kernel
parent 3b545140
......@@ -58,7 +58,7 @@ echo "Set new root password below "
until passwd; do echo "Confirmation didn't match. Please try again. " ; done
# install necessary packages
xbps-install -Su # update
xbps-install -S xbps libxbps # update xbps
read -p "The following will take some time - you may want to go and put the kettle on or the like. Please press <return> (twice) to continue." teatime
......@@ -129,9 +129,12 @@ then
MEMINBYTES=`echo "$((ARCREZINT*1024*1024*1024))"`
echo "
# Limit ZFS ARC to ${ARCREZ}Gb
echo ${MEMINBYTES} >> /sys/module/zfs/parameters/zfs_arc_max" >> /etc/rc.local
# echo "
# Limit ZFS ARC to ${ARCREZ}Gb
# echo ${MEMINBYTES} >> /sys/module/zfs/parameters/zfs_arc_max" >> /etc/rc.local # doesn't seem to work anymore (?!) from rc.local
# so put into grub instead:
sed -i "s/boot=zfs/boot=zfs zfs.zfs_arc_max=$MEMINBYTES/" "/etc/default/grub"
grub-mkconfig -o /boot/grub/grub.cfg
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment