I just tried to update the KVM packages (kvm and qemu-kvm) from Debian
squeeze to squeeze-backports on a developement machine.
But after upgrading, when trying to start an instance I get the error:
# gnt-instance startup lucy
Waiting for job 1540 for lucy.home.rieschl.com...
Job 1540 for lucy.home.rieschl.com has failed: Failure: command
execution error:
Could not start instance: Hypervisor error: Unable to get KVM version
# cat /var/log/ganeti/master-daemon.log
2012-03-05 13:12:56,980: ganeti-masterd pid=25300/JobQueue1/Job1542
ERROR Op 1/1: Caught exception in INSTANCE_STARTUP(lucy.home.rieschl.com)
Traceback (most recent call last):
File "/usr/lib/pymodules/python2.6/ganeti/jqueue.py", line 936, in
_ExecOpCodeUnlocked
timeout=timeout, priority=op.priority)
File "/usr/lib/pymodules/python2.6/ganeti/mcpu.py", line 352, in
ExecOpCode
priority)
File "/usr/lib/pymodules/python2.6/ganeti/mcpu.py", line 296, in
_LockAndExecLU
result = self._LockAndExecLU(lu, level + 1, calc_timeout, priority)
File "/usr/lib/pymodules/python2.6/ganeti/mcpu.py", line 305, in
_LockAndExecLU
result = self._LockAndExecLU(lu, level + 1, calc_timeout, priority)
File "/usr/lib/pymodules/python2.6/ganeti/mcpu.py", line 305, in
_LockAndExecLU
result = self._LockAndExecLU(lu, level + 1, calc_timeout, priority)
File "/usr/lib/pymodules/python2.6/ganeti/mcpu.py", line 256, in
_LockAndExecLU
result = self._ExecLU(lu)
File "/usr/lib/pymodules/python2.6/ganeti/mcpu.py", line 231, in _ExecLU
result = lu.Exec(self.Log)
File "/usr/lib/pymodules/python2.6/ganeti/cmdlib.py", line 5206, in Exec
raise errors.OpExecError("Could not start instance: %s" % msg)
OpExecError: Could not start instance: Hypervisor error: Unable to get
KVM version
2012-03-05 13:12:57,009: ganeti-masterd pid=25300/JobQueue1/Job1542 INFO
Finished job 1542, status = error
The ganeti version is 2.4.5 from squeeze-backports.
I think the problem is that the method _GetKVMVersion() in hv_kvm.py
expects a three digit version number, like "0.12.5" (that's the working
kvm version in the debian squeeze rep), but the KVM version in backports
reports "1.0":
# kvm --version (from squeeze):
QEMU PC emulator version 0.12.5 (qemu-kvm-0.12.5), Copyright (c)
2003-2008 Fabrice Bellard
# kvm --version (from squeeze-backports):
QEMU emulator version 1.0 (qemu-kvm-1.0 Debian 1.0+dfsg-8~bpo60+1),
Copyright (c) 2003-2008 Fabrice Bellard
BTW: that output is the same as the first line of "kvm --help".
Is there an easy fix for that problem? I'm not good in python but I
think I could modify the .py file and recompile the script if you tell
me what changes are necessary ;)
Thanks four your help!
Cheers,
Thomas
Thanks,
Guido
well, then I have an other request:
make 2.5 stable and put it in the debian backports ;)
ok, all jokes aside...
is it possible to just take the hv_kvm.py from the 2.5.0~rc5 tarball and
replace the current file with it?
...or just replace the GetKVMVersion method inside?
thanks
cheers,
Thomas
On 5 March 2012 12:41, Thomas Rieschl <tho...@rieschl.com> wrote:
> ok, all jokes aside...
> is it possible to just take the hv_kvm.py from the 2.5.0~rc5 tarball and
> replace the current file with it?
> ...or just replace the GetKVMVersion method inside?
>
The attached patch (assuming it doesn't get stripped off) will apply
to 2.4.5 and allow you to use qemu-kvm 1.0.
Regards,
Damien
Thanks, works like a charm now!
Regards,
Thomas
did you nano on the source and recompile kvm?
regards
beh
vladimir@xxx01:~# sudo gnt-instance startup -H kernel_path=/home/Downloads/debian-7.7.0-amd64-CD-1.iso xxx02-vm
Waiting for job 2626 for xxx02.domain.com ...
Job 2626 for xxx02.domain.com has failed: Failure: command execution error:
Could not start instance: Error while executing backend function: [Errno 18] Invalid cross-device link
vladimir@xxx01:~#