debconf upgrade: xargs Assertion `bc_ctl.arg_max <= (131072-2048)' failed.

Bug #232416 reported by Grant Grundler
6
Affects Status Importance Assigned to Milestone
Ubuntu
New
Undecided
Unassigned

Bug Description

running "apt-get dist-upgrade" to upgrade from hardy to integrity, debconf.prerm script failed. I added "-x" to the debconf.prerm script and re-ran the dpkg command and it failed again the same way:

root@mb500:/var/cache/apt/archives # dpkg -i debconf_1.5.21_all.deb
(Reading database ... 135672 files and directories currently installed.)
Preparing to replace debconf 1.5.20 (using debconf_1.5.21_all.deb) ...
+ set -e
+ dpkg -L debconf
+ awk $0~/\.py$/ {print $0"c\n" $0"o"}
+ tee /dev/tty
+ xargs rm -f
xargs: xargs.c:443: main: Assertion `bc_ctl.arg_max <= (131072-2048)' failed.
Aborted
dpkg: warning - old pre-removal script returned error exit status 134
dpkg - trying script from the new package instead ...
xargs: xargs.c:443: main: Assertion `bc_ctl.arg_max <= (131072-2048)' failed.
Aborted
dpkg: error processing debconf_1.5.21_all.deb (--install):
 subprocess new pre-removal script returned error exit status 134
Errors were encountered while processing:
 debconf_1.5.21_all.deb

So xargs was hosed by something in the upgrade. NFC. I then replaced the use of xargs since it was only a few files that were to be removed:
   while read x
   do
     rm -f $x
   done

I have NFC why xargs failed and honestly don't care. debconf failing during a dist-upgrade just shouldn't be possible and not using xargs reduces the odds of that by a bit. awk b0rkage is still a bigger risk (more code than xargs I expect).

root@mb500:/var/cache/apt/archives # dpkg -i debconf_1.5.21_all.deb
(Reading database ... 135672 files and directories currently installed.)
Preparing to replace debconf 1.5.20 (using debconf_1.5.21_all.deb) ...
+ set -e
+ dpkg -L debconf
+ awk $0~/\.py$/ {print $0"c\n" $0"o"}
+ tee /dev/tty
+ read x
/usr/lib/python2.4/site-packages/debconf.pyc
/usr/lib/python2.4/site-packages/debconf.pyo
/usr/lib/python2.5/site-packages/debconf.pyc
/usr/lib/python2.5/site-packages/debconf.pyo
+ rm -f /usr/lib/python2.4/site-packages/debconf.pyc
+ read x
+ rm -f /usr/lib/python2.4/site-packages/debconf.pyo
+ read x
+ rm -f /usr/lib/python2.5/site-packages/debconf.pyc
+ read x
+ rm -f /usr/lib/python2.5/site-packages/debconf.pyo
+ read x
+ exit 0
Unpacking replacement debconf ...
Setting up debconf (1.5.21) ...

Revision history for this message
Francesc Vicent (fransex) wrote :

I can confirm this on i386.

Same issue when "aptitude safe-upgrade" from hardy to intrepid.

The xargs replacement in /var/lib/dpkg/info/debconf.prerm also worked for me.

Thanks Grant!

Revision history for this message
Andrew Pollock (apollock) wrote :

This is actually a bug in xargs. See #234345

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

you can fix this by upgrading findutils before dist-upgrading

sudo apt-get install findutils
sudo apt-get dist-upgrade

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.