Attached you can find both the tool to fragment memory and the script it calls in my testing. I was executing this as follows (on 2G machine with 2G swap space): echo 1 > /proc/sys/vm/overcommit_memory echo 1 > /proc/sys/vm/compact_memory /root/fragment-mem-and-run /root/alloc_hugepages.sh 1920M 250M -- Michal Hocko SUSE Labs