DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
SCO crash quick reference

SCO crash quick reference

crash synopsis

SCO OpenServer 5 /etc/crash [-d dumpfile] [-n namelist] [-w outputfile >> batchfile]
SVR5 /usr/sbin/crash [-a analysisdir] [-b batchfile -d dumpfile] [-n namelist] [-m moduledir] [-w outputfile]

Operators

Operator Associativity
- ~ * () right to left
* / % # left to right
+ - left to right
<< >> left to right
& left to right
^ left to right
| left to right
= += -= *= /= #=
%= &= |= ^= >>= <<=
right to left

Useful local crash variables

$$ value of the most recently evaluated expression
$A set to 1 if an active system is being examined; set to 0 otherwise
$C number of active CPUs in addition to the base processor
$P number of the slot for the current process
$U size of the u-area excluding the Task State Segment (TSS)

Common crash command options and arguments

SCO OpenServer 5 Description SVR5
-e Display every entry in a table -e
-f Display the full structure -f
-- Display privilege names symbolically -n
-p Interpret all addresses in the command line as physical addresses -p
-s process Specify process other than default -s process
-w file Redirect the output to file. Works with all commands except plock and quit. -w file
process Processes may be identified by their slot numbers in the process table, or by their process ID number prefixed by a ``#'' (for example, #3091). A ``#'' on its own specifies the currently defined process. process
table_entry Table entries are identified by their slot number, a range of slot numbers, or a mixture of these (for example, 2 4 6..8) table_entry
start_addr A start address is expressed as a numeric value, a symbol, or an expression (for example, symbol+offset) start_addr

General purpose crash commands

SCO OpenServer 5 Description SVR5
? List all available commands ?
!command Issue shell command. !command
-- Print audit buffer data. mode can be -l (long), -t (short), or -b (byte). abuf [-mode]
-- Print address space information for process segment as [-e][-f] [proc...]
base expression ... Print expression in all bases base expression ...
curproc [ -c | process ] Identical to defproc --
defproc [ -c | process ] Set the value of the process slot argument. defproc [ -c | process
dis [-a] start_addr [count] Disassemble from the start address for count instructions. On SVR5, -c can be used in place of start_addr to continue disassembly from a previous disassembly. dis [ -a ] start_addr | -c [ count ]
ds virtual_addr ... Print the data symbol whose address is closest to, but not greater than, the virtual address entered. ds virtual_addr ...
eval expression ... Evaluate an expression in all formats. --
findaddr table slot Print the address of slot in table. findaddr table slot
help command ... Print the syntax of command, a short description, and any aliases (equivalent commands). help command ...
mode [ p | v ] Set or change address mode. mode [ p | v ]
nm symbol ... | -e Print address and type of symbol. nm symbol ... | -e
od [-p] [-a|-c|-d|-h|-o|-x]
    [-b|-l|-t] [-s process]
    [-p] start_addr [count]
Print count symbol values beginning at start_addr. od [-p] [-format] [-mode]
    [-s process]
    start_addr [count]
panic Print most recent system notices, warnings, and panic messages panic
plock [ -d | -t | -u ] Lock the crash process in memory. --
-- Print processor local data for current engine plocal
quit Exit the crash session. quit
rd [-p] [-a|-c|-d|-h|-o|-x]
    [-b|-l|-t] [-s process]
    [-p] start_addr [count]
Identical to od. --
redirect [ -c | file ] Redirect output to file. redirect [ -c | file ]
search [-p] [-s process]
   [-m mask] pattern
   start_addr length
Print long words in memory that match pattern, beginning at start_addr, and ending at start_addr plus length. search [ -p ] [ -m mask ]
   [ -s process ]
   pattern start_addr length
size [ -x ] [ structure ... ] Print size of structure. size [ -x ] [ structure ... ]
stat Print operating system information. stat
ts virtual_addr ... Print text symbol that is closest to, but not greater than, the address. ts virtual_addr ...
-- Print information about LWPs tslwp
var Print values of tunable system parameters. var
vtop [ -s process ] start_addr ... Print physical address corresponding to virtual start address. vtop [ -s process ] start_addr ...

Viewing kernel structures with crash (Part 1/2)

SCO OpenServer 5 Description SVR5
boot [-ef] [-p boot_info
    [boot_misc [boot_apm]]]
Display information passed to the kernel at boot time. --
buffer [format] table_entry | [-p] start_addr Display contents of the buf structure. buffer [format] | [-p] addr
bufhdr [-f] [[-p] table_entry...] Display bufhdr structure. bufhdr] [-f] [[-p] addr...]
callout Display callout table. --
cblock [ -eft ] [ -p ] table_entry ... ] Print cblock structures. --
-- Set current CPU group cg [cgnum]
-- Print local information for current CPU group cglocal
-- Print information about process scheduler classes class [table_entry]
dbfree [ class ... ] Display extdatab structure. --
dblock [-e] [-c class ... ] Display allocated extdatab structures  
--    
-- Set lwp slot to current process deflwp [slot]
-- Print dispatcher (scheduler) queues. dispq [-l|-g] [table_entry...]
eproc [-ef] [[-p] process...| [-r]] Display eproc structure. --
-- Set current engine to eng_num. eng [eng_num]
-- Print active event queue. evactive [-f] [event_name]
-- Print events memory management information evmm
file [-e] [[-p] table_entry...] Display the file structure. file [-e] [[-p] table_entry...]
-- Print kernel privilege table. filepriv [-e] [-n] [[-p] table_entry...]
-- Print table, entry slot number, and offset for structure findslot virtual_address...
fs [ [ -p ] table_entry ... ] Display fsinfo structure. fs [ [ -p ] table_entry ... ]
-- Print gift descriptor protocol table gdp [-e] [-f] [[-p] table_entry...]
gdt [-e] [-c cpu] [slot [count]] Print the Global Descriptor Table. gdt [-e] [slot [count] table_entry...]
-- Print high resolution timer information hrt
idt [-e] [-c cpu] [slot [count]] Print the Interrupt Descriptor Table. --
inode [-eflr] [[-p] table_entry...] Display incore inode information. inode [-ef] [[-p] table_entry...]
kfp [-s process] [-r | kfp] Display frame pointer for the start of
a kernel (system) stack trace.
kfp [value]
-- Print kernel memory allocator statistics kmastat
ksp [-s process] [-r | ksp] Print the kernel stack pointer. --
lck [-e] [[-p] table_entry...] Print record-locking information. lck [-e] [[-p] table_entry...]
ldt [-e] [process [slot [count]]] Print the Local Descriptor Table for a specified process. ldt [-e] [process [slot [count]]]
-- Print out level identifier translation cache lidcache
linkblk [-e] [-p] table_entry...] Display linkblk structure. linkblk [-e] [[-p] table_entry...]
map mapname ... Print the map structure of mapname. map mapname ...
mbfree Display msgb structure. --
mblock [-e] [-p]table_entry Display allocated msgb structure. --
mount [-e] [[-p] [-v] table_entry...] Display mount structure. mount [-e] [[-p] table_entry...]
-- Print page information. page [-e] [[-p] table_entry...]
pbfree Display free pageb structures. --
pblock [-e] [ -c class ... | [-p] table_entry...] Display allocated pageb structures. --

