Your message dated Mon, 30 May 2011 21:44:01 +0100
with message-id <[email protected]>
and subject line Re: [buildd-tools-devel] Bug#477936: [Buildd-tools-devel]
Bug#477936: does not clean up sessions when interrupted
has caused the Debian Bug report #477936,
regarding does not clean up sessions when interrupted
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
477936: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=477936
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: sbuild
Version: 0.57.0-1
Severity: normal
If an sbuild gets interrupted, the session is not ended as no
signals are trapped. sbuild should ensure that it cleans up any
schroot sessions on exit, if it can in any way (as is the case for
SIGINT).
-- System Information:
Debian Release: lenny/sid
APT prefers unstable
APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable'), (1,
'experimental')
Architecture: i386 (i686)
Kernel: Linux 2.6.24-1+scoflowctrl.1-686 (SMP w/1 CPU core)
Locale: LANG=en_GB, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages sbuild depends on:
ii adduser 3.107 add and remove users and groups
ii apt 0.7.11 Advanced front-end for dpkg
ii dctrl-tools 2.12 Command-line tools to process Debi
ii dpkg-dev 1.14.18 package building tools for Debian
ii perl 5.8.8-12 Larry Wall's Practical Extraction
ii perl-modules 5.8.8-12 Core Perl modules
ii postfix [mail-transport-agen 2.5.2~rc2-1 High-performance mail transport ag
ii schroot 1.1.6-1 Execute commands in a chroot envir
Versions of packages sbuild recommends:
ii debootstrap 1.0.8 Bootstrap a basic Debian system
ii fakeroot 1.9.4 Gives a fake root environment
-- no debconf information
--
.''`. martin f. krafft <[email protected]>
: :' : proud Debian developer, author, administrator, and user
`. `'` http://people.debian.org/~madduck - http://debiansystem.info
`- Debian - when you have better things to do than fixing systems
digital_signature_gpg.asc
Description: Digital signature (see http://martin-krafft.net/gpg/)
--- End Message ---
--- Begin Message ---
Version: 0.62.0-1
On Sun, Oct 31, 2010 at 10:19:23PM +0000, Roger Leigh wrote:
> On Fri, Apr 25, 2008 at 07:26:48PM +0400, martin f krafft wrote:
> > If an sbuild gets interrupted, the session is not ended as no
> > signals are trapped. sbuild should ensure that it cleans up any
> > schroot sessions on exit, if it can in any way (as is the case for
> > SIGINT).
>
> The current sbuild (0.60.0/0.60.1) will end the session associated
> with the current job, so from this POV the bug is now fixed. It
> also rm -rf's the build directory.
>
> Now, while the bug (as reported) is not present in current sbuild's
> it's open to debate whether the current signal handling is
> adequate. While we clean up the build dir and end the session,
> we don't make /any/ attempt to leave the build chroot in a
> consistent state. We don't remove the build dependencies, and
> we don't do any other cleanup, e.g. srcdep-lock removal.
>
> If using snapshot-based schroot chroots, this is a non-issue:
> the cleanup occured when the session ended. For other types,
> manual cleanup with e.g. debfoster is needed. The chroot could
> be broken if interrupting at other critical moments, e.g.
> when running apt-get/dpkg.
>
> So the question is: if the user requested termination, do we
> terminate immediately, or do we do the cleanup necessary to
> leave everything ready for a new build? The cleanup could be
> expensive and take a long time, especially on slow systems
> where this might be part of the shutdown process.
>
> In the common case of terminating during a build, I think we
> cope fairly well, bar not removing the build-deps. At other
> points, termination is not a good plan.
This bug was fixed completely in 0.62.0-1. This version introduced
proper exception handling into the Sbuild::Build class and the
sbuild program itself. This means that rather than aborting early
and avoiding session cleanup, all failures are inside eval blocks
which means cleanup occurs for all failure scenarios. This includes
all signal handling, which now simply requests an abort; this
consequently kills the build and causes an exception to throw, thus
triggering the same cleanup paths as for any other error.
Note that there is a separate bug (in LVM) which prevents lvremove
from completing in (somewhat mysterious) circumstances. It's
likely an LVM locking bug. This can't be fixed or worked around
in sbuild though. From the point of view of sbuild, we're now
about as robust as possible in cleaning up following an error.
Regards,
Roger
--
.''`. Roger Leigh
: :' : Debian GNU/Linux http://people.debian.org/~rleigh/
`. `' Printing on GNU/Linux? http://gutenprint.sourceforge.net/
`- GPG Public Key: 0x25BFB848 Please GPG sign your mail.
signature.asc
Description: Digital signature
--- End Message ---