LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud
User Name
Password
Linux - Virtualization and Cloud This forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.

Notices

Reply
 
LinkBack Search this Thread
Old 01-06-2013, 05:15 PM   #1
billotronic
LQ Newbie
 
Registered: Jan 2013
Location: The Region, Indiana
Distribution: Xubuntu, unRAID, ICS, DSL, Archbang, Rasbian
Posts: 10

Rep: Reputation: 0
Linux guest only shows one cpu core


Trying to diagnose performance issues led me to the CPU and low and behold my slow running vm apparently is being shorted a core. VBoxManage recognizes two cores assigned to the vm, but the guest is not registering both cores.

here is some info:

unrad host

Code:
root@master_control:~# uname -a
Linux master_control 3.4.11-unRAID #1 SMP Mon Sep 17 17:36:21 PDT 2012 i686 AMD A6-3500 APU with Radeon(tm) HD Graphics AuthenticAMD GNU/Linux
xubuntu guest

Code:
x@xvb:~$ uname -a
Linux xvb 3.5.0-21-generic #32-Ubuntu SMP Tue Dec 11 18:52:46 UTC 2012 i686 athlon i686 GNU/Linux
unraid host /proc/cpuinfo

Code:
root@master_control:~# cat /proc/cpuinfo
processor	: 0
vendor_id	: AuthenticAMD
cpu family	: 18
model		: 1
model name	: AMD A6-3500 APU with Radeon(tm) HD Graphics
stepping	: 0
microcode	: 0x3000027
cpu MHz		: 2400.000
cache size	: 1024 KB
physical id	: 0
siblings	: 3
core id		: 0
cpu cores	: 3
apicid		: 0
initial apicid	: 0
fdiv_bug	: no
hlt_bug		: no
f00f_bug	: no
coma_bug	: no
fpu		: yes
fpu_exception	: yes
cpuid level	: 1
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc nonstop_tsc extd_apicid pni cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt arat cpb hw_pstate npt lbrv svm_lock nrip_save pausefilter
bogomips	: 4943.78
clflush size	: 64
cache_alignment	: 64
address sizes	: 40 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate cpb

processor	: 1
vendor_id	: AuthenticAMD
cpu family	: 18
model		: 1
model name	: AMD A6-3500 APU with Radeon(tm) HD Graphics
stepping	: 0
microcode	: 0x3000027
cpu MHz		: 800.000
cache size	: 1024 KB
physical id	: 0
siblings	: 3
core id		: 1
cpu cores	: 3
apicid		: 1
initial apicid	: 1
fdiv_bug	: no
hlt_bug		: no
f00f_bug	: no
coma_bug	: no
fpu		: yes
fpu_exception	: yes
cpuid level	: 1
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc nonstop_tsc extd_apicid pni cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt arat cpb hw_pstate npt lbrv svm_lock nrip_save pausefilter
bogomips	: 4943.78
clflush size	: 64
cache_alignment	: 64
address sizes	: 40 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate cpb

processor	: 2
vendor_id	: AuthenticAMD
cpu family	: 18
model		: 1
model name	: AMD A6-3500 APU with Radeon(tm) HD Graphics
stepping	: 0
microcode	: 0x3000027
cpu MHz		: 800.000
cache size	: 1024 KB
physical id	: 0
siblings	: 3
core id		: 2
cpu cores	: 3
apicid		: 2
initial apicid	: 2
fdiv_bug	: no
hlt_bug		: no
f00f_bug	: no
coma_bug	: no
fpu		: yes
fpu_exception	: yes
cpuid level	: 1
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm 3dnowext 3dnow constant_tsc nonstop_tsc extd_apicid pni cx16 popcnt lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt arat cpb hw_pstate npt lbrv svm_lock nrip_save pausefilter
bogomips	: 4943.78
clflush size	: 64
cache_alignment	: 64
address sizes	: 40 bits physical, 48 bits virtual
power management: ts ttp tm stc 100mhzsteps hwpstate cpb
xububunt guest
Code:
x@xvb:~$ cat /proc/cpuinfo
processor	: 0
vendor_id	: AuthenticAMD
cpu family	: 18
model		: 1
model name	: AMD A6-3500 APU with Radeon(tm) HD Graphics
stepping	: 0
cpu MHz		: 2471.826
cache size	: 1024 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	: 1
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx fxsr_opt rdtscp 3dnowext 3dnow up extd_apicid pni cmp_legacy cr8_legacy arat
bogomips	: 4943.65
clflush size	: 64
cache_alignment	: 64
address sizes	: 40 bits physical, 48 bits virtual
power management:
vboxmanage check of cores

