[libvirt][PATCH] running libvirt on the latest kvm snapshot

Chris Lalancette clalance at redhat.com
Fri Aug 7 11:57:34 UTC 2009


Anton Protopopov wrote:
> Hi.
> 
> Libvirt tryes to extract kvm version from the string
>   "QEMU PC emulator version <major>.<minor>.<micro> (kvm-<version>)..."
> For examle,
>   # kvm -help | head -1
>   QEMU PC emulator version 0.10.0 (kvm-85), Copyright (c) 2003-2008
> Fabrice Bellard
> 
> The problem occures if you are trying to run it on the devel version of kvm:
>   # kvm -help | head -1
>   QEMU PC emulator version 0.10.0 (kvm-devel), Copyright (c) 2003-2008
> Fabrice Bellard
> The virParseNumber() obvioulsy fails on the "devel" string here. I
> propose to setup
> `kvm_version' to 1000 (that's enough, I think) in that case, so all
> checks, such as
>   if (kvm_version > 74) ...
> will pass.

Yeah, I've run into this too.  The problem with just setting kvm_version to a
huge number is that if you built a kvm development snapshot a long time in the
past, and you run it now, then you will be turning on features your old
development snapshot didn't necessarily have.  On the other hand, if you are
running development snapshots, you get to keep both pieces when things break.
Maybe we can set the kvm_version number very high like you say, but also dump a
warning message out to the logfile saying this is a development version so the
poor sap who has to debug something like this has a fighting chance.  Any other
opinions?

-- 
Chris Lalancette




More information about the libvir-list mailing list