Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have an Ubuntu 32bit virtualized machine for some time now on my 4 processor server. I gave it one processor but now I need more power. I added the second in Virtualbox settings but virtualized ubuntu still thinks it's only one processor:

cat /proc/cpuinfo 
processor   : 0
vendor_id   : GenuineIntel
cpu family  : 6
model       : 15
model name  : Intel(R) Core(TM)2 Quad CPU    Q6600  @ 2.40GHz
stepping    : 11
cpu MHz     : 2405.790
cache size  : 6144 KB
physical id : 0
siblings    : 1
core id     : 0
cpu cores   : 1
apicid      : 0
initial apicid  : 0
fdiv_bug    : no
hlt_bug     : no
f00f_bug    : no
coma_bug    : no
fpu     : yes
fpu_exception   : yes
cpuid level : 5 
wp      : yes
flags       : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx lm constant_tsc up pni ssse3 lahf_lm
bogomips    : 4811.58
clflush size    : 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:

Is there a way to make my virtualized Ubuntu machine aware of a second processor?

share|improve this question

There is a section in Virtualbox documentation on CPU Hot-Plugging. That details the procedure of adding another CPU to Linux guests.

With Linux guests, the following applies: To prevent ejection while the CPU is still used it has to be ejected from within the guest before. The Linux Guest Additions contain a service which receives hot-remove events and ejects the CPU. Also, after a CPU is added to the VM it is not automatically used by Linux. The Linux Guest Additions service will take care of that if installed. If not a CPU can be started with the following command:

echo 1 > /sys/devices/system/cpu/cpu<id>/online

On the Known Limitations page, some drawbacks of the SMP capabilities of 32bit guests are listed. Mostly performance issues:

Poor performance with 32-bit guests on certain Intel CPU models that do not include virtual APIC hardware optimization support. This affects mainly Windows and Solaris guests, but possibly also some Linux kernel revisions. Partially solved in 3.0.12 for 32 bits Windows NT, 2000, XP and 2003 guests. Requires 3.0.12 or higher Guest Additions to be installed.

It does not say that multi processing is not possible.

share|improve this answer
Unfortunatly this doesn't work. I have Virtualbox additions installed and this trick with echo 1 > /sys/devices/system/cpu/cpuid... there is no such directory on my virtual ubuntu. – enedene Oct 27 '11 at 20:32
Make sure you replace <id> with a number eg. 0, 1, etc. So that the file name gets /sys/devices/system/cpu/cpu1/online. Also please read the Hot-Plugging chapter, because the VM needs some preparation to be able to handle the hot plugging. – lgarzo Oct 28 '11 at 7:51
of course :) But it's simply not there, online file/directory doesn't exist. – enedene Oct 28 '11 at 8:16
Unfortunately I do not have hands-on experience, so I'm just guessing. If you have the cpu1 directory (and you should, since you added a new CPU), you could try to create the online file with the above command and see if the CPU gets used. Or as an alternative, the VBoxManage commands could help. – lgarzo Oct 28 '11 at 8:27
/sys/devices/system/cpu there is a online offline file here, not in /sys/devices/system/cpu/cpu0, I'll try modifying that file today, after all users have disconnected from my virtual machine and will state results. – enedene Oct 28 '11 at 8:28

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.