[Buildbot-commits] [Buildbot] #1843: LibVirtSlave fails to destroy domain on buildFinished
Buildbot
nobody at buildbot.net
Mon Feb 28 18:40:59 UTC 2011
#1843: LibVirtSlave fails to destroy domain on buildFinished
--------------------+-----------------------
Reporter: fr4nk | Owner:
Type: defect | Status: new
Priority: major | Milestone: undecided
Version: 0.8.3p1 | Keywords:
--------------------+-----------------------
[root at eridu ~]# libvirtd --version
'''libvirtd (libvirt) 0.8.8'''
[root at eridu ~]# qemu-kvm --version
QEMU emulator version 0.14.0 '''(qemu-kvm-0.14.0)''', Copyright (c)
2003-2008 Fabrice Bellard
[root at eridu ~]#
master.cfg snippet:
{{{
from buildbot.libvirtbuildslave import LibVirtSlave
from buildbot.libvirtbuildslave import Connection
connection = Connection("qemu:///system")
c['slaves'] = []
[...]
slave = LibVirtSlave("arch32", "<password>", connection,
"/data/vms/snapshots/arch32.tmp", base_image="/data/vms/arch32.img",
max_builds=1, missing_timeout=30, build_wait_timeout=30)
c['slaves'].append(slave)
}}}
A builder associated with this slave will cause the (qemu-kvm) virtual
machine to start, from a snapshot overlay disk, just fine. The buildslave
on the VM starts, connects, the build starts, and finishes, or fails..
this is not the issue here..
The problem is that after the build, it doesn't manage to stop/destroy the
VM, leaving it running. Apart from taking up memory, this also de-syncs
the states between libvirt and buildbot, so that you can't start the build
again.
below is a stacktrace from a manually interrupted build (but the last line
is the same regardless of how the build terminates:
{{{
2011-02-26 16:33:56+0100 [-] setting expectations for next time
2011-02-26 16:33:56+0100 [-] new expectations: 367.477597952 seconds
2011-02-26 16:33:56+0100 [-] Got buildFinished notification - attempting
to insubstantiate
2011-02-26 16:33:56+0100 [-] Attempting to stop 'arch32'
2011-02-26 16:33:56+0100 [-] Unhandled Error
Traceback (most recent call last):
File
"/usr/lib/python2.7/site-packages/buildbot/process/base.py", line 478,
in allStepsDone
return self.buildFinished(text, self.result)
File
"/usr/lib/python2.7/site-packages/buildbot/process/base.py", line 511,
in buildFinished
self.deferred.callback(self)
File
"/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 361,
in callback
self._startRunCallbacks(result)
File
"/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 455,
in _startRunCallbacks
self._runCallbacks()
--- <exception caught here> ---
File
"/usr/lib/python2.7/site-packages/twisted/internet/defer.py", line 542,
in _runCallbacks
current.result = callback(current.result, *args, **kw)
File
"/usr/lib/python2.7/site-packages/buildbot/process/base.py", line 225,
in _release_slave
self.slavebuilder.buildFinished()
File
"/usr/lib/python2.7/site-packages/buildbot/process/builder.py", line
317, in buildFinished
self.slave.buildFinished(self)
File
"/usr/lib/python2.7/site-packages/buildbot/libvirtbuildslave.py", line
264, in buildFinished
self.insubstantiate()
File
"/usr/lib/python2.7/site-packages/buildbot/buildslave.py", line 715, in
insubstantiate
d = self.stop_instance(fast)
File
"/usr/lib/python2.7/site-packages/buildbot/libvirtbuildslave.py", line
239, in stop_instance
d = domain.destroy()
exceptions.AttributeError: 'int' object has no attribute 'destroy'
}}}
--
Ticket URL: <http://trac.buildbot.net/ticket/1843>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation
More information about the Commits
mailing list