Bug#674147: apt: LANG=C apt-cache policy is very slow
Hi, On Wed, 23 May 2012, David Kalnischkies wrote: [...] I think it is this fixed-in-unstable issue: apt (0.9.4) unstable; urgency=low […] * apt-pkg/aptconfiguration.cc: - longcode Translation files are saved with encoded underscore, so make sure to pick these files up as well for Acquire::Languages […] -- Michael Vogt m...@debian.org Mon, 21 May 2012 12:29:05 +0200 Can you test this (or: better 0.9.5) version from unstable maybe? (you need to upgrade the libapt-pkg4.12 package) I tested apt-cage from the 0.9.5 apt package and indeed that fixes the speed issue. So this bug can be closed. Thanks! -- Francois Gouget fgou...@free.fr http://fgouget.free.fr/ Demander si un ordinateur peut penser revient à demander si un sous-marin peut nager.
Bug#674147: apt: LANG=C apt-cache policy is very slow
Package: apt Version: 0.9.3 Severity: normal Dear Maintainer, Here is how to reproduce the problem: $ LANG=C time apt-cache policy /dev/null 1.76user 0.05system 0:01.82elapsed 99%CPU (0avgtext+0avgdata 137200maxresident)k 0inputs+0outputs (0major+11677minor)pagefaults 0swaps $ LANG=fr_FR.UTF8 time apt-cache policy /dev/null 0.03user 0.00system 0:00.04elapsed 86%CPU (0avgtext+0avgdata 63584maxresident)k 0inputs+0outputs (0major+5982minor)pagefaults 0swaps This makes lsb_release very slow because it runs apt-cache with LANG=C, which in turn makes vmrun, a VMware tool, very slow. Now the reason for the speed difference between the C and fr_FR.UTF8 cases is that on my system 'apt-cache gencaches' is being run in the French locale and that only one cache is kept. Ideally apt-cache policy should be fast in both the 'machine querying' mode that's normally done in the C locale, and in the 'main user' locale. Though if lsb_release should handle things differently that could fix things too. -- Package-specific info: -- apt-config dump -- APT ; APT::Architecture amd64; APT::Build-Essential ; APT::Build-Essential:: build-essential; APT::Install-Recommends 1; APT::Install-Suggests 0; APT::Authentication ; APT::Authentication::TrustCDROM true; APT::NeverAutoRemove ; APT::NeverAutoRemove:: ^firmware-linux.*; APT::NeverAutoRemove:: ^linux-firmware$; APT::NeverAutoRemove:: ^linux-image.*; APT::NeverAutoRemove:: ^kfreebsd-image.*; APT::NeverAutoRemove:: ^linux-restricted-modules.*; APT::NeverAutoRemove:: ^linux-ubuntu-modules-.*; APT::NeverAutoRemove:: ^gnumach$; APT::NeverAutoRemove:: ^gnumach-image.*; APT::Never-MarkAuto-Sections ; APT::Never-MarkAuto-Sections:: metapackages; APT::Never-MarkAuto-Sections:: restricted/metapackages; APT::Never-MarkAuto-Sections:: universe/metapackages; APT::Never-MarkAuto-Sections:: multiverse/metapackages; APT::Never-MarkAuto-Sections:: oldlibs; APT::Never-MarkAuto-Sections:: restricted/oldlibs; APT::Never-MarkAuto-Sections:: universe/oldlibs; APT::Never-MarkAuto-Sections:: multiverse/oldlibs; APT::Periodic ; APT::Periodic::Update-Package-Lists 1; APT::Periodic::Download-Upgradeable-Packages 0; APT::Periodic::AutocleanInterval 0; APT::Update ; APT::Update::Post-Invoke ; APT::Update::Post-Invoke:: touch /var/lib/apt/periodic/update-success-stamp 2/dev/null || true; APT::Update::Post-Invoke-Success ; APT::Update::Post-Invoke-Success:: [ ! -f /var/run/dbus/system_bus_socket ] || /usr/bin/dbus-send --system --dest=org.debian.apt --type=signal /org/debian/apt org.debian.apt.CacheChanged || true; APT::Archives ; APT::Archives::MaxAge 30; APT::Archives::MinAge 2; APT::Archives::MaxSize 500; APT::Architectures ; APT::Architectures:: amd64; APT::Compressor ; APT::Compressor::. ; APT::Compressor::.::Name .; APT::Compressor::.::Extension ; APT::Compressor::.::Binary ; APT::Compressor::.::Cost 1; APT::Compressor::gzip ; APT::Compressor::gzip::Name gzip; APT::Compressor::gzip::Extension .gz; APT::Compressor::gzip::Binary gzip; APT::Compressor::gzip::Cost 2; APT::Compressor::gzip::CompressArg ; APT::Compressor::gzip::CompressArg:: -9n; APT::Compressor::gzip::UncompressArg ; APT::Compressor::gzip::UncompressArg:: -d; APT::Compressor::bzip2 ; APT::Compressor::bzip2::Name bzip2; APT::Compressor::bzip2::Extension .bz2; APT::Compressor::bzip2::Binary bzip2; APT::Compressor::bzip2::Cost 3; APT::Compressor::bzip2::CompressArg ; APT::Compressor::bzip2::CompressArg:: -9; APT::Compressor::bzip2::UncompressArg ; APT::Compressor::bzip2::UncompressArg:: -d; APT::Compressor::xz ; APT::Compressor::xz::Name xz; APT::Compressor::xz::Extension .xz; APT::Compressor::xz::Binary xz; APT::Compressor::xz::Cost 4; APT::Compressor::xz::CompressArg ; APT::Compressor::xz::CompressArg:: -6; APT::Compressor::xz::UncompressArg ; APT::Compressor::xz::UncompressArg:: -d; APT::Compressor::lzma ; APT::Compressor::lzma::Name lzma; APT::Compressor::lzma::Extension .lzma; APT::Compressor::lzma::Binary xz; APT::Compressor::lzma::Cost 5; APT::Compressor::lzma::CompressArg ; APT::Compressor::lzma::CompressArg:: --format=lzma; APT::Compressor::lzma::CompressArg:: -9; APT::Compressor::lzma::UncompressArg ; APT::Compressor::lzma::UncompressArg:: --format=lzma; APT::Compressor::lzma::UncompressArg:: -d; APT::CompressorName ; APT::CompressorExtension .; APT::CompressorBinary ; APT::CompressorCost 100; APT::CompressorCompressArg ; APT::CompressorCompressArg:: -9; APT::CompressorUncompressArg ; APT::CompressorUncompressArg:: -d; Dir /; Dir::State var/lib/apt/; Dir::State::lists lists/; Dir::State::cdroms cdroms.list; Dir::State::mirrors mirrors/; Dir::State::extended_states extended_states; 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;
Bug#674147: apt: LANG=C apt-cache policy is very slow
On Wed, May 23, 2012 at 1:15 PM, Francois Gouget fgou...@free.fr wrote: Here is how to reproduce the problem: $ LANG=C time apt-cache policy /dev/null 1.76user 0.05system 0:01.82elapsed 99%CPU (0avgtext+0avgdata 137200maxresident)k 0inputs+0outputs (0major+11677minor)pagefaults 0swaps $ LANG=fr_FR.UTF8 time apt-cache policy /dev/null 0.03user 0.00system 0:00.04elapsed 86%CPU (0avgtext+0avgdata 63584maxresident)k 0inputs+0outputs (0major+5982minor)pagefaults 0swaps This makes lsb_release very slow because it runs apt-cache with LANG=C, which in turn makes vmrun, a VMware tool, very slow. Thanks for your report! I think it is this fixed-in-unstable issue: apt (0.9.4) unstable; urgency=low […] * apt-pkg/aptconfiguration.cc: - longcode Translation files are saved with encoded underscore, so make sure to pick these files up as well for Acquire::Languages […] -- Michael Vogt m...@debian.org Mon, 21 May 2012 12:29:05 +0200 Can you test this (or: better 0.9.5) version from unstable maybe? (you need to upgrade the libapt-pkg4.12 package) Otherwise the output of the two commands with the debug option -o Debug::pkgCacheGen=1 could be helpful to know which file isn't picked up, as in theory what you suggested is already in action. Best regards David Kalnischkies -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org