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

Bug#315612: apt-utils: apt-ftparchive hangs during initial generation



Package: apt-utils
Version: 0.5.28.6
Severity: important

When I run 'apt-ftparchive generate apt-ftparchive.config' for the first time,
it walks through some of my archive and eventually hangs.  I suspect it's a
race condition--this is on a two-way ia64 machine.  I have included the
relevant gdb backtraces of gzip and apt-ftparchive.


*** gdb-backtraces
Relevant output from pstree:

sshd---bash---update-archive---apt-ftparchive---apt-ftparchive
                                              |-gzip

-----------------------------------------------------------------------

jswright@ftp-linux:~$ ps -u jswright|grep apt-ftparchive
 2108 pts/7    00:00:09 apt-ftparchive
 2133 pts/7    00:00:00 apt-ftparchive
jswright@ftp-linux:~$ gdb /usr/bin/apt-ftparchive 2108
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "ia64-linux"...Using host libthread_db library "/lib/tls/libthread_db.so.1".

Attaching to program: /usr/bin/apt-ftparchive, process 2108
Reading symbols from /usr/lib/libapt-pkg-libc6.3-5.so.3.3...done.
Loaded symbols for /usr/lib/libapt-pkg-libc6.3-5.so.3.3
Reading symbols from /usr/lib/libapt-inst-libc6.3-5.so.1.0...done.
Loaded symbols for /usr/lib/libapt-inst-libc6.3-5.so.1.0
Reading symbols from /usr/lib/libdb-4.2.so...done.
Loaded symbols for /usr/lib/libdb-4.2.so
Reading symbols from /usr/lib/libstdc++.so.5...done.
Loaded symbols for /usr/lib/libstdc++.so.5
Reading symbols from /lib/libunwind.so.7...done.
Loaded symbols for /lib/libunwind.so.7
Reading symbols from /lib/tls/libm.so.6.1...done.
Loaded symbols for /lib/tls/libm.so.6.1
Reading symbols from /lib/libgcc_s.so.1...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/libc.so.6.1...done.
Loaded symbols for /lib/tls/libc.so.6.1
Reading symbols from /lib/ld-linux-ia64.so.2...done.
Loaded symbols for /lib/ld-linux-ia64.so.2
0x2000000000742841 in waitpid () from /lib/tls/libc.so.6.1
(gdb) bt
#0  0x2000000000742841 in waitpid () from /lib/tls/libc.so.6.1
#1  0x2000000000099ba0 in ExecWait () from /usr/lib/libapt-pkg-libc6.3-5.so.3.3
#2  0x200000000018dfd0 in ExtractTar::Done (this=0xc99, Force=true) at basic_string.h:355
#3  0x200000000018fdb0 in ExtractTar::Go (this=0x60000fffffff9eb0,
    Stream=@0x60000fffffffaf88) at contrib/extracttar.cc:157
#4  0x40000000000719b0 in ContentsExtract::Read (this=0x60000fffffffaf88,
    Deb=@0x600000000000d200) at contents.cc:316
#5  0x4000000000040ed0 in CacheDB::LoadContents (this=0x60000fffffffa7e0, GenOnly=true)
    at cachedb.cc:168
#6  0x400000000004d890 in PackagesWriter::DoPackage (this=0x60000fffffffa780, FileName=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<No data fields>}, _M_p = 0x60000000000330b8 "./pool/main/x/xfree86/libxaw6_4.1.0-16woody3_ia64.deb"}, static _S_empty_rep_storage = {0, 0, 1687, 0}}) at writer.cc:349
#7  0x4000000000044ff0 in FTWScanner::Scanner (
    File=0x60000fffffffa2c0 "./pool/main/x/xfree86/libxaw6_4.1.0-16woody3_ia64.deb",
    sb=0x60000fffffffa6b0, Flag=216512) at writer.cc:75
#8  0x4000000000045f70 in FTWScanner::LoadFileList (this=0x60000fffffffa2c2, Dir=Cannot access memory at address 0x2
)
    at writer.cc:218
#9  0x4000000000009940 in PackageMap::GenPackages (this=0x600000000002c320,
    Setup=@0x60000000000077c8, Stats=@0x60000fffffffb130) at apt-ftparchive.cc:191
#10 0x4000000000030f50 in Generate (CmdL=@0x60000fffffffb5e0) at stl_iterator.h:605
#11 0x200000000008eb90 in CommandLine::DispatchArg ()
   from /usr/lib/libapt-pkg-libc6.3-5.so.3.3
#12 0x40000000000359a0 in main (argc=30560, argv=0x60000000000077d0)
    at apt-ftparchive.cc:898

