pstack
El comando pstack imprimirá un vaciado hexadecimal de la pila del proceso, brindando información importante sobre un proceso sospechoso en el sistema afectado.
[root@walv215-a1j:mgeiser]#pstack 1094
1094: /usr/lib/sendmail -bd -q15m
fefc6004 pollsys (ffbfd080, 3, ffbfd128, 0)
fef66f20 pselect (ffbfd080, feff2530, feff2530, 40, ffbfd128, 0) + 1c8
fef67298 select (8, ffbfdb18, 0, 0, ffbfdb10, 109400) + a0
0002852c getrequests (121744, 7, 7, 11c388, 11c2f8, 3) + 690
00048a94 main (0, 13f800, 64, 10f800, 121c00, e8c00) + 5b68
0001f6e0 _start (0, 0, 0, 0, 0, 0) + 108
Este comando también se puede usar en archivos básicos.
# pstack core.httpd.1008
core 'core.httpd.1008' of 1008: /opt/IBMHTTPD/bin/httpd
----------------- lwp# 1 / thread# 1 --------------------
0002e3e8 ???????? (ffbeee7c, 1425, d, a16f0, 82b68, 9b098)
00031188 main (1, ffbeef94, 96408, ff238018, ff23b03c, 82cf0) + 478
00031bec parse_byterange (1, ffbeef94, ffbeef9c, 96000, 0, 0) + 484
00017308 load_module (0, 0, 0, 0, 0, 0) + 140
----------------- lwp# 2 / thread# 2 --------------------
ff21ad54 _signotifywait (ff16e000, 0, 0, ff23b540, 0, 0) + 8
ff151ae4 thr_yield (0, 0, 0, 0, 0, 0) + 8c
----------------- lwp# 3 / thread# 3 --------------------
ff21b3e0 _lwp_sema_wait (fe30de30, ff16e000, 0, fe30dd78, 250c4, 0) + c
ff14944c _swtch (fe30dd78, fe30dd78, ff16e000, 5, 1000, 1) + 424
ff14d8a4 _reap_wait (ff172a08, 20a38, 0, ff16e000, 0, 0) + 38
ff14d5fc _reaper (ff16ee30, ff255d18, ff172a08, ff16ee08, 0,
fe400000) + 38
ff15ba1c _thread_start (0, 0, 0, 0, 0, 0) + 40
#
Este comando está disponible y puede usarse también en HP-UX, AIX y LINUX
gcore