Bug 103073 - hugepage documentation incorrect...
hugepage documentation incorrect...
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: kernel (Show other bugs)
All Linux
medium Severity high
: ---
: ---
Assigned To: Jason Baron
Brian Brock
Depends On:
  Show dependency treegraph
Reported: 2003-08-26 09:45 EDT by Johnray Fuller
Modified: 2013-03-06 00:55 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2003-09-26 12:30:54 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Johnray Fuller 2003-08-26 09:45:55 EDT
Description of problem:

The following documentation is incorrect:


It states that the kernel parameter to adjust for hugepages is
/proc/sys/vm/nr_hugepages. This file no longer exists. 

I believe the new file is:


Please verify the accuracy of this file as it is really the only documentation
about in the distribution that explains this feature.

Comment 1 Johnray Fuller 2003-08-26 10:24:33 EDT
This is also not how I understand it:

"Use the following command to dynamically allocate/deallocate hugepages:

	echo 20 > /proc/sys/vm/nr_hugepages

This command will try to configure 20 hugepages in the system."

I thought the value echoed is in megabytes and that this value is divided by the
size of the hugepages (2, 4 or 256 depending on the kernel) to determine the
total number of hugepages. So on an SMP x86 kernel, this command would create 10
hugepages. On a UP x86 kernel, this would create 5 hugepages, and on. 

Is my interpretation of this incorrect or is the documentation?

Comment 2 Jason Baron 2003-08-27 12:23:32 EDT
nr_hugepages is in 'page' units
hugetlb_page is in MB units...

for as3 we have the hugetlb_page interface
Comment 3 Johnray Fuller 2003-08-27 14:28:55 EDT
So /proc/sys/vm/hugetlb_pool and /proc/sys/vm/nr_hugepages are not synonymous
and function differently. But /proc/sys/vm/nr_hugepages is not present in Taroon.

Are their plans to add /proc/sys/vm/hugetlb_pool to this kernel document? As it
stands the inconsistency between the /proc chapter in the RG
(http://intranet.corp.redhat.com/docs/taroon/rhel-rg-en/ch-proc.html) and this
document are very confusing.

I reference this document because it is the only thing that explains how to set
up and use hugepages.

Also, does hugetlb_page = hugetlb_pool?


Comment 4 Jason Baron 2003-08-27 14:49:51 EDT
first, yes i mean hugetlb_pool, not hugetlb_page. i think generally the
Documentation directory in the kernel is understood to apply to the upstream
kernel, and is superceded by any Red Hat documentation. But, i'm not sure this
policy or understanding is explicitly laid out anywhere

Comment 5 Johnray Fuller 2003-08-27 17:05:46 EDT
So this document is not going to be updated or ammended?

We don't have the time to incorporate a Red Hat-specific version of this file
before deadline into the RG.

Is there any documentation online about the Red Hat implementation I can point
to by chance?

Finally, is everything else accurate in this document appart from the references
to nr_hugepages? If so, I can put a disclaimer in the proc chapter highlighting
that detail.

Comment 6 Jason Baron 2003-09-03 12:28:54 EDT
i don't think we're updating the the Documentation/vm/hugetlbpage.txt file. I
think everything there is correct w/respect to Red Hat's implementation, except
for the nr_hugepages, as you mentioned. 
Comment 7 Johnray Fuller 2003-09-08 17:14:58 EDT
The excerpt below is from the updated proc chapter, available online at the
following URL:


"Refer to /usr/src/linux-2.4/Documentation/vm/hugetlbpage.txt  for more
information about configuring hugepages.


Despite being mentioned in hugetlbpage.txt, the file /proc/sys/vm/nr_hugepages
does not exist within Red Hat Enterprise Linux. Instead hugetlb_pool should be
used to configure the number of hugepages available for the system. Also, it is
important to remember that nr_hugepages uses hugepage units, while hugetlb_pool
configures hugepages in megabytes."

Is this sufficient?
Comment 8 Jason Baron 2003-09-26 12:30:54 EDT
looks fine, i'm closing this

Note You need to log in before you can comment on or make changes to this bug.