Debian Bug report logs - #704193
guaranteed Segmentation fault

version graph

Package: locate; Maintainer for locate is Andreas Metzler <ametzler@debian.org>; Source for locate is src:findutils.

Reported by: jidanni@jidanni.org

Date: Fri, 29 Mar 2013 09:15:01 UTC

Severity: normal

Tags: patch

Found in version findutils/4.5.11-1

Fixed in version findutils/4.5.11-2

Done: Andreas Metzler <ametzler@debian.org>

Bug is archived. No further changes may be made.

Forwarded to http://savannah.gnu.org/bugs/?38673

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Fri, 29 Mar 2013 09:15:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to jidanni@jidanni.org:
New Bug report received and forwarded. Copy sent to Andreas Metzler <ametzler@debian.org>. (Fri, 29 Mar 2013 09:15:05 GMT) Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: jidanni@jidanni.org
To: submit@bugs.debian.org
Subject: guaranteed Segmentation fault
Date: Fri, 29 Mar 2013 17:10:07 +0800
Package: locate
Version: 4.5.11-1

# su - nobody
No directory, logging in with HOME=/
nobody@jidanni2:/$ locate zzzz
locate: warning: database '/var/cache/locate/locatedb' is more than 8 days old (actual age is 20.4 days)
Segmentation fault

-- System Information:
Debian Release: 7.0
  APT prefers experimental
  APT policy: (990, 'experimental'), (500, 'unstable')
Architecture: i386 (i686)

Kernel: Linux 3.8-trunk-486
Locale: LANG=zh_TW.UTF-8, LC_CTYPE=zh_TW.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages locate depends on:
ii  findutils  4.5.11-1
ii  libc6      2.17-0experimental2



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Fri, 29 Mar 2013 14:45:08 GMT) Full text and rfc822 format available.

Acknowledgement sent to sacrificial-spam-address@horizon.com:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Fri, 29 Mar 2013 14:45:08 GMT) Full text and rfc822 format available.

Message #10 received at 704193@bugs.debian.org (full text, mbox):

From: sacrificial-spam-address@horizon.com
To: 704193@bugs.debian.org
Cc: sacrificial-spam-address@horizon.com
Subject: I also see this (i386)
Date: 29 Mar 2013 10:25:02 -0400
Control: found 704193 4.5.11-1
Architecture: i386

Here's an strace.  The segfault happens just AFTER locatedb is closed.
It also happns on a successful lookup.  I'm running i386 sid userland
on an x86_64 kernel.

