[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#694127: apt-utils: apt-extracttemplates is confused when RootDir is set



Hi David,
I've given it a try on wheezy (apt 0.9.7.6).
I suppose, the new apt-get chroots into the new env before apt-extracttemplates is executed, right? Setting just RootDir made apt-extracttemplates complain about missing APT_CONFIG configuration - which is obvious as it was stored in the parent environment. (APT_CONFIG points to my temporary configuration file which is stored in /tmp. It contains the necessary tweaks and is not part of usual configuration.) However, it passed. And then chroot was done (probably once again) before /usr/bin/dpkg. And there is failed with status 100.

Setting RootDir along with Dpkg::Chroot-directory makes no good. It makes apt-get chroot into RootDir/chroot-directory (like /tmp/altroot/tmp/altroot). Needless to say that /usr/bin/apt-listchanges could have not been started from there and failed with status 100.

With the recent dpkg::chroot-directory changes you probably mean bug# 659387. I saw that but I don't think it applies to this case.

Best regards,
Milan Cermak

Dne 25.11.2012 14:07, David Kalnischkies napsal(a):
On Sat, Nov 24, 2012 at 9:23 AM, Milan Cermak<mcermak@chello.cz>  wrote:
It suggests, that apt-extracttemplates (and maybe other components) does not
honor RootDir option. The packages were downloaded to the chroot'd environment,
but apt-extracttemplated looked them up in the primary environment.

We will need to check if this applies to APT/wheezy and/or APT/unstable.

It could be that rev 1561.1.206 solves this:

apt (0.8.12) unstable; urgency=low
…
   * apt-pkg/contrib/fileutl.cc, apt-pkg/deb/dpkgpm.cc:
     - honor Dpkg::Chroot-Directory in the RunScripts*() methods
…
  -- Michael Vogt<mvo@debian.org>   Thu, 10 Mar 2011 14:46:48 +0100

as apt-extracttemplate is not directly executed from APT.


I was able to workaround this with setting:
Dpkg::Chroot-Directory "/tmp/mychroot";

in the APT_CONFIG file. However, this caused dpkg to be chrooted to /tmp/mychroot/tmp/mychroot,
which obviously does not exist.

I remember that we had some changes in that area as well, I just can't
seem to find them just yet.


Would be nice if you could test this in wheezy as I never used these options
myself so far so I don't know the "usecase" to properly test it.


Best regards

David Kalnischkies


Reply to: