From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30314 invoked by alias); 28 May 2009 20:29:51 -0000 Received: (qmail 30305 invoked by uid 22791); 28 May 2009 20:29:51 -0000 X-SWARE-Spam-Status: No, hits=-0.5 required=5.0 tests=BAYES_00,RCVD_NUMERIC_HELO,SPF_PASS X-Spam-Check-By: sourceware.org Received: from spsmtp02oc.mail2world.com (HELO spsmtp02oc.mail2world.com) (74.202.142.148) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 28 May 2009 20:29:46 +0000 Received: from mail pickup service by spsmtp02oc.mail2world.com with Microsoft SMTPSVC; Thu, 28 May 2009 13:28:23 -0700 auth-sender:drago.krznaric@spray.se Received: from 90.225.97.154 unverified ([90.225.97.154]) by spsmtp02oc.mail2world.com with Mail2World SMTP Server; Thu, 28 May 2009 13:28:22 -0700 Subject: Re: examining a core dump on a machine with other base addresses in shared libraries From: Drago Krznaric To: Paul Pluzhnikov Cc: gdb@sourceware.org In-Reply-To: <8ac60eac0905271646g2a775639sbe9a97d587fdc943@mail.gmail.com> References: <1243457555.17311.4.camel@localhost.localdomain> <8ac60eac0905271646g2a775639sbe9a97d587fdc943@mail.gmail.com> Content-Type: text/plain Date: Thu, 28 May 2009 20:29:00 -0000 Message-Id: <1243542581.8338.5.camel@localhost.localdomain> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2009-05/txt/msg00184.txt.bz2 Yes and no... It turns out that they're identical on A and B but on those machines I had an old gdb that couldn't deal with the prelinked libraries. When i ran the newer gdb I was on another machine that had some different libraries. However, running a newer gdb on A and B did indeed give a readable backtrace even with prelinked libraries. Thanx, drago On Wed, 2009-05-27 at 16:46 -0700, Paul Pluzhnikov wrote: > On Wed, May 27, 2009 at 1:52 PM, Drago Krznaric wrote: > > I have a program and a core dump created on machine A that I copy to > > machine B. I can open the core dump and get a nice backtrace on A but > > not on B. The reason appears to be that the shared libraries on A and B > > have different base addresses. They are otherwise exactly identical in > > hardware and software (RedHat 4). > > Are you absolutely sure the libc binaries are identical between A and B? > We see a lot of similar GDB failures due to mismatch between libc versions > (but we don't use prelink). > > You could verify whether prelink is the problem, by copying B:libc.so.6 and > B:ld-linux.so.2 to e.g. /tmp/lib, manually prelinking them to the same > address A:libc.so.6 and A:ld-linux.so.2 were prelinked at, and verifying > they "work" (set solib-absolute-prefix /tmp in GDB before loading the core). > > I think you should also get identical (as in md5sum-identical) binary > for B:/tmp/lib/libc.so.6 and A:/lib/libc.so.6 > > Cheers,