You are not logged in.
Hello,
I have successfully got hugepages to work with my VMs, but now even though my VMs are off (which they usually are) the hugepages take up my memory quite a bit (4GB for 1 VM). Is there some existing mechanism to modify the number of hugepages based on the amount of memory used in the VM, or will I have to modify /proc/sys/vm/nr_hugepages with VM autostart scripts?
Offline
Well, since I haven't received any help on this topic, I assume this is a non-existant feature. So for now, I just added qemu hooks to add/remove the entire hugepages size like this, maybe it will help someone else out:
if [ "${1}" = "win10" ]; then
if [ "${2}" = "start" ]; then
echo 2050 > /proc/sys/vm/nr_hugepages
xrandr --output HDMI1 --off
elif [ "${2}" = "stopped" ]; then
echo 0 > /proc/sys/vm/nr_hugepages
xrandr --output HDMI1 --auto
xrandr --output HDMI1 --right-of HDMI2
fi
fi
Offline