[buildd-tools-devel] Bug#630658: Bug#630658: sbuild-createchroot succfails badly with invalid user

Roger Leigh rleigh at codelibre.net
Thu Jun 16 10:35:45 UTC 2011


On Thu, Jun 16, 2011 at 02:21:03AM +0200, Cyril Brulebois wrote:
> So, having faith, I purged sbuild and schroot entirely (yay for the
> failing delgroup call, by the way, and a different error than #619892 --
> sbuild being the last remaining group for the sbuild user or something
> similar), trying to start afresh and without any prejudices.

And the error was...?

> Now, even creating a chroot fails, or succeeds, depending on which line
> one reads:
> | [config file excerpt]
> | I: Please rename and modify this file as required.
> | mkdir /etc/sbuild/chroot
> | I: sudo chroot configuration linked as
> | /etc/sbuild/chroot/sid-amd64-sbuild.
> | chown: invalid user: `sbuild:sbuild'
> | E: Failed to set sbuild:sbuild ownership on /build
> | Failed to set up chroot
> | E: Error creating chroot session: skipping apt update
> | I: Successfully set up sid chroot.
> | I: Run "sbuild-adduser" to add new sbuild users.
> 
> Looks like yet another proof of sbuild's extreme fragility. :(

Some setup tasks inside the chroot failed; the actual chroot was
created just fine.

This is due to running Sbuild::ChrootSetup::basesetup() after
bootstrapping the chroot.  This is called by sbuild at the
start of each build, so the stuff that failed here will be
sorted out on the first use.

The reason for the failure is a chicken-and-egg problem WRT the
existence of the sbuild user/group inside the chroot.  This is
set up by schroot's nssdatabases setup script, but we aren't
in a position to run schroot at this point.  The new sbuild
version works around this by manually copying the sbuild user
and group into the chroot before running basesetup().

Please let me know if you still have any issues.  It's working
correctly for me.

> -- Configuration Files:
> /etc/schroot/buildd/config changed [not included]
> /etc/schroot/buildd/copyfiles changed [not included]
> /etc/schroot/buildd/fstab changed [not included]
> /etc/schroot/buildd/nssdatabases changed [not included]
> 
> ^^^^^
> Also, lies. I never touched those files.

They were adopted by schroot, which provided its own
(functionally equivalent) versions.  This is mentioned in
the schroot and (new) sbuild changelogs.


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.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/buildd-tools-devel/attachments/20110616/009f4083/attachment-0001.pgp>


More information about the Buildd-tools-devel mailing list