2009-06-27 07:12:54

by James Dolan

[permalink] [raw]
Subject: Kernel testing in a VM good idea?

Are there any disadvantages to testing/developing a kernel in a VM ? (i
luck the availability of hardware)
--
Regards,
James


2009-06-27 07:21:59

by Aioanei Rares

[permalink] [raw]
Subject: Re: Kernel testing in a VM good idea?

James Dolan wrote:
> Are there any disadvantages to testing/developing a kernel in a VM ? (i
> luck the availability of hardware)
>
I personally prefer to find a spare machine to do testing/compiling
rather than a VM. Maybe the most experimented users of this list will
give you technically-oriented reasons.

2009-06-27 09:07:43

by Maciej Rutecki

[permalink] [raw]
Subject: Re: Kernel testing in a VM good idea?

2009/6/28 James Dolan <[email protected]>:
> Are there any disadvantages to testing/developing a kernel in a VM ? (i
> luck the availability of hardware)

To testing I use 2 machines: PC (mainly use for development,
multimedia) and laptop (work, home etc.). Firstly I test kernel on PC.
When I'm sure, that kernel doesn't cause any filesystem/hardware
error, lost data, then I test it also on laptop. When You can't use
more than one computer, I think that is good idea testing/development
on VM, before use real machine.

Regards
--
Maciej Rutecki
http://www.maciek.unixy.pl

2009-06-29 08:39:21

by Duane Griffin

[permalink] [raw]
Subject: Re: Kernel testing in a VM good idea?

2009/6/27 James Dolan <[email protected]>:
> Are there any disadvantages to testing/developing a kernel in a VM ? (i
> luck the availability of hardware)

To start with the obvious, with a VM you don't need extra hardware. If
you make a silly mistake and trash the filesystem all you need to do
is copy a file, not reinstall a whole system. The hack/install/test
cycle can be as quick and easy as "make && ./test.sh", instead of
requiring you to copy files across to another machine, reboot, etc.
You can easily script tests, e.g. to create and boot from a COW image,
drive the VM through its console, then run checks within the VM and
externally for whatever it is you testing. You can give those scripts
and images to others to use, too.

Cheers,
Duane.

--
"I never could learn to drink that blood and call it wine" - Bob Dylan

2009-06-29 15:25:15

by Petr Tesařík

[permalink] [raw]
Subject: Re: Kernel testing in a VM good idea?

James Dolan píše v So 27. 06. 2009 v 18:57 -0400:
> Are there any disadvantages to testing/developing a kernel in a VM ? (i
> luck the availability of hardware)

AFAICS the only unsurmountable problems you might encounter is timing
and performance. You can't predict how real hardware will work when it
comes to CPU and memory caches, system buses, hardware interrupts, large
CPU counts, NUMA factors, etc. But if any of those were of any concern
to you, you wouldn't have asked, I guess. ;-)

So, no, I don't think there are any important disadvantages when using
virtualized environment.

Petr Tesarik
SUSE Linux