Package: mmdebstrap
Version: 1.3.1-2
Severity: normal
X-Debbugs-Cc: none, Dima Kogan <dko...@debian.org>

Hi. This is almost certainly not a bug, but I don't understand the
problem, and would like ask here. For a little while now I've been using
mmdebstrap to create bookworm tarballs. This works very nicely. As a
non-root user I would do this:

  mmdebstrap   \                                                       
    bookworm   \
    image.tar.gz \
    http://deb.debian.org/debian

Today I tried this on a different machine. It's also running Debian, but
something is different about it, because this happens:

  mmdebstrap   \                                                       
    bookworm   \
    image.tar.gz \
    http://deb.debian.org/debian

  I: automatically chosen mode: unshare
  I: chroot architecture amd64 is equal to the host's architecture
  I: finding correct signed-by value...
  done
  I: automatically chosen format: tar
  I: using /tmp/mmdebstrap.hu5TsS_2_C as tempdir
  newuidmap: write to uid_map failed: Operation not permitted
  E: newuidmap 1474581  0 60017 1 1 1476256 1 failed: 
  E: child had a non-zero exit status: 1
  E: chown failed

I'm reading the "newuidmap" manpage, but the issue isn't clear to me. In
an attempt to debug, I did this on the working machine:

  strace -f -o /tmp/stlog mmdebstrap ....

Doing that makes it fail with that error! So adding strace to a working
mmdebstrap invocation causes this error too.

If I just run the failing "newuidmap" command all by itself in the
shell, it consistently produces that error. This makes me think that
when mmdebstrap is working for me, it's somehow not actually running
newuidmap. I don't know why.

In all cases I see this:

  I: automatically chosen mode: unshare

The mmdebstrap manpage talks about this option, but it's still not clear
to me. Can you please comment? Is the above supposed to work? If so, any
idea why it would fail on some machines and not others? Does it make
sense that strace breaks it?

Thanks!

Reply via email to