64-Bit Processors
In 2004, the 64-bit processor was introduced into the computer market. In the beginning, these 64-bit processors were only used for servers, but ones such as the AMD Athlon™ 64 are now being used for desktop computers as well.
Red Hat Enterprise Linux supports both 32-bit and 64-bit processors. If you have a system with a 64-bit processor, install the 64-bit version of the operating system if you want the 64-bit kernel, libraries, and available applications to be installed.
Most of the modern 64-bit processors such as the AMD64 and EM64T can also run 32-bit applications if the operating
system also supports it. 32-bit support is installed by default when installing the 64-bit version of Red Hat Enterprise Linux.
To run both 32-bit and 64-bit applications, both sets of libraries must be installed. Having both the 64-bit and 32- bit versions of a library installed at the same time is known as multilib. Red Hat Enterprise Linux allows for this by following the FHS guidelines. 32-bit libraries are installed in /lib/ and /usr/lib/, and 64-bit libraries are installed in /lib64/ and /usr/lib64/.
NOTE
For the complete FHS guidelines explanation of how 32-bit and 64-bit libraries co-
exist, refer to http://www.pathname.com/fhs/pub/fhs-2.3.html#LIB64.

Some packages have been compiled for the 64-bit architecture but are available in a 32-bit version as well. When using Red Hat Network to install a package on a 64-bit system with the 64-bit version of the OS installed, the 64-bit version of the package is installed if
available. If the 32-bit version is the only one available, it is installed. If both versions are available, the architecture can be specified if installing from Red Hat Network:

yum install <package_name>.<arch>
Replace <arch> with the 32-bit architecture compatible with your 64-bit processor such as i386 for Intel Itanium, AMD64, and EM64T systems. If you are selecting a package to install via the RHN website, the architecture is included in the package name such as
glibc-2.3.4-2.i686 and glibc-2.3.4-2.ia64. If you are installing software directly from the RPM package file, remember that the filename includes the architecture such as glibc-2.3.4-2.i686.rpm. Table 8.1 shows the architecture abbreviations used in the RPM
filename and in the package name listed on the RHN website. It also shows the compati- ble 32-bit architectures.
TABLE 8.1 Compatible Architectures
Processor RPM Architecture Compatible 32-Bit Architectures
Intel Itanium ia64 i386, i686
AMD64, EM64T x86_64 i386, i686
IBM POWER ppc64 ppc
IBM zSeries s390x s390
After installing both versions of a library, how can you verify they are both installed? The rpm -q <package-name> command doesn’t display the architecture of the package by default. But, the command can be configured to show this information by using the –queryformat option:
#rpm -q <package-name> –queryformat=’%{NAME}-%{VERSION}.%{ARCH}\n’

This changes the format displayed to also include a period at the end of the package name followed by the architecture such as the following for two different builds of glibc:
glibc-2.3.4-2.19.i686
glibc-2.3.4-2.19.x86_64
This option is very useful, but it is not easy to remember. Luckily, this format can be saved as the default for each user. In your home directory, create a .rpmmacros file if you don’t already have one. In this file, add the following line:
%_query_all_fmt %%{name}-%%{version}-%%{release}.%%{arch}

Duplicate this file for each user who wants to view the architecture of the packages queried.
TIP
Add this formatting line to the .rpmmacros file for the root user as well if you often
perform RPM queries as root. Multi-Core Processors
A multi-core processor is a processor that contains one or more processor cores on a single processor chip, with each core having its own dedicated cache. The advantages of using multi-core processors include the following:
>. More processor cores on a single processor means a smaller physical footprint for a multi-processor machine. More processor cores can fit in a single unit.
>. If combined with Virtualization or a similar technology, each processor core can be dedicated to a virtual machine. Just switching to dual-core processors doubles the number of virtual machines with a dedicated processor. Refer to Appendix B, “Creating Virtual Machines,” for details on implementing the Virtualization layer.

The Linux kernel recognizes the number of physical processors, the number of processor cores on each physical processor, and the total number of processor cores. It uses each processor core as it would a separate physical processor. In addition to the processor vendor, speed, and cache size, the /proc/cpuinfo virtual file shows information about the processor cores. To view the contents of this virtual file, use the cat /proc/cpuinfo command.

Similar to the previous example for the multi-core processors, look at the processor, physical id, core id, and cpu cores fields to verify that the system is recognized as one with HT Technology. The processor count goes from 0 to 1, indicating that, as far as the
operating system is considered, there are two processors to send data to for execution. The physical id is 0 for both, meaning that there is only one physical processor. The value of cpu cores is 1, and the value of core id is 0 for both, meaning that the proces- sor is not a multi-core processor. Thus, the processor must have HT Technology because the virtual processor count is 2 with only one processor core.
Hyper-Threading can be disabled at boot-time with a kernel option passed to the kernel using the GRUB boot loader. This process only disables Hyper-Threading for one boot instance. It must be repeated on subsequent boots to continue disabling Hyper-Threading.
The steps are as follows:
1. When the GRUB boot menu appears, use the up and down arrows to select the
kernel to boot.
2. Press the E key to add a kernel option to the kernel selected.
3. At the end of the line, add a space and then the noht kernel option.
4. Press Enter to return to the GRUB boot menu.
5. Press the B key to boot the system.
Hyper-Threading can be disabled for all subsequent boots if the kernel option is added to the GRUB configuration file. As root, open the /etc/grub.conf file and find the kernel stanza for which you want to disable Hyper-Threading. Find the kernel line for the stanza,
add a space to the end, and add the noht kernel option as shown in Listing 8.3.

LISTING 8.3 Disabling Hyper-Threading with GRUB
default=0
timeout=15
splashimage=(hd0,0)/boot/grub/splash.xpm.gz
hiddenmenu
title Red Hat Enterprise Linux (2.6.16-1.2133)
root (hd0,0)
kernel /boot/vmlinuz-2.6.16-1.2133 ro root=LABEL=/ rhgb quiet noht
initrd /boot/initrd-2.6.16-1.2133.imgSummary
This chapter explained what to look for when using Red Hat Enterprise Linux on 64-bit
and multi-core systems as well as systems with Hyper-Threading Technology. Install Red
Hat Enterprise Linux on these systems as you would for any other system. For the 64-bit
system, be sure to install the 64-bit version of the operating system. For a multi-core
system, the number of processor cores is detected, and the appropriate kernel is installed.