execve("/usr/bin/locate", ["locate", "qqqq"], [/* 24 vars */]) = 0
brk(0)                                  = 0x84a9000
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf77cd000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=145521, ...}) = 0
mmap2(NULL, 145521, PROT_READ, MAP_PRIVATE, 3, 0) = 0xf77a9000
close(3)                                = 0
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
open("/lib/i386-linux-gnu/i686/cmov/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0P\372\202M4\0\0\0"..., 512) = 512
fstat64(3, {st_mode=S_IFREG|0755, st_size=1756536, ...}) = 0
mmap2(0x4d816000, 1764124, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x4d816000
mmap2(0x4d9bf000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1a9) = 0x4d9bf000
mmap2(0x4d9c2000, 11036, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x4d9c2000
close(3)                                = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf77a8000
set_thread_area({entry_number:-1 -> 12, base_addr:0xf77a8900, limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0, useable:1}) = 0
mprotect(0x805a000, 4096, PROT_READ)    = 0
mprotect(0x4d9bf000, 8192, PROT_READ)   = 0
mprotect(0x4d812000, 4096, PROT_READ)   = 0
munmap(0xf77a9000, 145521)              = 0
open("/var/cache/locate/locatedb", O_RDONLY|O_LARGEFILE) = 3
fcntl64(3, F_SETFD, FD_CLOEXEC)         = 0
geteuid32()                             = $UID
getuid32()                              = $UID
getgid32()                              = $GID
setgid32($GID)                          = 0
brk(0)                                  = 0x84a9000
brk(0x84ca000)                          = 0x84ca000
ioctl(1, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
fstat64(3, {st_mode=S_IFREG|0644, st_size=21917714, ...}) = 0
time(NULL)                              = 1364566351
fcntl64(3, F_GETFL)                     = 0x8000 (flags O_RDONLY|O_LARGEFILE)
fstat64(3, {st_mode=S_IFREG|0644, st_size=21917714, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf77cc000
_llseek(3, 0, [0], SEEK_CUR)            = 0
read(3, ""..., 4096) = 4096

(Lots of additional reads omitted)

read(3, "", 4096)                       = 0
close(3)                                = 0
munmap(0xf77cc000, 4096)                = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Mon, 01 Apr 2013 16:48:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Metzler <ametzler@downhill.at.eu.org>:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Mon, 01 Apr 2013 16:48:04 GMT) Full text and rfc822 format available.

Message #15 received at 704193@bugs.debian.org (full text, mbox):

From: Andreas Metzler <ametzler@downhill.at.eu.org>
To: jidanni@jidanni.org, 704193@bugs.debian.org
Cc: sacrificial-spam-address@horizon.com
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: Mon, 1 Apr 2013 18:46:12 +0200
On 2013-03-29 jidanni@jidanni.org wrote:
> Package: locate
> Version: 4.5.11-1

> # su - nobody
> No directory, logging in with HOME=/
> nobody@jidanni2:/$ locate zzzz
> locate: warning: database '/var/cache/locate/locatedb' is more than 8 days old (actual age is 20.4 days)
> Segmentation fault

Hello,

is the "su - nobody" necessary or do you see this as regular user,
too? 

The whole thing seems to depend on the specific
/var/cache/locate/locatedb (please make backup copy), I cannot reproduce
it here. - Does locate 4.4.2-5 work with this locate-db?

thanks, cu andreas



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Mon, 01 Apr 2013 19:15:07 GMT) Full text and rfc822 format available.

Acknowledgement sent to sacrificial-spam-address@horizon.com:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Mon, 01 Apr 2013 19:15:07 GMT) Full text and rfc822 format available.

Message #20 received at 704193@bugs.debian.org (full text, mbox):

From: sacrificial-spam-address@horizon.com
To: 704193@bugs.debian.org, ametzler@downhill.at.eu.org, jidanni@jidanni.org
Cc: sacrificial-spam-address@horizon.com
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: 1 Apr 2013 15:14:08 -0400
> is the "su - nobody" necessary or do you see this as regular user,
> too? 

Me, I see this as a regular user.

> The whole thing seems to depend on the specific
> /var/cache/locate/locatedb (please make backup copy), I cannot reproduce
> it here. - Does locate 4.4.2-5 work with this locate-db?

I tested with 4.4.2-5, 4.5.10-1 and 4.5.10-2.  None segfault.
Re-installing 4.5.11-1 produces a segfault.  (I ran these tests
as root for simplicity.)

Note that this is a locatedb rebuilt today, which is different
from the one when I first reported.  But I made a snapshot anyway.



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Mon, 01 Apr 2013 23:33:08 GMT) Full text and rfc822 format available.

Acknowledgement sent to jidanni@jidanni.org:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Mon, 01 Apr 2013 23:33:08 GMT) Full text and rfc822 format available.

Message #25 received at 704193@bugs.debian.org (full text, mbox):

From: jidanni@jidanni.org
To: sacrificial-spam-address@horizon.com
Cc: 704193@bugs.debian.org, ametzler@downhill.at.eu.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: Tue, 02 Apr 2013 07:29:42 +0800
s> Re-installing 4.5.11-1 produces a segfault.
OK I'm glad you guys can reproduce it! I'll leave it in your hands.



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Tue, 02 Apr 2013 01:00:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to sacrificial-spam-address@horizon.com:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Tue, 02 Apr 2013 01:00:04 GMT) Full text and rfc822 format available.

Message #30 received at 704193@bugs.debian.org (full text, mbox):

From: sacrificial-spam-address@horizon.com
To: jidanni@jidanni.org, sacrificial-spam-address@horizon.com
Cc: 704193@bugs.debian.org, ametzler@downhill.at.eu.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: 1 Apr 2013 20:56:32 -0400
>s> Re-installing 4.5.11-1 produces a segfault.
> OK I'm glad you guys can reproduce it! I'll leave it in your hands.

Er... I'm just a second schlub who reported the same symptoms.
Even though the maintainer wrote to you, and not me, I figured
I'd volunteer the requested information.

But same symptom doesn't necessarily mean same problem.  It's
only likely.

You're still not off the hook.  Does 4.5.11-1 word for you?



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Tue, 02 Apr 2013 02:06:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to jidanni@jidanni.org:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Tue, 02 Apr 2013 02:06:04 GMT) Full text and rfc822 format available.

Message #35 received at 704193@bugs.debian.org (full text, mbox):

