How can I analyze a core from the target on my hostsystem?
Daniel Jacobowitz
dmj+@andrew.cmu.edu
Fri Jun 8 10:47:00 GMT 2001
On Fri, Jun 08, 2001 at 12:55:22PM +0200, Frank Haverkamp wrote:
> Hi,
>
> one of the programs on my PowerPC embedded systems generated a
> core file. I want to analyze it on my host pc. Therefore I started my
> powerpc-linux-gdb debugger and asked it to load the core, but it
> refused:
>
> There is absolutely no warranty for GDB. Type "show warranty" for details.
> This GDB was configured as "--host=i586-pc-linux-gnu --target=powerpc-linux".
> (gdb)
> (gdb)
> (gdb) core-file core
> GDB can't read core files on this machine.
> (gdb)
>
> The gdb running on the target can analyze the core. But I want to
> do that on the hostsystem cause in production I will not have access
> to the target system anymore, but I will get the core files :-)
> and I should analyze them.
>
> So my question: Is that a misconfiguration of my selfcompiled
> powerpc-linux-gdb or is that not possible in general, and if it isn't
> what is the reason for it? What options do I have if analyzation of
> the target core file with is not possible on the host? Are there any
> other tools for that purpose?
Right now it is not possible to read core files in a cross debugger,
because gdb and bfd get the format of certain PT_NOTE sections from
host headers.
However, I've got patches to do this a little better. As soon as I
work out one last issue, I'll be posting them; however, right now they
contain some disgusting hacks, and I can't figure out cleanly how to do
the BFD part of the changes.
Thank the lord for mailing lists with more experienced people than I :)
--
Daniel Jacobowitz Debian GNU/Linux Developer
Monta Vista Software Debian Security Team
More information about the Gdb
mailing list