From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23220 invoked by alias); 17 May 2011 17:09:07 -0000 Received: (qmail 23205 invoked by uid 22791); 17 May 2011 17:09:06 -0000 X-SWARE-Spam-Status: No, hits=-6.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 17 May 2011 17:08:52 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p4HH8qAV019613 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 17 May 2011 13:08:52 -0400 Received: from host1.jankratochvil.net (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p4HH8opC008853 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 17 May 2011 13:08:52 -0400 Received: from host1.jankratochvil.net (localhost [127.0.0.1]) by host1.jankratochvil.net (8.14.4/8.14.4) with ESMTP id p4HH8nfC002696; Tue, 17 May 2011 19:08:49 +0200 Received: (from jkratoch@localhost) by host1.jankratochvil.net (8.14.4/8.14.4/Submit) id p4HH8n89002695; Tue, 17 May 2011 19:08:49 +0200 Date: Tue, 17 May 2011 17:09:00 -0000 From: Jan Kratochvil To: Paul Pluzhnikov Cc: gdb-patches@sourceware.org Subject: Re: [patch] Fix GNU/Linux core open: Can't read pathname for load map: Input/output error. Message-ID: <20110517170849.GA2463@host1.jankratochvil.net> References: <20091006214556.GA12955@host0.dyn.jankratochvil.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2011-05/txt/msg00380.txt.bz2 On Tue, 17 May 2011 03:06:11 +0200, Paul Pluzhnikov wrote: > I see this all the time, and it causes end-user confusion. (a) The fix should be in glibc and not in gdb but it was rejected in glibc. (b) Loading libraries for a core file from the inferior solist stored in the core file does not work anyway. If you have a crashed application with memory corruption commonly the inferior solist is also corrupted, GDB fails to find the libraries, therefore fails to load relocated symbols and therefore fails to display symbols for the backtrace. The right approach is to map symbols for libraries according to their build-ids (when available). This is no longer dependent on the corrupted solist. And it is also no longer dependent on this glibc bug as the solist will no longer get used (it will - to check for libraries not having build-id). Unfortunately the whole build-id locating patch is not yet in FSF GDB. http://sourceware.org/ml/gdb-patches/2010-11/msg00353.html http://sourceware.org/ml/gdb-patches/2010-11/msg00354.html or: http://pkgs.fedoraproject.org/gitweb/?p=gdb.git;a=blob_plain;f=gdb-6.6-buildid-locate.patch;hb=f15 http://pkgs.fedoraproject.org/gitweb/?p=gdb.git;a=blob_plain;f=gdb-6.6-buildid-locate-rpm.patch;hb=f15 http://pkgs.fedoraproject.org/gitweb/?p=gdb.git;a=blob_plain;f=gdb-6.6-buildid-locate-rpm-librpm-workaround.patch;hb=f15 http://pkgs.fedoraproject.org/gitweb/?p=gdb.git;a=blob_plain;f=gdb-6.6-buildid-locate-core-as-arg.patch;hb=f15 I do not yet have written the build-id extension for mapping solibs but I will do it soon as it affects Fedora ABRT backtracing a lot. Thanks, Jan