From: jidanni@jidanni.org
To: sacrificial-spam-address@horizon.com
Cc: 704193@bugs.debian.org, ametzler@downhill.at.eu.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: Tue, 02 Apr 2013 10:02:22 +0800
s> You're still not off the hook.  Does 4.5.11-1 word for you?
That's the version I reported.

P.S., try strace on it. (Which is also broken for me due to
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=702309 so I can't.)



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Tue, 02 Apr 2013 02:39:07 GMT) Full text and rfc822 format available.

Acknowledgement sent to sacrificial-spam-address@horizon.com:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Tue, 02 Apr 2013 02:39:07 GMT) Full text and rfc822 format available.

Message #40 received at 704193@bugs.debian.org (full text, mbox):

From: sacrificial-spam-address@horizon.com
To: jidanni@jidanni.org, sacrificial-spam-address@horizon.com
Cc: 704193@bugs.debian.org, ametzler@downhill.at.eu.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: 1 Apr 2013 22:38:00 -0400
>> You're still not off the hook.  Does 4.5.11-1 word for you?
> That's the version I reported.

Oops, my cut-and-paste error.  I meant 4.4.2-5.

> P.S., try strace on it. (Which is also broken for me due to
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=702309 so I can't.)

Already done in my first bug report.  Also, that bug report says you
can downgrade to the unstable version (4.5.20-2.3) and it works fine.
That's the version I'm using.



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Tue, 02 Apr 2013 03:57:09 GMT) Full text and rfc822 format available.

Acknowledgement sent to jidanni@jidanni.org:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Tue, 02 Apr 2013 03:57:09 GMT) Full text and rfc822 format available.

Message #45 received at 704193@bugs.debian.org (full text, mbox):

From: jidanni@jidanni.org
To: sacrificial-spam-address@horizon.com
Cc: 704193@bugs.debian.org, ametzler@downhill.at.eu.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: Tue, 02 Apr 2013 11:54:12 +0800
All I know is the problem started when I made the jump to experimental.
$ apt-cache policy $@
locate:
  Installed: 4.5.11-1
  Candidate: 4.5.11-1
  Version table:
 *** 4.5.11-1 0
        990 http://ftp.br.debian.org/debian/ experimental/main i386 Packages
        100 /var/lib/dpkg/status
     4.4.2-5 0
        500 http://ftp.br.debian.org/debian/ unstable/main i386 Packages



Set Bug forwarded-to-address to 'http://savannah.gnu.org/bugs/?38673'. Request was from Andreas Metzler <ametzler@downhill.at.eu.org> to control@bugs.debian.org. (Sat, 06 Apr 2013 07:09:08 GMT) Full text and rfc822 format available.

Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Tue, 16 Apr 2013 17:39:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Metzler <ametzler@downhill.at.eu.org>:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Tue, 16 Apr 2013 17:39:04 GMT) Full text and rfc822 format available.

Message #52 received at 704193@bugs.debian.org (full text, mbox):

From: Andreas Metzler <ametzler@downhill.at.eu.org>
To: sacrificial-spam-address@horizon.com, 704193@bugs.debian.org
Cc: jidanni@jidanni.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: Tue, 16 Apr 2013 19:34:32 +0200
On 2013-04-01 sacrificial-spam-address@horizon.com wrote:
[...]
> I tested with 4.4.2-5, 4.5.10-1 and 4.5.10-2.  None segfault.
> Re-installing 4.5.11-1 produces a segfault.  (I ran these tests
> as root for simplicity.)
[...]

Hello,

Does
http://git.savannah.gnu.org/cgit/findutils.git/commit/?id=4b7c8a448651fe96b72fd1e48fe0003778efe85a
fix the issue for you? For your convenience I have generated test
packages with this patch included and have uploaded these to
http://people.debian.org/~ametzler/
cu Andreas



Information forwarded to debian-bugs-dist@lists.debian.org, Andreas Metzler <ametzler@debian.org>:
Bug#704193; Package locate. (Tue, 16 Apr 2013 18:15:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to sacrificial-spam-address@horizon.com:
Extra info received and forwarded to list. Copy sent to Andreas Metzler <ametzler@debian.org>. (Tue, 16 Apr 2013 18:15:04 GMT) Full text and rfc822 format available.

Message #57 received at 704193@bugs.debian.org (full text, mbox):

From: sacrificial-spam-address@horizon.com
To: 704193@bugs.debian.org, ametzler@downhill.at.eu.org, sacrificial-spam-address@horizon.com
Cc: jidanni@jidanni.org
Subject: Re: Bug#704193: guaranteed Segmentation fault
Date: 16 Apr 2013 14:11:38 -0400
Control: tags 704193 patch

