Your message dated Fri, 19 Aug 2011 12:05:22 +0200 with message-id <20110819115258.GA4040@debian.org> and subject line Re: Bug#81829: "Segmentation faulty tree" (#270147) still present in Lenny, broken /var/cache/apt/*.bin available for download has caused the Debian Bug report #81829, regarding [libapt-pkg] apt-get segfaults on corrupt /var/cache/apt/*.bin to be marked as done. This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@bugs.debian.org immediately.) -- 81829: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=81829 Debian Bug Tracking System Contact owner@bugs.debian.org with problems
--- Begin Message ---
- To: submit@bugs.debian.org
- Subject: apt-get segfaults during update, upgrade etc.
- From: Guenther Harrasser <huedi@huedi.net>
- Date: Fri, 25 Oct 2002 13:08:02 +0200
- Message-id: <200210251308.02536@huedi.3node.com>
Package: apt Version: 0.5.4 I'm using linux 2.4.18, with libc6 2.2.5-15 installed. Here's the strace log for upgrade. ghexecve("/usr/bin/apt-get", ["apt-get", "upgrade"], [/* 34 vars */]) = 0 uname({sys="Linux", node="lsd", ...}) = 0 brk(0) = 0x806e2f8 old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40013000 open("/etc/ld.so.preload", O_RDONLY) = -1 ENOENT (No such file or directory) open("/etc/ld.so.cache", O_RDONLY) = 3 fstat64(3, {st_mode=S_IFREG|0644, st_size=60964, ...}) = 0 old_mmap(NULL, 60964, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40014000 close(3) = 0 open("/usr/lib/libapt-pkg-libc6.2-3-2.so.3.2", O_RDONLY) = 3 read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\220\307"..., 1024) = 1024 fstat64(3, {st_mode=S_IFREG|0644, st_size=880300, ...}) = 0 old_mmap(NULL, 883900, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x40023000 mprotect(0x400e1000, 105660, PROT_NONE) = 0 old_mmap(0x400e1000, 106496, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0xbd000) = 0x400e1000 close(3) = 0 open("/usr/lib/libstdc++-libc6.2-2.so.3", O_RDONLY) = 3 read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0P\233\1"..., 1024) = 1024 fstat64(3, {st_mode=S_IFREG|0644, st_size=288444, ...}) = 0 old_mmap(NULL, 296584, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x400fb000 mprotect(0x40131000, 75400, PROT_NONE) = 0 old_mmap(0x40131000, 69632, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x36000) = 0x40131000 old_mmap(0x40142000, 5768, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40142000 close(3) = 0 open("/lib/libm.so.6", O_RDONLY) = 3 read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\2007\0"..., 1024) = 1024 fstat64(3, {st_mode=S_IFREG|0644, st_size=129768, ...}) = 0 old_mmap(NULL, 132400, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x40144000 mprotect(0x40164000, 1328, PROT_NONE) = 0 old_mmap(0x40164000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x1f000) = 0x40164000 close(3) = 0 open("/lib/libc.so.6", O_RDONLY) = 3 read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\204\221"..., 1024) = 1024 fstat64(3, {st_mode=S_IFREG|0755, st_size=1145456, ...}) = 0 old_mmap(NULL, 1157888, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x40165000 mprotect(0x40276000, 39680, PROT_NONE) = 0 old_mmap(0x40276000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x111000) = 0x40276000 old_mmap(0x4027c000, 15104, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x4027c000 close(3) = 0 munmap(0x40014000, 60964) = 0 brk(0) = 0x806e2f8 brk(0x806e318) = 0x806e318 brk(0x806f000) = 0x806f000 open("/dev/null", O_WRONLY|O_CREAT|O_TRUNC|O_LARGEFILE, 0664) = 3 stat64("/var/lib/apt/.", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 brk(0x8070000) = 0x8070000 stat64("/etc/apt/apt.conf.d/", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 open("/dev/null", O_RDONLY|O_NONBLOCK|O_DIRECTORY) = -1 ENOTDIR (Not a directory) open("/etc/apt/apt.conf.d/", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 4 fstat64(4, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 fcntl64(4, F_SETFD, FD_CLOEXEC) = 0 brk(0x8072000) = 0x8072000 getdents64(0x4, 0x806f220, 0x1000, 0) = 80 stat64("/etc/apt/apt.conf.d/70debconf", {st_mode=S_IFREG|0644, st_size=182, ...}) = 0 getdents64(0x4, 0x806f220, 0x1000, 0) = 0 close(4) = 0 open("/etc/apt/apt.conf.d/70debconf", O_RDONLY|O_LARGEFILE) = 4 fstat64(4, {st_mode=S_IFREG|0644, st_size=182, ...}) = 0 old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000 read(4, "// Pre-configure all packages wi"..., 4096) = 182 read(4, "", 4096) = 0 close(4) = 0 munmap(0x40014000, 4096) = 0 stat64("/etc/apt/apt.conf", {st_mode=S_IFREG|0644, st_size=42, ...}) = 0 open("/etc/apt/apt.conf", O_RDONLY|O_LARGEFILE) = 4 fstat64(4, {st_mode=S_IFREG|0644, st_size=42, ...}) = 0 old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000 read(4, "Acquire::http::Proxy \"http://pro"..., 4096) = 42 read(4, "", 4096) = 0 close(4) = 0 munmap(0x40014000, 4096) = 0 stat64("/var/lib/dpkg/status", {st_mode=S_IFREG|0644, st_size=1843022, ...}) = 0 stat64("/usr/bin/dpkg", {st_mode=S_IFREG|0755, st_size=158184, ...}) = 0 stat64("/etc/debian_version", {st_mode=S_IFREG|0644, st_size=17, ...}) = 0 ioctl(1, SNDCTL_TMR_TIMEBASE, 0xbffff608) = -1 ENOTTY (Inappropriate ioctl for device) rt_sigaction(SIGPIPE, {SIG_IGN}, {SIG_DFL}, 8) = 0 rt_sigaction(SIGWINCH, {0x80632dc, [WINCH], SA_RESTART|0x4000000}, {SIG_DFL}, 8) = 0 ioctl(1, 0x5413, 0xbffff7d4) = -1 ENOTTY (Inappropriate ioctl for device) open("/var/lib/dpkg/lock", O_RDWR|O_CREAT|O_TRUNC, 0640) = 4 fcntl64(4, F_SETFD, FD_CLOEXEC) = 0 fcntl64(4, F_SETLK, {type=F_WRLCK, whence=SEEK_SET, start=0, len=0}) = 0 open("/var/lib/dpkg/updates/", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 5 fstat64(5, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0 fcntl64(5, F_SETFD, FD_CLOEXEC) = 0 getdents64(0x5, 0x806f908, 0x1000, 0x19) = 48 getdents64(0x5, 0x806f908, 0x1000, 0x19) = 0 close(5) = 0 stat64("/etc/apt/vendors.list.d/", 0xbffff47c) = -1 ENOENT (No such file or directory) stat64("/etc/apt/vendors.list", 0xbffff47c) = -1 ENOENT (No such file or directory) open("/etc/apt/sources.list", O_RDONLY|O_LARGEFILE) = 5 fstat64(5, {st_mode=S_IFREG|0644, st_size=820, ...}) = 0 old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000 read(5, "deb http://shakti.ath.cx/debian/"..., 4096) = 820 read(5, "", 4096) = 0 close(5) = 0 munmap(0x40014000, 4096) = 0 access("/var/cache/apt/", W_OK) = 0 fstat64(1, {st_mode=S_IFREG|0644, st_size=6106, ...}) = 0 old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000 write(1, "Reading Package Lists...", 24Reading Package Lists...) = 24 stat64("/var/cache/apt/pkgcache.bin", {st_mode=S_IFREG|0644, st_size=4024291, ...}) = 0 open("/var/cache/apt/pkgcache.bin", O_RDONLY) = 5 fcntl64(5, F_SETFD, FD_CLOEXEC) = 0 fstat64(5, {st_mode=S_IFREG|0644, st_size=4024291, ...}) = 0 old_mmap(NULL, 4024291, PROT_READ, MAP_SHARED, 5, 0) = 0x40280000 stat64("/var/lib/apt/lists/shakti.ath.cx_debian_kde3.1-beta2_._Packages", {st_mode=S_IFREG|0644, st_size=354706, ...}) = 0 stat64("/var/lib/apt/lists/shakti.ath.cx_debian_kde3.1-beta2_._Packages", {st_mode=S_IFREG|0644, st_size=354706, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_coda_debian_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8677, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_coda_debian_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8677, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_main_dists_unstable_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8252965, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_main_dists_unstable_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8252965, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_main_dists_unstable_contrib_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=233360, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_main_dists_unstable_contrib_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=233360, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_main_dists_unstable_non-free_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=257874, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_main_dists_unstable_non-free_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=257874, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_non-US_dists_unstable_non-US_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=98055, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_non-US_dists_unstable_non-US_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=98055, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_non-US_dists_unstable_non-US_contrib_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=1111, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_non-US_dists_unstable_non-US_contrib_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=1111, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_non-US_dists_unstable_non-US_non-free_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=7587, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_non-US_dists_unstable_non-US_non-free_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=7587, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_wine_dists_wine_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=7150, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_wine_dists_wine_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=7150, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_audio%5fvideo_dists_unstable_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=48303, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_audio%5fvideo_dists_unstable_main_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=48303, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_java_dists_woody_non-free_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8757, ...}) = 0 stat64("/var/lib/apt/lists/proxy:9999_java_dists_woody_non-free_binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8757, ...}) = 0 stat64("/var/lib/apt/lists/people.debian.org_%7eblade_testing_._Packages", {st_mode=S_IFREG|0644, st_size=23109, ...}) = 0 stat64("/var/lib/apt/lists/people.debian.org_%7eblade_testing_._Packages", {st_mode=S_IFREG|0644, st_size=23109, ...}) = 0 stat64("/var/lib/apt/lists/arachni.kiwi.uni-hamburg.de_%7eharlekin_._binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8524, ...}) = 0 stat64("/var/lib/apt/lists/arachni.kiwi.uni-hamburg.de_%7eharlekin_._binary-i386_Packages", {st_mode=S_IFREG|0644, st_size=8524, ...}) = 0 stat64("/var/lib/dpkg/status", {st_mode=S_IFREG|0644, st_size=1843022, ...}) = 0 close(5) = 0 write(1, "\n", 1 ) = 1 old_mmap(NULL, 176128, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40657000 stat64("/etc/apt/preferences", 0xbffff08c) = -1 ENOENT (No such file or directory) old_mmap(NULL, 348160, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40682000 brk(0x8083000) = 0x8083000 write(1, "Building Dependency Tree...", 27Building Dependency Tree...) = 27 --- SIGSEGV (Segmentation fault) --- +++ killed by SIGSEGV +++
--- End Message ---
--- Begin Message ---
- To: Jonathan Nieder <jrnieder@gmail.com>, 81829-done@bugs.debian.org
- Subject: Re: Bug#81829: "Segmentation faulty tree" (#270147) still present in Lenny, broken /var/cache/apt/*.bin available for download
- From: Julian Andres Klode <jak@debian.org>
- Date: Fri, 19 Aug 2011 12:05:22 +0200
- Message-id: <20110819115258.GA4040@debian.org>
- In-reply-to: <[🔎] 20110818211605.GA12840@elie.gateway.2wire.net>
- References: <20090217200846.GW5399@sym.noone.org> <[🔎] 20110818211605.GA12840@elie.gateway.2wire.net>
Source: apt Source-Version: 0.8.16~exp4 apt (0.8.16~exp4) experimental; urgency=low [ Julian Andres Klode ] * apt-pkg/pkgcache.h: - [ABI break] Add pkgCache::Header::CacheFileSize, storing the cache size * apt-pkg/pkgcachegen.cc: - Write the file size to the cache * apt-pkg/pkgcache.cc: - Check that cache is at least CacheFileSize bytes large (LP: #16467) On Thu, Aug 18, 2011 at 04:16:05PM -0500, Jonathan Nieder wrote: > tags 81829 - moreinfo > quit > > Axel Beckert wrote: > > > I occasionally ran into this bug on Lenny, can't remember on which > > platform, but never deterministically. > > > > But today I reproducibly ran into this bug with both, apt-get and > > aptitude. Independent of what I did: aptitude; aptitude -u; aptitude > > upgrade; apt-get upgrade, I always get the "Segmentation faulty > > tree... 50%" ("Building dependency tree... 50%^MSegmentation fault"). > > > > Moving /var/lib/apt/extended_states away didn't help. > > > > Couldn't even do an apt-get install gdb for generating a backtrace. > > > > Moving away pkgcache.bin and srcpkgcache.bin from /var/cache/apt/ > > finally did help (thanks to waldi for that hint), but copying them > > back after upgrading two packages didn't reproduce the segfault -- > > they always got recreated. > > Thanks! No promises about being able to take a look soon, but I've > downloaded them. I closed the Launchpad bug in 0.8.16~exp4, but forgot to close that one. We still cannot detect invalid caches where data changes, but we can now detect all truncated caches, and reject them. I could have included a CRC checksum in the header of the remaining cache, but our experience so far is that (a) most (all?) of these bugs are the result of truncated cache files (b) checksumming the cache on opening is much slower than we want, especially on ARM systems (200 ms on abel.d.o, 500 ms on an N900, 12 ms on my Intel Core i5) That said, if future shows us cases where there are problems with correctly-sized caches, we can still add a checksum when we break ABI again, and enable it by default only on amd64 and other fast architectures. -- Julian Andres Klode - Debian Developer, Ubuntu Member See http://wiki.debian.org/JulianAndresKlode and http://jak-linux.org/.Attachment: pgpUS_pqQBwMu.pgp
Description: PGP signature
--- End Message ---