From: C.J. Collier Date: Wed, 14 Sep 2016 17:24:04 +0000 (-0700) Subject: Write vm.nr_hugepages to persistent media X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=8c52a2b08de17fd2bf20abaefca11251592d9ec0;p=ci-management.git Write vm.nr_hugepages to persistent media Contrary to the comment, the code did not persist the vm.nr_hugepages value across reboots Change-Id: I34739800ccb525d725f0a936975a283886969936 Signed-off-by: C.J. Collier --- diff --git a/vagrant/lib/bootstrap-functions.sh b/vagrant/lib/bootstrap-functions.sh index 9a6067818..71fa0625d 100644 --- a/vagrant/lib/bootstrap-functions.sh +++ b/vagrant/lib/bootstrap-functions.sh @@ -154,7 +154,9 @@ deb_install_pkgs() { deb_enable_hugepages() { # Setup for hugepages using sysctl so it persists across reboots - sysctl -w vm.nr_hugepages=1024 + AVP="vm.nr_hugepages=1024" + sysctl -w ${AVP} + echo "${AVP}" >> /etc/sysctl.conf mkdir -p /mnt/huge echo "hugetlbfs /mnt/huge hugetlbfs defaults 0 0" >> /etc/fstab