[prev in list] [next in list] [prev in thread] [next in thread] 

List:       hpux-devtools
Subject:    Re: HPUX-DEVTOOLS: finding proc_t in a dump
From:       Sabyasachi Sengupta <sabyasg () hp ! com>
Date:       2008-07-21 3:39:07
Message-ID: Pine.LNX.4.64.0807210847270.3900 () sabyasg ! india ! hp ! com
[Download RAW message or body]



Hi Stan,

Can you try the following in the crashdump from a kwdb session? You can dump 
the fields of proc_t by running "fields -c proc_t" and, then you can go 
about using load/keep/discard/pileon command combination to go down further. 
For example:

q4> load proc_t from proc_list max nproc next p_factp
This lets you traverse the proc_t's through p_factp as the "next" pointer 
and stores pointers of each proc_t in the memory as "piles".

q4> keep p_pid = 123
This lets you store details of process no 123 in the memory for future 
processing.

q4> pileon kthread_t from p_firstthreadp
Subsequently loads a pile of the kthread_t's of all threads of process 123.

In kwdb there is a concept of "piles" which are store houses of data. Piles 
remain in memory as long as the kwdb session runs, unless they are 
explicitly forgotten. In the above case, you would have the pointer to 
the first thread of a process, and from thereon you can go down further by 
looking at the fields -c kthread_t. If you would want to look for more 
details about debugging with kwdb and piles for crashdump analysis, you can 
look for the "kwdb comprehensive user guide" that is available at: 
http://www.hp.com/go/hpux_ddk, and then look for the "Kernel debugger" 
links. Once in the Kernel debugger page, you will find pointers to the user 
guide.

Is this what you're looking for? Feel free to let me know if you have any 
followup questions..

Best regards,
Sabya

-- 

HPUX Kernel debugger tools project
Ph: 91-80-25165263
Mailstop: Floor-1, Wing-C, Pillar-E3, Seat-115


On Fri, 18 Jul 2008, Stan Sieler wrote:

+ Date: Fri, 18 Jul 2008 22:58:05 +0000
+ From: Stan Sieler <sieler@allegro.com>
+ To: hpux devtools <hpux-devtools@cxx.cup.hp.com>
+ Subject: HPUX-DEVTOOLS: finding proc_t in a dump
+ 
+ hi,
+ 
+ I'm trying to figure out how to find a proc_t entry in an HP-UX dump.
+ 
+ On MPE/iX, for PID 123, I'd say the following in DAT:  = pib (123)
+ ...but I don't know the HP-UX kwdb equivalent.
+ 
+ (I really want the kthread_t of the first thread of a particular process,
+ but I can get that from the proc_t :)
+ 
+ In short, if I could tell kwdb:  pfind (123)
+ and get back a pointer, I'd be happy (for awhile :)
+ 
+ Any suggestions appreciated!
+ 
+ thanks,
+ 
+ --
+ Stan Sieler
+ work:     www.allegro.com
+ personal: www.sieler.com/wanted/index.html
+ 
+  _________________________________________________________________
+  To leave this mailing list, send mail to majordomo@cxx.cup.hp.com
+     with the message UNSUBSCRIBE hpux-devtools
+  _________________________________________________________________
+ 

 _________________________________________________________________
 To leave this mailing list, send mail to majordomo@cxx.cup.hp.com
    with the message UNSUBSCRIBE hpux-devtools
 _________________________________________________________________
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic