[Bug 1640892] [NEW] pbuilder: remove_packages() checks for existence in host, not in chroot

Mattia Rizzolo mattia at mapreri.org
Thu Nov 10 18:26:01 UTC 2016


Public bug reported:

The fix:
https://anonscm.debian.org/git/pbuilder/pbuilder.git/commit/?id=bf1acdc

[Impact]

The remove_packages() function in pbuilder-modules contains:
    if (dpkg -s "$pkg" 2>&1)>/dev/null ; then
This obviously must
    if ($CHROOTEXEC dpkg -s "$pkg" 2>&1)>/dev/null ; then

This causes remove_packages() to try to remove packages that are not
present, actually making the function not working at all in some
circumstances, leading to crashes.

[Test Case]

 * get a sarge chroot, or anyway around that time
 * assuming you have pbuilder installed on the host and not in the chroot, run:
       pbuilder u --removepackages pbuilder

[Regression Potential]

 * for yakkety, no potential regression, this is a targetted fix.

** Affects: pbuilder (Ubuntu)
     Importance: Undecided
         Status: New

** Affects: pbuilder (Ubuntu Yakkety)
     Importance: Undecided
         Status: New

** Affects: pbuilder (Debian)
     Importance: Unknown
         Status: Unknown

** Bug watch added: Debian Bug tracker #840146
   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=840146

** Also affects: pbuilder (Debian) via
   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=840146
   Importance: Unknown
       Status: Unknown

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to pbuilder in Ubuntu.
https://bugs.launchpad.net/bugs/1640892

Title:
  pbuilder: remove_packages() checks for existence in host, not in
  chroot

Status in pbuilder package in Ubuntu:
  New
Status in pbuilder source package in Yakkety:
  New
Status in pbuilder package in Debian:
  Unknown

Bug description:
  The fix:
  https://anonscm.debian.org/git/pbuilder/pbuilder.git/commit/?id=bf1acdc

  [Impact]

  The remove_packages() function in pbuilder-modules contains:
      if (dpkg -s "$pkg" 2>&1)>/dev/null ; then
  This obviously must
      if ($CHROOTEXEC dpkg -s "$pkg" 2>&1)>/dev/null ; then

  This causes remove_packages() to try to remove packages that are not
  present, actually making the function not working at all in some
  circumstances, leading to crashes.

  [Test Case]

   * get a sarge chroot, or anyway around that time
   * assuming you have pbuilder installed on the host and not in the chroot, run:
         pbuilder u --removepackages pbuilder

  [Regression Potential]

   * for yakkety, no potential regression, this is a targetted fix.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/pbuilder/+bug/1640892/+subscriptions



More information about the foundations-bugs mailing list