> Does
> http://git.savannah.gnu.org/cgit/findutils.git/commit/?id=4b7c8a448651fe96b72fd1e48fe0003778efe85a
> fix the issue for you? For your convenience I have generated test
> packages with this patch included and have uploaded these to
> http://people.debian.org/~ametzler/

Confirmed that your pathced package makes the segfault go away.
Switched back and forth to confirm that plain 4.5.11-1 degfaults,
+bugfix+1 does not.

Yay, thank you!



Added tag(s) patch. Request was from sacrificial-spam-address@horizon.com to 704193-submit@bugs.debian.org. (Tue, 16 Apr 2013 18:15:04 GMT) Full text and rfc822 format available.

Reply sent to Andreas Metzler <ametzler@debian.org>:
You have taken responsibility. (Sat, 20 Apr 2013 09:36:15 GMT) Full text and rfc822 format available.

Notification sent to jidanni@jidanni.org:
Bug acknowledged by developer. (Sat, 20 Apr 2013 09:36:15 GMT) Full text and rfc822 format available.

Message #64 received at 704193-close@bugs.debian.org (full text, mbox):

From: Andreas Metzler <ametzler@debian.org>
To: 704193-close@bugs.debian.org
Subject: Bug#704193: fixed in findutils 4.5.11-2
Date: Sat, 20 Apr 2013 09:32:42 +0000
Source: findutils
Source-Version: 4.5.11-2

We believe that the bug you reported is fixed in the latest version of
findutils, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 704193@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Andreas Metzler <ametzler@debian.org> (supplier of updated findutils package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Format: 1.8
Date: Sat, 20 Apr 2013 11:11:55 +0200
Source: findutils
Binary: findutils locate
Architecture: source i386
Version: 4.5.11-2
Distribution: experimental
Urgency: low
Maintainer: Andreas Metzler <ametzler@debian.org>
Changed-By: Andreas Metzler <ametzler@debian.org>
Description: 
 findutils  - utilities for finding files--find, xargs
 locate     - maintain and query an index of a directory tree
Closes: 657088 704193
Changes: 
 findutils (4.5.11-2) experimental; urgency=low
 .
   * [20_missing-variable-initialisati.patch] pulled from upstream git
     fixes a crash in locate. Closes: #704193
   * Patch from Steve Langasek/Ubuntu - Mark findutils and locate multi-arch:
     foreign. Closes: #657088
Checksums-Sha1: 
 39ccb0adb84cf7c3280d487b9c6db91361144e7d 1398 findutils_4.5.11-2.dsc
 8b6485def84153df6efc14e306c5c45b92e55afe 25139 findutils_4.5.11-2.debian.tar.gz
 3bdb3cf07ac8b771ce0297e160b4d8631b8c9c45 725564 findutils_4.5.11-2_i386.deb
 67a772249baa3b16084e82343cf80d90a1517c80 206568 locate_4.5.11-2_i386.deb
Checksums-Sha256: 
 4a76d14d73f5654d5326a55200bc5801f35ae93928d193f5614f80b2050c87e7 1398 findutils_4.5.11-2.dsc
 f00a5089901b889a2e042f1fc07307dae951f7087cce9edcd694dd9f003b8a69 25139 findutils_4.5.11-2.debian.tar.gz
 25250f8c869453e8744f74934d724ab759c6a6f8a3a3119e08cc1957210770a8 725564 findutils_4.5.11-2_i386.deb
 4e6ed29e46d961efe28c29b59d79daeb5da9144fe3f7bfba9e5e4214784b0e8b 206568 locate_4.5.11-2_i386.deb
Files: 
 91e64979936ca75f60b3270b41355acf 1398 utils required findutils_4.5.11-2.dsc
 05ad8a5f57011f970e9b4da5178fdad8 25139 utils required findutils_4.5.11-2.debian.tar.gz
 a98f7a7f033702c52e3dcb0b8238cc7c 725564 utils required findutils_4.5.11-2_i386.deb
 dea1a3a5420b28813348e9fd1119450c 206568 utils optional locate_4.5.11-2_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEAREDAAYFAlFyXIMACgkQHTOcZYuNdmOfaQCggG0K9RrwV0r4tHvFfThGfk7o
sV4An3koXsAs3D0q80U8enlMErV6wYel
=thjs
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sun, 19 May 2013 07:30:07 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sun Apr 20 01:40:16 2014; Machine Name: buxtehude.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.