PAE is now the standard for a 32 bit Ubuntu, so there is no need for enabling.

If you on the other hand are trying to install L/X/K/Ubuntu >= 12.10 on hardware without PAE support this guide might be helpful.


What is PAE?

Physical Address Extension is a technology which allows 32 bit operating systems to use up to 64 Gb of memory (RAM), something which is normally achieved by switching to a 64 bit system. PAE is supported on the majority of computers today and it is an easy procedure to enable it in Ubuntu, if it is not already. To check if your processor supports PAE, try:

grep --color=always -i PAE /proc/cpuinfo

In general, a proper 64 bit system is recommended if you have 4 Gb or more memory and/or want to get the full benefit of the 64 bit architecture (see 32bit_and_64bit), but in some cases making a complete switch to 64 bit is not desirable, and using PAE can be a viable compromise.

It should be noted that there is no "Virtual Address Extension." i.e. The applications still get the same amount of virtual memory since the virtual addresses are still 32 bits while the physical addresses are 36 bits. Therefore PAE is not at all equivalent to a 64 bit system.

Pentium M laptops

Many Pentium M CPUs have PAE disabled by default, but it can be enabled by the user. At the moment this requires some workarounds to install or upgrade Ubuntu 14.04.

Upgrading to 14.04 on Pentium M laptop

The upgrade will be blocked with the message "Your system uses a CPU that does not have PAE enabled. Ubuntu only supports non-PAE systems up to Ubuntu 12.04. To upgrade to a later version of Ubuntu, you must enable PAE (if this is possible)". There are two things you must do to successfully upgrade:

  • Install a PAE kernel (to verify your system is PAE capable)

     apt-get install linux-image-generic-pae
     # reboot and then...
     uname -a
     # will output something like "linux ubuntu 3.11.0-17-generic ..."
     # kernel version should be 3.11.0 or above (3.2.0 was the last non-PAE kernel, so anything above that is PAE)
  • Add "pae" flag to /proc/cpuinfo

     cat /proc/cpuinfo | sed 's/flags\t*:/& pae/' > /tmp/cpuinfo_pae
     mount -o bind /tmp/cpuinfo_pae /proc/cpuinfo
     mount -o remount,ro,bind /proc/cpuinfo
     grep flags /proc/cpuinfo
     # should output "flags : ... pae ..."

Installing on Pentium M laptop (with forcepae)

The ISO image will fail to boot ("This kernel requires the following features not present on the CPU: pae.") If a few lines above this text there is a warning "WARNING: PAE disabled. Use parameter 'forcepae' to enable at your own risk!", then you can boot by pressing tab at the boot screen and appending the kernel parameter "forcepae" after the "-- ".

Installing on Pentium M laptop (without forcepae)

The ISO install images use syslinux to boot the Linux kernel. The boot fails because syslinux jumps to the 16-bit entry point of the kernel which does a CPU check. Grub bypasses the 16-bit code and jumps directly to the 32-bit entry point. Thus, the boot will be successful if syslinux is replaced with Grub.

  • Download ISO of ubuntu flavor you wish to use, for example, xubuntu. I will use the name xubuntu.iso, for convenience.
  • partition and format USB stick, in this example, /dev/sdb and /dev/sdb1. The USBStick has to be larger then the iso. Use mkvfat for formatting of /dev/sdb1.
  • Eject and insert the USB to have the automounter mount the USB drive. Make note of the location.
  • Use grub to install grub to the USB stick
    • grub-install --no-floppy --root-directory=/media/ubuntu/2341-af31/ (obviously this will have to match the mounted path)
  • grub-mkconfig > /media/ubuntu/2341-af31/boot/grub/grub.cfg

Open grub.cfg in your favorite editor and remove all the menuentry sections to replace it with the following.

menuentry "Xubuntu (32bit)" {
  iso_path=/xubuntu-13.10-dvd-i386.iso
  export iso_path
  search --set --file $iso_path
  loopback loop $iso_path
  root=(loop)
  configfile /grub/loopback.cfg
  loopback --delete loop
}

Save, unmount and reboot from the USB stick.

What will happen is, the USB stick will be booted as usual by grub, grub will then do a loopback mount of the iso, as is (so no modification to it required). The beauty of this all is, you can add MORE iso's and just add menu entries for them. So xubuntu 32bit, 64bit, gnomebuntu, you name it, you can add it. The only requirement is that the iso does actually support grub booting (e.g. has the /grub/loopback.cfg). Not all iso's have this!

How to Enable PAE

Ubuntu 12.10 (Quantal) and onwards

The generic default kernel already has PAE enabled.

For more on this, please see the Quantal technical overview, and the announcement by the Ubuntu Technical Board.

Ubuntu 10.04 LTS (Lucid Lynx) to Ubuntu 12.04 LTS (Precise)

Both the CD and DVD installer of Ubuntu automatically installs the PAE enabled kernel if it detects more than 3 Gb of available memory. In the case of the liveCD, a working network connection is required, since the PAE enabled kernel packages are not present on the CD.

If you need to enable PAE manually, follow the instructions below.

Enabling PAE manually

The PAE enabled kernel can be installed using the Synaptic Package Manager (accessible from the System menu under Administration -> Synaptic Package Manager): The relevant packages are called "linux-generic-pae" and "linux-headers-generic-pae" and should be easily found with a search for "pae".

Alternatively they can be installed using either apt-get or aptitude through the terminal:

sudo apt-get install linux-generic-pae linux-headers-generic-pae

After a reboot the PAE kernel should be booted as the default option in the GRUB boot menu.

To confirm that PAE was enabled correctly you can use the system monitor form the System menu under Administration -> System Monitor. The first tab shows usable memory.

Removing non-PAE kernels

If PAE was successfully enabled you may want to remove the meta-packages for the normal kernel, in order to disable unnecessary updates to the non-PAE kernels:

sudo apt-get remove linux-generic linux-image-generic linux-headers-generic

If you want to remove all of the old kernels from your boot menu, it seems like you have to do it all manually:

sudo apt-get remove linux-image-<version number>-generic linux-headers-<version number>-generic

Something went wrong

If something went wrong, just remove the PAE kernel packages using either synaptic or apt-get/aptitude. If you did not specifically remove the non-PAE kernel packages, they should still be present on the system and automatically selected as the default when the PAE kernel is removed.

The relevant PAE kernel packages are:

linux-image-generic-pae  linux-image-<version number>-generic-pae linux-headers-generic-pae linux-headers-<version number>-generic-pae


CategoryKernel

EnablingPAE (last edited 2014-04-17 18:50:11 by chris-bainbridge)