2.2. 32 bit Architecture and the hugemem Kernel
In Red Hat Enterprise Linux 3, 4 or 5 the smp kernel can be used on systems with up to 16 GB of RAM. The hugemem kernel is required in order to use all the memory on systems that have more than 16GB of RAM up to 64GB. However, it is recommend to use the hugemem kernel even on systems that have 8GB of RAM or more due to the potential issue of "low memory" starvation (see next section) that can happen on database systems with 8 GB of RAM. The stability you get with the hugemem kernel on larger systems outperforms the performance overhead of address space switching.
With x86 architecture the first 16MB-896MB of physical memory is known as "low memory" (ZONE_NORMAL) which is permanently mapped into kernel space. Many kernel resources must live in the low memory zone. In fact, many kernel operations can only take place in this zone. This means that the low memory area is the most performance critical zone. For example, if you run resource-intensive applications or have a lot of memory installed and are simultaneously running resource-intensive applications, memory addresses below 896MB can become constrained. This happens because more kernel structures must be allocated to these low memory addresses. Low memory starvation happens when
/proc/meminfo becomes very low accompanied by a sudden spike in paging activity. To free up memory in the low memory zone, the kernel bounces buffers aggressively between low memory and high memory which becomes noticeable as paging (do not confuse it with paging to the swap partition). If the kernel is unable to free up enough memory in the low memory zone, then the kernel can hang the system.
Paging activity can be monitored using the
vmstat command or using the
sar command (option '
-B') which comes with the
sysstat RPM. Since Linux tries to utilize the whole low memory zone, a low LowFree in
/proc/meminfo does not necessarily mean that the system is out of low memory. However, when the system shows increased paging activity when
LowFree gets below 50MB, then the hugemem kernel should be installed. The stability you gain from using the hugemem kernel makes up for any performance impact resulting from the 4GB-4GB kernel/user memory split in this kernel (a classic 32 bit x86 system splits the available 4 GB address space into 3 GB virtual memory space for user processes and a 1 GB space for the kernel). To see some allocations in the low memory zone, refer to
slabtop(1) for more information. Note that Huge Pages would free up memory in the low memory zone since the system has less bookkeeping to do for that part of virtual memory, see Chapter 17, Using Very Large Memory (VLM).
If you install the Red Hat Enterprise Linux 3, 4 or 5 hugemem kernel ensure that any proprietary drivers you are using (e.g. proprietary multipath drivers) are certified with the hugemem kernel.
In Red Hat Enterprise Linux 2.1, the smp kernel is capable of handling up to 4GB of RAM. The
kernel-enterprise kernel should be used for systems with more than 4GB of RAM up to 16GB.
In Red Hat Enterprise Linux 5, a 32 bit kernel is always a hugemem kernel so there is no need to install a special kernel.