On 11/27/05, James C. McPherson <James.McPherson at sun.com> wrote: > > > Hi Tao, > since you know the pid that's hung, you can get the proc_t > structure, then the kthread and it's stack: > > > mdb> 0t711::pid2proc | ::print proc_t p_tlist|::findstack -v > > ::pid2proc translates the pid to a proc_t structure, which > contains an element called "p_tlist" -- a struct kthread_t. > Struct kthread_t contains at t_pcb[1] the pointer to that > thread's stack. > > Thanks!
I forced a dump last night. I also just recreated the "problem". >From either the dump (# mdb -k unix.0 vmcore.0) or the live system ( # mdb -k ), I got: > 0t552::pid2proc|::print proc_t p_tlist|::findstack -v [ fffffe8000d3bad0 _resume_from_idle+0xde() ] fffffe8000d3bb10 swtch+0x185() fffffe8000d3bb80 cv_wait_sig_swap_core+0x17a() fffffe8000d3bba0 cv_wait_sig_swap+0x1a() fffffe8000d3bc10 fifo_open+0x44e() fffffe8000d3bc70 fop_open+0x9a() fffffe8000d3bdd0 vn_openat+0x4a3() fffffe8000d3be90 copen+0x323() fffffe8000d3bec0 open64+0x33() fffffe8000d3bf10 sys_syscall32+0x101() Again, the user stack: # pstack 552 552: cp -r /export/share/tc /firewire/zfs fef6a907 open64 (8044e90, 0, 17) fef5c4d9 open64 (8044e90, 0) + 97 0805251f cpymve (8044e90, 8068900) + 59c 08053646 rcopy (8045ce0, 8067c68) + 116 08053ca0 copydir (8045ce0, 8067c68) + 25d 0805277b cpymve (8045ce0, 8067c68) + 7f8 08053646 rcopy (8046b30, 8066940) + 116 08053ca0 copydir (8046b30, 8066940) + 25d 0805277b cpymve (8046b30, 8066940) + 7f8 08053646 rcopy (8047d7e, 8066900) + 116 08053ca0 copydir (8047d7e, 8066900) + 25d 0805277b cpymve (8047d7e, 8066900) + 7f8 08051b65 main (4, 8047cb0, 8047cc4) + 467 Apprently one of the source file is a pipe! Then I remembered I created a pipe file during a test for pipe: # ls -l /export/share/tc/C/pipe/pipe.file prwxrwxrwx ... /export/share/tc/C/pipe/pipe.file That marks the first "real world" mdb experience for me :-) Thanks, Tao -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.opensolaris.org/pipermail/mdb-discuss/attachments/20051127/02249c4b/attachment.html>