[Whonix-devel] Bug#932552: empty /var/lib/dpkg/available causing pbuilder to fail

Patrick Schleizer adrelanos at riseup.net
Sat Jul 20 16:56:00 CEST 2019


Package: mmdebstrap
Severity: normal
X-Debbugs-CC: whonix-devel at whonix.org

Dear maintainer,

I am using mmdebstrap in combination with cowbuilder / pbuilder.

Initially a chroot created using mmdebstrap comes with an empty file
/var/lib/dpkg/available.

This confuses aptitude which I wouldn't care much about but pbuilder
uses aptitude internally.

++ chroot /var/cache/pbuilder/cow.cow_amd64/cow.14818 cow-shell env
XDG_CACHE_HOME=/root aptitude -y --without-recommends -o
APT::Install-Recommends=false -o
Aptitude::ProblemResolver::StepScore=100 -o
'Aptitude::ProblemResolver::Hints::KeepDummy=reject
pbuilder-satisfydepends-dummy :UNINST' -o
Aptitude::ProblemResolver::Keep-All-Level=55000 -o
Aptitude::ProblemResolver::Remove-Essential-Level=maximum install
pbuilder-satisfydepends-dummy
[ ERR] Writing extended state information
[ ERR] Building tag database

At the same time generating /var/lib/dpkg/available is not obvious
anymore in Debian buster. In Debian stretch one could use "dpkg
--clear-avail" followed by "apt-get update" but that does no longer work
in Debian buster.

Solution was found. (Credits [1].)

/usr/lib/dpkg/methods/apt/update /var/lib/dpkg apt apt

However, it would be nice if mmdebstrap could come with a functional
/var/lib/dpkg/available file so mmdebstrap can be used in combination
with cowbuilder / pbuilder.

Kind regards,
Patrick

[1] Thanks to Chris Gibson
https://unix.stackexchange.com/users/162231/chris-gibson
https://unix.stackexchange.com/a/271387/49297


More information about the Whonix-devel mailing list