Viewing kernel structures with crash (Part 2/2)

SCO OpenServer 5 Description SVR5
pbp[ool] Display pageb structures reserved for interrupt time allocations. --
pcb [-u | -k] [process] | -i [-p] start_addr Print Process Control Block of process. pcb [process]
-- Print cdfs_inodes structure pcinode
pdt [-e] [-s process] [-p] slot | start_addr [count] Display pde structure. --
pfdat [-e] [[-p] table_entry...] Display pfdat structure. --
pregion [-e] [[-p] process...| Display pregion structure. --
-- Print info about private data of processes prnode [-e] [[-p] table_entry...]
proc [-ef] [-q | -l] [[-p] process...| -r] Display proc structure. proc [-e] [-f [-n]]    [[-p] table_entry...|
   #procid...|] proc [-f [-n]] -r]
-- Display page descriptor table ptbl [-e] [-s process] [[-p] addr [count]]
-- Display configured pseudo ttys. pty [-f] [-e] [-s] [-h] [-l]
qrun Display scheduled queue structures. qrun
queue [-e] [[-p] table_entry...] Display allocated queue structures. queue [-e] [[-p] table_entry...]
-- Display receive descriptor table rcvd [-e] [-f] [[-p] table_entry...]
-- Display receive descriptor user table rduser [-e] [-f] [[-p] table_entry...]
region [-ef] [[-p] table_entry...] Display region structure. --
-- Display realtime scheduler parameter table rtdptbl [table_entry...]
rtop [-l | -q] [-p] [table_entry...] Print process table entries of processes
in specified region table entries.
--
-- Display realtime process information rtproc
runq Display processes on the run queue. --
sdt [-ef] [-s process] [-p] [slot | start_addr [count]] Display page directory table entries for a process. --
-- Display ufs or sfs inode table sinode [-e] [-f] [[-p] table_entry...]
-- Display open special files snode [-e] [-f] [[-p] table_entry...]
-- Display server mount table srmount [-e] [[-p] table_entry...]
stack [-u | -k | -l] [process...] Dump user or kernel stack for the specified process. stack [process]
stream [-ef] [[-p] table_entry...] Display allocated stdata and strevent structures. stream [-ef] [[-p] table_entry...]
strstat Display STREAMS statistics. strstat
trace [-e] [-q | -l] [-r] [process... ] Print system (kernel) stack trace. trace [process]
-- Display timesharing scheduler parameter table tsdptbl [table_entry...]
tss [-u | -k] [process] | -i [-p] start_addr Print the Task State Segment of a process.  
tty [-ef] [-t type [[-p] table_entry...]
   | [-p] start_addr ] ]
Print entries in the tty table. tty [-ef] [-l] [-t type [[-p] table_entry...]
   | [-p] start_addr ] ]
user [-f] [process] Print information about u-area of process. user [-f] [process]
-- Identical to mount vfs [-e] [[-p] table_entry...]
-- Display info about configured file system types vfssw [[-p] vnode_addr...]
-- Print vnode information vnode [[-p] vnode_addr...]
-- Print vxfs inode table vxinode [-e] [-f] [-l] [-r] [vs_inodeaddr...]


© 2005 The SCO Group, Inc. All rights reserved.
OpenServer 6 and UnixWare (SVR5) HDK - June 2005