-----------------------------------------------------------------------

jswright@ftp-linux:~$ gdb /usr/bin/apt-ftparchive 2133
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "ia64-linux"...Using host libthread_db library "/lib/tls/libthread_db.so.1".

Attaching to program: /usr/bin/apt-ftparchive, process 2133
Reading symbols from /usr/lib/libapt-pkg-libc6.3-5.so.3.3...done.
Loaded symbols for /usr/lib/libapt-pkg-libc6.3-5.so.3.3
Reading symbols from /usr/lib/libapt-inst-libc6.3-5.so.1.0...done.
Loaded symbols for /usr/lib/libapt-inst-libc6.3-5.so.1.0
Reading symbols from /usr/lib/libdb-4.2.so...done.
Loaded symbols for /usr/lib/libdb-4.2.so
Reading symbols from /usr/lib/libstdc++.so.5...done.
Loaded symbols for /usr/lib/libstdc++.so.5
Reading symbols from /lib/libunwind.so.7...done.
Loaded symbols for /lib/libunwind.so.7
Reading symbols from /lib/tls/libm.so.6.1...done.
Loaded symbols for /lib/tls/libm.so.6.1
Reading symbols from /lib/libgcc_s.so.1...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/libc.so.6.1...done.
Loaded symbols for /lib/tls/libc.so.6.1
Reading symbols from /lib/ld-linux-ia64.so.2...done.
Loaded symbols for /lib/ld-linux-ia64.so.2
0x2000000000788e61 in select () from /lib/tls/libc.so.6.1
(gdb) bt
#0  0x2000000000788e61 in select () from /lib/tls/libc.so.6.1
#1  0x2000000000099830 in WaitFd () from /usr/lib/libapt-pkg-libc6.3-5.so.3.3
#2  0x400000000007ce00 in MultiCompress::Child (this=0x60000fffffffb0a0, FD=7)
    at multicompress.cc:376
#3  0x400000000007bd20 in MultiCompress::Start (this=0x60000fffffffb0a0)
    at multicompress.cc:181
#4  0x400000000007ac30 in MultiCompress (this=0x60000fffffffb0a0, Output=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<No data fields>}, _M_p = 0x6000000000033a00 "./dists/woody-hpde/main/binary-ia64/Packages"}, static _S_empty_rep_storage = {0, 0, 1686, 0}}, Compress=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<No data fields>}, _M_p = 0x6000000000035fb8 ". gzip"}, static _S_empty_rep_storage = {0, 0, 1686, 0}}, Permissions=221118, Write=true) at multicompress.cc:48
#5  0x4000000000009610 in PackageMap::GenPackages (this=0x600000000002c320,
    Setup=@0x60000fffffffa7c0, Stats=@0x60000fffffffb130) at apt-ftparchive.cc:176
#6  0x4000000000030f50 in Generate (CmdL=@0x60000fffffffb5e0) at stl_iterator.h:605
#7  0x200000000008eb90 in CommandLine::DispatchArg ()
   from /usr/lib/libapt-pkg-libc6.3-5.so.3.3
#8  0x40000000000359a0 in main (argc=30560, argv=0x60000000000077d0)
    at apt-ftparchive.cc:898
(gdb)
#0  0x2000000000788e61 in select () from /lib/tls/libc.so.6.1
#1  0x2000000000099830 in WaitFd () from /usr/lib/libapt-pkg-libc6.3-5.so.3.3
#2  0x400000000007ce00 in MultiCompress::Child (this=0x60000fffffffb0a0, FD=7)
    at multicompress.cc:376
#3  0x400000000007bd20 in MultiCompress::Start (this=0x60000fffffffb0a0)
    at multicompress.cc:181
#4  0x400000000007ac30 in MultiCompress (this=0x60000fffffffb0a0, Output=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<No data fields>}, _M_p = 0x6000000000033a00 "./dists/woody-hpde/main/binary-ia64/Packages"}, static _S_empty_rep_storage = {0, 0, 1686, 0}}, Compress=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<No data fields>}, _M_p = 0x6000000000035fb8 ". gzip"}, static _S_empty_rep_storage = {0, 0, 1686, 0}}, Permissions=221118, Write=true) at multicompress.cc:48
#5  0x4000000000009610 in PackageMap::GenPackages (this=0x600000000002c320,
    Setup=@0x60000fffffffa7c0, Stats=@0x60000fffffffb130) at apt-ftparchive.cc:176
#6  0x4000000000030f50 in Generate (CmdL=@0x60000fffffffb5e0) at stl_iterator.h:605
#7  0x200000000008eb90 in CommandLine::DispatchArg ()
   from /usr/lib/libapt-pkg-libc6.3-5.so.3.3