Code:
root@master_control:~# VBoxManage modifyvm xub3 --plugcpu 1
VBoxManage: error: CPU 1 is already attached
VBoxManage: error: Details: code VBOX_E_OBJECT_IN_USE (0x80bb000c), component SessionMachine, interface IMachine, callee nsISupports
VBoxManage: error: Context: "HotPlugCPU(ValueUnion.u32)" at line 614 of file VBoxManageModifyVM.cpp
root@master_control:~# VBoxManage modifyvm xub3 --plugcpu 0
VBoxManage: error: CPU 0 is already attached
VBoxManage: error: Details: code VBOX_E_OBJECT_IN_USE (0x80bb000c), component SessionMachine, interface IMachine, callee nsISupports
VBoxManage: error: Context: "HotPlugCPU(ValueUnion.u32)" at line 614 of file VBoxManageModifyVM.cpp
root@master_control:~# VBoxManage modifyvm xub3 --plugcpu 2
VBoxManage: error: CPU id exceeds number of possible CPUs [0:1]
VBoxManage: error: Details: code NS_ERROR_INVALID_ARG (0x80070057), component SessionMachine, interface IMachine, callee nsISupports
VBoxManage: error: Context: "HotPlugCPU(ValueUnion.u32)" at line 614 of file VBoxManageModifyVM.cpp

I am completly lost here. Super forums users, please give me some ideas.

Thanks!
 
Old 01-06-2013, 05:41 PM   #2
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,716

Rep: Reputation: 634Reputation: 634Reputation: 634Reputation: 634Reputation: 634Reputation: 634
Are you sure the output didn't just cut off? .. there is no power management info listed ...

Try running 'top' then pressing '1' (one) to show per-cpu stats
 
1 members found this post helpful.
Old 01-06-2013, 05:59 PM   #3
billotronic
LQ Newbie
 
Registered: Jan 2013
Location: The Region, Indiana
Distribution: Xubuntu, unRAID, ICS, DSL, Archbang, Rasbian
Posts: 10

Original Poster
Rep: Reputation: 0
Code:
top - 18:54:42 up  1:38,  2 users,  load average: 2.63, 2.78, 2.78
Tasks: 161 total,   3 running, 158 sleeping,   0 stopped,   0 zombie
%Cpu0  : 19.8 us, 63.2 sy,  0.0 ni,  0.0 id,  0.0 wa,  0.0 hi, 17.0 si,  0.0 st
KiB Mem:   3622892 total,  3413636 used,   209256 free,     1340 buffers
KiB Swap:        0 total,        0 used,        0 free,  3157280 cached

  PID USER      PR  NI  VIRT  RES  SHR S  %CPU %MEM    TIME+  COMMAND                                                                                                                                
 2056 x         20   0  307m  83m  25m R  59.4  2.4  49:33.37 fsm                                                                                                                            
 2115 root      20   0  7188 3884 2200 R  26.2  0.1  17:54.56 openvpn                                                                                                                                
 1169 root      20   0  320m  32m  11m S   8.0  0.9   1:19.43 Xorg                                                                                                                                   
 1933 x         20   0 74076  12m 9432 S   4.6  0.4   0:02.50 xfce4-terminal                                                                                                                         
 1601 x         20   0  9764 1392  920 S   1.7  0.0   2:17.48 VBoxClient                                                                                                                             
 2354 x         20   0  5368 1356  996 R   0.7  0.0   0:00.21 top                                                                                                                                    
  342 root      20   0     0    0    0 S   0.3  0.0   0:01.84 jbd2/sda1-8                                                                                                                            
  595 syslog    20   0 30168 1160  888 S   0.3  0.0   0:09.24 rsyslogd                                                                                                                               
 1625 x         20   0 23188 8760 7100 S   0.3  0.2   0:03.72 xfwm4                                                                                                                                  
 1655 x         20   0 79904  10m 7444 S   0.3  0.3   0:01.39 update-notifier                                                                                                                        
 1704 x         20   0 17092 2972 2536 S   0.3  0.1   0:01.45 at-spi2-registr                                                                                                                        
    1 root      20   0  3632 1940 1220 S   0.0  0.1   0:01.50 init                                                                                                                                   
    2 root      20   0     0    0    0 S   0.0  0.0   0:00.00 kthreadd                                                                                                                               
    3 root      20   0     0    0    0 S   0.0  0.0   0:04.38 ksoftirqd/0                                                                                                                            
    6 root      rt   0     0    0    0 S   0.0  0.0   0:00.00 migration/0                                                                                                                            
    7 root      rt   0     0    0    0 S   0.0  0.0   0:02.05 watchdog/0                                                                                                                             
    8 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 cpuset                                                                                                                                 
    9 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 khelper                                                                                                                                
   10 root      20   0     0    0    0 S   0.0  0.0   0:00.00 kdevtmpfs                                                                                                                              
   11 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 netns                                                                                                                                  
   12 root      20   0     0    0    0 S   0.0  0.0   0:00.11 sync_supers                                                                                                                            
   13 root      20   0     0    0    0 S   0.0  0.0   0:00.00 bdi-default                                                                                                                            
   14 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 kintegrityd                                                                                                                            
   15 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 kblockd                                                                                                                                
   16 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 ata_sff                                                                                                                                
   17 root      20   0     0    0    0 S   0.0  0.0   0:00.00 khubd                                                                                                                                  
   18 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 md                                                                                                                                     
   21 root      20   0     0    0    0 S   0.0  0.0   0:00.01 khungtaskd                                                                                                                             
   22 root      20   0     0    0    0 S   0.0  0.0   0:06.43 kswapd0                                                                                                                                
   23 root      25   5     0    0    0 S   0.0  0.0   0:00.00 ksmd                                                                                                                                   
   24 root      39  19     0    0    0 S   0.0  0.0   0:00.00 khugepaged                                                                                                                             
   25 root      20   0     0    0    0 S   0.0  0.0   0:00.02 fsnotify_mark                                                                                                                          
   26 root      20   0     0    0    0 S   0.0  0.0   0:00.00 ecryptfs-kthrea                                                                                                                        
   27 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 crypto                                                                                                                                 
   36 root       0 -20     0    0    0 S   0.0  0.0   0:00.00 kthrotld                                                                                                                               
   37 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_0                                                                                                                              
   38 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_1                                                                                                                              
   39 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_2                                                                                                                              
   40 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_3                                                                                                                              
   41 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_4                                                                                                                              
   42 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_5                                                                                                                              
   43 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_6                                                                                                                              
   44 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_7                                                                                                                              
   45 root      20   0     0    0    0 S   0.0  0.0   0:00.00 scsi_eh_8                                                                                                                              
x@xvb:~$
just showing one core
 
Old 01-06-2013, 06:28 PM   #4
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,716

Rep: Reputation: 634Reputation: 634Reputation: 634Reputation: 634Reputation: 634Reputation: 634
Sorry, I didn't notice your original output:
Code:
...
physical id	: 0
siblings	: 1
core id		: 0
cpu cores	: 1
...
Yes, you are correct, the kernel in your xubuntu is only seeing one core/cpu .. maybe you could try 12.10 which has the 3.5.5 kernel? Also, did you specifically need the 32bit version ?
 
Old 01-06-2013, 06:55 PM   #5
billotronic
LQ Newbie
 
Registered: Jan 2013
Location: The Region, Indiana
Distribution: Xubuntu, unRAID, ICS, DSL, Archbang, Rasbian
Posts: 10

Original Poster
Rep: Reputation: 0
I will update and try again.

Host os is 32 bit so I would assume that prevents 64bit guests?
 
