specifying in the kernel command line

Kevin Wilson wkevils at gmail.com
Wed Apr 4 04:46:01 EDT 2018


Hello,
I have an x86_64 host with 4GB of Physical RAM running Fedora 25.

I have a question about hugepages allocation on this host.
In:
https://www.kernel.org/doc/Documentation/vm/hugetlbpage.txt

I see that you can use "hugepages=N" kernel parameter (in grub) for
specifying the number
of hugepages you want to allocate at boot time.

The default hugepage size on this host is 2MB.

For example, I am thinking of using
hugepagesz=2MB hugepages=4096
in the kernel command line.

So my question is:
How it the number of hugepages related to the physical memory ? or
more specifically,
I want to allocate 4096 2MB pages on this host which has 4 GB physical
RAM. Is it possible at all ?
because 4096*2 gives 8192MB,  which is about 8GB, and if it is about
the full size of the physical memory on this host.

I doubt whether the host can boot at all with such a command line ?
Or is this calculation is not related to the physical memory but to
virtual memory ?


Regards,
Kevin



More information about the Kernelnewbies mailing list