LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (http://www.linuxquestions.org/questions/linux-general-1/)
-   -   Is it unusual for something to run faster under vmware than native? (http://www.linuxquestions.org/questions/linux-general-1/is-it-unusual-for-something-to-run-faster-under-vmware-than-native-484175/)

dggoldst 09-16-2006 05:39 PM

Is it unusual for something to run faster under vmware than native?
 
I have a Dell Optiplex Gx620 dual-core pentium 4 machine.

I'm dual booting ubuntu 6.06 in one partition, windows XP in another.

using VMWare's browser appliance (basically ubuntu) under XP, if I execute in a terminal

date; factor 18446744073709551557; date

it terminates in about 35 seconds

Booting into ubuntu native, the same call takes 55 seconds. I took both measurements a few times.

Is it that Ubuntu's basic install doesn't properly exploit the dual-core?

Thanks!

b0uncer 09-18-2006 01:58 AM

Check out whether your Ubuntu's kernel has SMP built in or not. If it doesn't have, then you can't take advantage of more than one processing unit..

dggoldst 09-19-2006 09:47 AM

Hi B0ouncer,

I have a stupid question, how would I check if it has SMP? Ubuntu 6.06 is very common so it might be easy to find out, right? I figured on a questions site other people might benefit from the answer as well.

trickykid 09-19-2006 11:03 AM

Quote:

Originally Posted by dggoldst
Hi B0ouncer,

I have a stupid question, how would I check if it has SMP? Ubuntu 6.06 is very common so it might be easy to find out, right? I figured on a questions site other people might benefit from the answer as well.

uname -a will tell you your running kernel.. look for SMP in the output.

dggoldst 10-07-2006 05:50 AM

Ok, this is strange, I've now got an SMP kernel running

$ uname -a
Linux box 2.6.17 #4 SMP PREEMPT Wed May 10 13:53:45 CEST 2006 i686 GNU/Linux

and it's detecting dual-core,and still the thing runs faster in virtualization under XP than native (52 vs 35 seconds) I really wish this weren't so. I wonder for how many people this is true.

dggoldst 10-07-2006 06:46 AM

Figured it out!

It acutally doesn't run faster under virtualization, it's just that you can't trust timekeeping under virtualization. When you execute the following script, it works out about the same (about 55 seconds) virtualized or native.

Code:

#!/bin/sh
ntpdate tick.usno.navy.mil
hwclock -w
date
factor 18446744073709551557
ntpdate tick.usno.navy.mil
hwclock -w
date

Equaling native is impressive for virtualization, though...


All times are GMT -5. The time now is 04:31 AM.