Old 01-06-2013, 08:03 PM   #6
jefro
Guru
 
Registered: Mar 2008
Posts: 10,246

Rep: Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255
I would think that most newer systems running 32 bit can run a 64 bit client. I forget what the issue was but it may be that your motherboard or host can't run more than one cpu in a 64 bit mode under 32 bit host. It may be the limit of the vm under such also.

Not sure where that info, maybe on virtual box help files.

Last edited by jefro; 01-07-2013 at 08:23 AM.
 
Old 01-06-2013, 08:24 PM   #7
billotronic
LQ Newbie
 
Registered: Jan 2013
Location: The Region, Indiana
Distribution: Xubuntu, unRAID, ICS, DSL, Archbang, Rasbian
Posts: 10

Original Poster
Rep: Reputation: 0
Ok, figured both out with the same solution (bonus right?)

This was right under my nose the whole time. I did not select Enable I/O APIC since I had no clue what it was. You would think that since there is a slide bar for assigning cores, that is all you would need? WRONG! lol. From the VB manual:

Code:
Note: Enabling the I/O APIC is required for 64-bit guest operating systems, especially Windows Vista; it is also required if you want to use more than one virtual CPU in a virtual machine.

However, software support for I/O APICs has been unreliable with some operating systems other than Windows. Also, the use of an I/O APIC slightly increases the overhead of virtualization and therefore slows down the guest OS a little.
AND thats what I couldn't go 64bit when I tried! So with this selected I now have two cores showing in top and x64 xubuntu installing. I've been messing around with vb for little over a year now and have been screwing it up the whole time. No wonder my vm's were running so slow. I am now a happy camper.

Thanks for the help folks!
 
Old 01-07-2013, 06:32 AM   #8
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,716

Rep: Reputation: 634Reputation: 634Reputation: 634Reputation: 634Reputation: 634Reputation: 634
No problems .. the 'lm' flag in 'cat /proc/cpuinfo' stands for long mode, aka 64bit capable. If you see this flag then probably your best bet is to go with 64bit everywhere - host and guests.
 
Old 01-07-2013, 08:24 AM   #9
jefro
Guru
 
Registered: Mar 2008
Posts: 10,246

Rep: Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255
When all else fails. Read the manual?
 
Old 01-07-2013, 08:25 AM   #10
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Hanover, Germany
Distribution: Slackware
Posts: 14,865
Blog Entries: 2

Rep: Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798Reputation: 3798
Or use the GUI. It will warn you if something like that misconfiguration happens.
 
Old 01-07-2013, 08:41 AM   #11
billotronic
LQ Newbie
 
Registered: Jan 2013
Location: The Region, Indiana
Distribution: Xubuntu, unRAID, ICS, DSL, Archbang, Rasbian
Posts: 10

Original Poster
Rep: Reputation: 0
kbp- Stuck with 32bit on the host. People have managed to compile unraid in 64bit install it on slax, but that is a little beyond my scope to say the least. From my reading it looks like its a moot point due to the virtualization built into the hardware.

Jefro- There was a face palm involved, have no fear.

TobiSGD- I use phpVirtualBox for the bulk of my vm tasks. Regrettably, it will let you select multiple cores for a vm but not tell you to select the APIC so it will work. Gonna look into that and maybe put it a feature request if someone has not already. I'm sure I am not the first n00b to have this happen.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
centos guest shows shared folder empty pouya7525 Linux - Virtualization and Cloud 3 09-16-2012 05:58 AM
why does SCHED_FIFO task on one CPU affects other CPU tasks on a multy core system? reg13 Linux - Kernel 2 07-31-2011 09:48 PM
cpu frequency scaling with Pentium(R) Dual-Core CPU E5200 @ 2.50GHz tramni1980 Slackware 5 08-16-2009 08:29 AM
Boot with 'acpi=no'-Ubuntu shows one core,normal boot-kacpid process is eating 70%CPU WebEyeX Ubuntu 5 05-18-2008 06:48 AM
Samba shows shared folders in Windows but a Guest login pops up when trying to access ciphe Linux - Software 4 08-20-2007 11:55 AM


All times are GMT -5. The time now is 01:58 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration