Now that apt stores information about automatic installation status of
packages in its own file in /var/lib/apt/extended_states, backups should
be taken of this file the same as is done for /var/lib/dpkg/status and
/var/lib/aptitude/pkgstates.
Strangely, /etc/cron.daily/apt does backups of /var/cache/apt and *not*
of /var/lib/apt, even though all information in /var/cache is supposed to
be recoverable if deleted!
-- Package-specific info:
-- apt-config dump --
APT "";
APT::Architecture "armel";
APT::Build-Essential "";
APT::Build-Essential:: "build-essential";
APT::Install-Recommends "1";
APT::Install-Suggests "0";
APT::Acquire "";
APT::Acquire::Translation "environment";
APT::Authentication "";
APT::Authentication::TrustCDROM "true";
APT::NeverAutoRemove "";
APT::NeverAutoRemove:: "^linux-image.*";
APT::NeverAutoRemove:: "^linux-restricted-modules.*";
Dir "/";
Dir::State "var/lib/apt/";
Dir::State::lists "lists/";
Dir::State::cdroms "cdroms.list";
Dir::State::userstatus "status.user";
Dir::State::status "/var/lib/dpkg/status";
Dir::Cache "var/cache/apt/";
Dir::Cache::archives "archives/";
Dir::Cache::srcpkgcache "srcpkgcache.bin";
Dir::Cache::pkgcache "pkgcache.bin";
Dir::Etc "etc/apt/";
Dir::Etc::sourcelist "sources.list";
Dir::Etc::sourceparts "sources.list.d";
Dir::Etc::vendorlist "vendors.list";
Dir::Etc::vendorparts "vendors.list.d";
Dir::Etc::main "apt.conf";
Dir::Etc::parts "apt.conf.d";
Dir::Etc::preferences "preferences";
Dir::Etc::preferencesparts "preferences.d";
Dir::Bin "";
Dir::Bin::methods "/usr/lib/apt/methods";
Dir::Bin::dpkg "/usr/bin/dpkg";
Dir::Log "var/log/apt";
Dir::Log::Terminal "term.log";
DPkg "";
DPkg::Pre-Install-Pkgs "";
DPkg::Pre-Install-Pkgs:: "/usr/sbin/dpkg-preconfigure --apt || true";
-- (no /etc/apt/preferences present) --
-- (/etc/apt/sources.list present, but not submitted) --
-- System Information:
Debian Release: squeeze/sid
APT prefers testing
APT policy: (500, 'testing'), (500, 'stable')
Architecture: armel (armv5tel)
Kernel: Linux 2.6.30-1-iop32x
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages apt depends on:
ii debian-archive-keyring 2009.01.31 GnuPG archive keys of the Debian a
ii libc6 2.11.2-2 Embedded GNU C Library: Shared lib
ii libgcc1 1:4.4.1-1 GCC support library
ii libstdc++6 4.4.1-1 The GNU Standard C++ Library v3
apt recommends no packages.
Versions of packages apt suggests:
pn apt-doc <none> (no description available)
ii aptitude 0.4.11.11-1+b4 terminal-based package manager
ii bzip2 1.0.5-3 high-quality block-sorting file co
ii dpkg-dev 1.15.3.1 Debian package development tools
ii lzma 4.43-14 Compression method of 7z format in
ii python-apt 0.7.96.1 Python interface to libapt-pkg
-- no debconf information
--
To UNSUBSCRIBE, email to debian-bugs-...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org
2010/8/18 Steve Langasek <vor...@debian.org>:
> Now that apt stores information about automatic installation status of
> packages in its own file in /var/lib/apt/extended_states, backups should
> be taken of this file the same as is done for /var/lib/dpkg/status and
> /var/lib/aptitude/pkgstates.
"Now"… :)
(hint: included since APT 0.6.44.2exp1 released on 3 Jul 2006.)
SCNR
>>>>>>>
--- debian/apt.cron.daily 2010-06-09 09:51:21 +0000
+++ debian/apt.cron.daily 2010-08-18 09:05:10 +0000
@@ -320,6 +320,15 @@
# ------------------------ main ----------------------------
+# Backup the 7 last versions of APT's extended_states file
+# shameless copy from dpkg cron
+if cd /var/backups ; then
+ if ! cmp -s apt.extended_states.0 /var/lib/apt/extended_states; then
+ cp -p /var/lib/apt/extended_states apt.extended_states
+ savelog -c 7 apt.extended_states >/dev/null
+ fi
+fi
+
# check apt-config exstance
if ! which apt-config >/dev/null ; then
exit 0
<<<<<<<
That is all we need, right?
> Strangely, /etc/cron.daily/apt does backups of /var/cache/apt and *not*
> of /var/lib/apt, even though all information in /var/cache is supposed to
> be recoverable if deleted!
As far as i know it is the content of /var/cache/apt/archives which can
be backup and which is not always recoverable, even if you have an
internet connection. Its easier now with snapshot.debian.net to recover
the content coming from the official archive for any given time, but other
more or less official archives aren't tracked by it (volatile,
security, backports)
and historical thirdparty stuff isn't always available either…
Best regards,
David Kalnischkies
> 2010/8/18 Steve Langasek <vor...@debian.org>:
> > Now that apt stores information about automatic installation status of
> > packages in its own file in /var/lib/apt/extended_states, backups should
> > be taken of this file the same as is done for /var/lib/dpkg/status and
> > /var/lib/aptitude/pkgstates.
> "Now"… :)
> (hint: included since APT 0.6.44.2exp1 released on 3 Jul 2006.)
> SCNR
This bug report was prompted by a review of the release notes, which have a
multi-year development cycle. :)
> >>>>>>>
> --- debian/apt.cron.daily 2010-06-09 09:51:21 +0000
> +++ debian/apt.cron.daily 2010-08-18 09:05:10 +0000
> @@ -320,6 +320,15 @@
>
> # ------------------------ main ----------------------------
>
> +# Backup the 7 last versions of APT's extended_states file
> +# shameless copy from dpkg cron
> +if cd /var/backups ; then
> + if ! cmp -s apt.extended_states.0 /var/lib/apt/extended_states; then
> + cp -p /var/lib/apt/extended_states apt.extended_states
> + savelog -c 7 apt.extended_states >/dev/null
> + fi
> +fi
> +
> # check apt-config exstance
> if ! which apt-config >/dev/null ; then
> exit 0
>
> <<<<<<<
> That is all we need, right?
Yes, A shameless copy from dpkg cron should do the job. :-)
> > Strangely, /etc/cron.daily/apt does backups of /var/cache/apt and *not*
> > of /var/lib/apt, even though all information in /var/cache is supposed to
> > be recoverable if deleted!
> As far as i know it is the content of /var/cache/apt/archives which can
> be backup and which is not always recoverable, even if you have an
> internet connection. Its easier now with snapshot.debian.net to recover
> the content coming from the official archive for any given time, but other
> more or less official archives aren't tracked by it (volatile,
> security, backports)
> and historical thirdparty stuff isn't always available either…
Yes, but I don't think it makes sense for apt to be providing the backups of
this; but well, as long as it's disabled by default, I guess it doesn't do
any harm.
--
Steve Langasek Give me a lever long enough and a Free OS
Debian Developer to set it on, and I can move the world.
Ubuntu Developer http://www.debian.org/
slan...@ubuntu.com vor...@debian.org