#8  0x40000000000359a0 in main (argc=30560, argv=0x60000000000077d0)
    at apt-ftparchive.cc:898

-----------------------------------------------------------------------

jswright@ftp-linux:~$ ps -u jswright|grep gzip
 2134 pts/7    00:00:00 gzip
 3225 pts/7    00:00:00 gzip
jswright@ftp-linux:~$ gdb /bin/gzip 2134
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "ia64-linux"...Using host libthread_db library "/lib/tls/libthread_db.so.1".

Attaching to program: /bin/gzip, process 2134
Reading symbols from /lib/tls/libc.so.6.1...done.
Loaded symbols for /lib/tls/libc.so.6.1
Reading symbols from /lib/ld-linux-ia64.so.2...done.
Loaded symbols for /lib/ld-linux-ia64.so.2
0x20000000001b8f81 in read () from /lib/tls/libc.so.6.1
(gdb) bt
#0  0x20000000001b8f81 in read () from /lib/tls/libc.so.6.1
#1  0x4000000000016c00 in file_read (
    buf=0x6000000000054150 "whistles\n Vim is a very capable editor. Its scripting support allows the use of plugins\n that enhance the functionality of it. Many people have written scripts, they\n are scattered all over the web; h"..., size=32768) at zip.c:111
#2  0x4000000000002bc0 in fill_window () at deflate.c:532
#3  0x4000000000003900 in deflate () at deflate.c:719
#4  0x4000000000016470 in zip (in=48480, out=48240) at zip.c:76
#5  0x4000000000005530 in treat_stdin () at gzip.c:667
#6  0x4000000000004e20 in main (argc=2, argv=0x60000fffffffba88) at gzip.c:449

-----------------------------------------------------------------------

jswright@ftp-linux:~$ gdb /bin/gzip 3225
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "ia64-linux"...Using host libthread_db library "/lib/tls/libthread_db.so.1".

Attaching to program: /bin/gzip, process 3225
Reading symbols from /lib/tls/libc.so.6.1...done.
Loaded symbols for /lib/tls/libc.so.6.1
Reading symbols from /lib/ld-linux-ia64.so.2...done.
Loaded symbols for /lib/ld-linux-ia64.so.2
0x20000000001e9ad1 in pthread_setcanceltype () from /lib/tls/libc.so.6.1
(gdb) bt
#0  0x20000000001e9ad1 in pthread_setcanceltype () from /lib/tls/libc.so.6.1
#1  0x2000000000113670 in _IO_adjust_column () from /lib/tls/libc.so.6.1
#2  0x2000000000113710 in _IO_flush_all () from /lib/tls/libc.so.6.1
#3  0x2000000000113c90 in _IO_cleanup () from /lib/tls/libc.so.6.1
#4  0x20000000000977a0 in exit () from /lib/tls/libc.so.6.1
#5  0x400000000000a6d0 in do_exit (exitcode=1) at gzip.c:1832
#6  <signal handler called>
#7  0x2000000000113320 in _IO_adjust_column () from /lib/tls/libc.so.6.1
#8  0x2000000000113710 in _IO_flush_all () from /lib/tls/libc.so.6.1
#9  0x2000000000113c90 in _IO_cleanup () from /lib/tls/libc.so.6.1
#10 0x20000000000977a0 in exit () from /lib/tls/libc.so.6.1
#11 0x400000000000a6d0 in do_exit (exitcode=1) at gzip.c:1832
#12 0x4000000000015ab0 in read_error () at util.c:398
#13 0x4000000000014de0 in fill_inbuf (eof_ok=0) at util.c:122
#14 0x4000000000008ad0 in get_method (in=0) at gzip.c:1228
#15 0x4000000000005570 in treat_stdin () at gzip.c:739
#16 0x4000000000004e20 in main (argc=2, argv=0x60000fffffffba88) at gzip.c:449



-- System Information:
Debian Release: 3.1
Architecture: ia64
Kernel: Linux 2.6.11.6-andrew
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)

Versions of packages apt-utils depends on:
ii  apt [libapt-pkg-libc6.3-5-3 0.5.28.6     Advanced front-end for dpkg
ii  libc6.1                     2.3.2.ds1-22 GNU C Library: Shared libraries an
ii  libdb4.2                    4.2.52-18    Berkeley v4.2 Database Libraries [
ii  libgcc1                     1:3.4.3-13   GCC support library
ii  libstdc++5                  1:3.3.5-13   The GNU Standard C++ Library v3

-- no debconf information



Reply to: