Operating System - HP-UX
1822522 Members
2650 Online
109642 Solutions
New Discussion юеВ

Re: analyzing core files using adb or wdb

 
SOLVED
Go to solution
Amit Manna_6
Regular Advisor

analyzing core files using adb or wdb

Hi,

Can anybody tell me how to analyze core files in HP-UX using adb or wdb??/Step by step procedure will be highly appreciated.


Thanks and Regards,

Amit Manna
7 REPLIES 7
Manish Srivastava
Trusted Contributor

Re: analyzing core files using adb or wdb

Hi,

I have not done much of core analysis but at times stack trace helps.

gdb core
bt


HTH

manish
Shaikh Imran
Honored Contributor

Re: analyzing core files using adb or wdb

Hi,

For core dump analysis, you can use
file core
and
what core,
If you want detailed analysis use wdb:

wdb program core

where program is the executable that failed.

You can download wdb from here:
http://hp.com/go/wdb

Regards,






I'll sleep when i am dead.
Joseph Loo
Honored Contributor
Solution

Re: analyzing core files using adb or wdb

hi,

using the file command will identify what application generated the core:

# file core

another basic guide to analyze core files is found in this HP doc:

http://www2.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000063236268

regards.
what you do not see does not mean you should not believe
Muthukumar_5
Honored Contributor

Re: analyzing core files using adb or wdb

hai amit,

Let's see about wdb core debugging,

Before debugging set the core size as
# get the core size using
ulimit -a (or) ulimit -c (or) ulimit
# set your limit
ulimit -c
unlimited to make the usage as unlimited

gdb core-file
gdb> bt

it will show the cause for that core,

gdb> info signals
it will give the signal which effect the appliacation

gdb> where
it can also used to detect the location of core dumped.

Good guide here at
http://devrsrc1.external.hp.com/devresource/Tools/wdb/doc/guide/index.html

Regards,
Muthukumar.
Easy to suggest when don't know about the problem!
Muthukumar_5
Honored Contributor

Re: analyzing core files using adb or wdb

hai,

You can use the absolute debugger (adb) is the analysis of core files.

adb

adb> c
It will give the back trace

adb> m
It will give the file mappings

To know more about core file use
core(4) man page and sys/core.h

Regards,
Muthukumar
Easy to suggest when don't know about the problem!
R. Sri Ram Kishore_1
Respected Contributor

Re: analyzing core files using adb or wdb

Rick Beldin
HPE Pro

Re: analyzing core files using adb or wdb

Requirements for core accurate core analysis:

1. complete, untruncated core file from binary
2. *exact* binary that caused core
3. *all* the shared libraries that match *exactly* at the time of the failure. You can collect them and put them in a directory and set the environment variable GDB_SHLIB_PATH to point to this directory prior to running GDB

It is often easiest to do an initial core analysis on the same machine where failure occurred.

Can use chatr or ldd to find out complete list of shared libs. gdb has info shared which will give you a list of shared libs loaded at time of failure.
Necessary questions: Why? What? How? When?