trrespass/drama/hugepage.sh
2020-03-10 16:19:50 +01:00

7 lines
171 B
Bash
Executable File

gbFile="/sys/kernel/mm/hugepages/hugepages-1048576kB/nr_hugepages"
mkdir /mnt/huge
mount -t hugetlbfs -o pagesize=1G none /mnt/huge
su -c 'echo 1 >'$gbFile
cat $gbFile