WARNING: NR_CPUS limit of 1 reached. Processor ignored.
Not exactly the error message that you were hoping to see when you were checking you dmesg logs. Don’t panic, this is easily remedied. If you are wondering how to check your own Linux system for this error you can look by using this command:
dmesg | grep -i cpu
This error occurs on a multiple logical processor system when a uniprocessor kernel is loaded. What the error indicates is that one CPU is being used and that more have been found but are being ignored. The system should come online correctly but with only a single logical CPU. (For a detailed discussion on logical processors see CPUs, Cores and Threads.)
In today’s market full of multi-core CPU products and hyperthreading this error message has moved from the exclusive realm of multi-socket servers to the home desktop and laptop. It is now a potentially common site for many casual Linux users.
To correct this issue on a Red Hat, CentOS or Fedora Linux system all you will need to do is make a simple change to your GRUB configuration to tell it to point to a symmetrical multiprocessor (smp) kernel rather than the uniprocessor kernel. The file that you will need to edit is /etc/grub.conf. After some header comments the beginning of your file should look something like this:
default=1 timeout=5 splashimage=(hd0,0)/grub/splash.xpm.gz hiddenmenu title CentOS (2.6.9-67.0.7.plus.c4smp) root (hd0,0) kernel /vmlinuz-2.6.9-67.0.7.plus.c4smp ro root=/dev/VG0/LV0 initrd /initrd-2.6.9-67.0.7.plus.c4smp.img title CentOS (2.6.9-67.0.7.plus.c4) root (hd0,0) kernel /vmlinuz-2.6.9-67.0.7.plus.c4 ro root=/dev/VG0/LV0 initrd /initrd-2.6.9-67.0.7.plus.c4.img
The GRUB configuration file can appear daunting at first but, in reality, it is quite simple to deal with. The only line with which we are concerned with making modifications is the “default” line value. In this case it is set to 1. The grub.conf file contains a list of available kernels for us to use. We may have just one or possible several, maybe even dozens. In this case we see two. You can see here that we have a CentOS 2.6.9 c4smp and a CentOS 2.6.9 c4 kernel. You only need to be concerned with the “title” lines. These are your kernel titles. Normally the kernels of most interest will be at the top of the file.
You can check the name of the kernel that you are currently running by issuing:
The first title line is kernel “0”, the second is kernel “1”, the next “2” and so forth. Right now our “default” value is pointing to “1” which is the second kernel from the top and, as you will notice, not an smp kernel (therefore it is a uniprocessor kernel.) In this case all we need to do is change the “default” value from “1” to “0” so that it now points to the first kernel option which for us is the smp kernel.
After your grub.conf file has been saved you make reboot the Linux system. If all goes well it will return to you with additional logical processors enabled. You can verify the name of the loaded kernel with the command given above.
I’d also look in /proc/cpuinfo .
/proc/cpuinfo does not, I believe, have an indicator that additional logical CPUs exist but are not active. This would allow you to check whether or not you have made them visible to the kernel but it would not indicate that you have more than you have visible unless you knew that they were there ahead of time.
Leave a comment