Subject: Re: Debugging core dumps from Linux-emulated apps
To: None <netbsd-users@netbsd.org>
From: Christos Zoulas <christos@astron.com>
List: netbsd-users
Date: 04/17/2007 02:10:11
In article <20070416163852.GB4064@monolith.usask.ca>,
Brian de Alwis <bsd@cs.ubc.ca> wrote:
>I'm running a Linux app on NetBSD using the Linux emulation. The
>app is dumping core, but the core dump is a NetBSD core:
>
> $ file bin/java java.core
> bin/java: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV),
>for GNU/Linux 2.2.5, dynamically linked (uses shared libs), stripped
> java.core: ELF 32-bit LSB core file Intel 80386, version 1 (SYSV),
>NetBSD-style, from 'java' (signal 11)
>
>(This is the jRockit JVM.)
>
>I had thought gdb's bfd would DTRT (and tried the version from
>pkgsrc), but it complains that it wasn't compiled with a Linux ABI.
>
> This GDB was configured as "i386--netbsdelf"...
> warning: A handler for the OS ABI "GNU/Linux" is not built into this
>configuration
>
>And using a Linux GDB produces the same warning but for the NetBSD ABI.
>And a quick peek didn't show me anything obvious to enable it.
>
>Is it possible? Has anybody done this?
>
>(ktrace/ktruss doesn't show anything obvious.)
I was able to debug a 64 bit linux 1.6.0_01 jvm with NetBSD-current.
Perhaps gdb 6.x supports this? Try the pkgsrc version.
christos