1.
Kernel Crash Dump Analysis
PREPARED BY : Buland Singh, Red Hat
REVIEW BY : Jijesh Kalliyat, Red Hat
Version 1.0
Jan 2016
Send feedback to jkalliya@redhat.com
12.
sshkey <path>
o Used to specify the path of the ssh key you want to use when do ssh dump, the default value is
/root/.ssh/kdump_id_rsa
o kdump will use the sshkey to do ssh dump.
Eg:
sshkey /root/.ssh/kdump_id_rsa
path <path>
o "path" represents the filesystem path in which vmcore will be saved.
o If a dump target is specified in kdump.conf, then "path" is relative to the specified dump target.
o Interpretation of path changes a bit if user has not specified a dump target explicitly in kdump.conf. In this
case, "path" represents the
absolute path from root. And dump target and adjusted path are arrived at automatically depending on what's
mounted in the current system.
o Ignored for raw device dumps.
o If unset, will default to /var/crash.
Eg:
path /var/crash
core_collector <command> <options>
o This allows you to specify the command to copy the vmcore.
o Default core_collector for other targets is: "makedumpfile c messagelevel 1 d 31"
Eg:
core_collector makedumpfile c messagelevel 1 d 31
o The c tells makedumpfile command to compress the vmcore file.
o The "d" option is used to set the dump_level.
o "dump_level" is used to decide which pages to be removed from the resultant vmcore file.
o The option is a bit mask, having each page type specified like so:
zero pages = 1
cache pages = 2
cache private = 4
user pages = 8
free pages = 16
47.
Eg:
crash> extend swap_usage.so
./swap_usage.so: shared object loaded
o Use "pswap" command to check swap usage per task.
Eg:
crash> pswap G | sort n k 2 |tail
6946 3099 opcmona
6964 3334 agtrep
30548 9362 R
30575 9377 R
30566 9378 R
30557 9427 R
6123 14284 splunkd
2098 18739 python
19406 164229 rsession
28882 8107112 rsession
[Q:5] How to determine memory usage in kernelspace?
crash> kmem i
PAGES TOTAL PERCENTAGE
TOTAL MEM 4051286 15.5 GB
FREE 33838 132.2 MB 0% of TOTAL MEM
USED 4017448 15.3 GB 99% of TOTAL MEM
SHARED 957 3.7 MB 0% of TOTAL MEM
BUFFERS 58 232 KB 0% of TOTAL MEM
CACHED 900 3.5 MB 0% of TOTAL MEM
SLAB 3954789 15.1 GB 97% of TOTAL MEM
TOTAL SWAP 4194303 16 GB
SWAP USED 249162 973.3 MB 5% of TOTAL SWAP
SWAP FREE 3945141 15 GB 94% of TOTAL SWAP
COMMIT LIMIT 6219946 23.7 GB
COMMITTED 4054963 15.5 GB 65% of TOTAL LIMIT
"kmem s" command displays basic kmalloc() slab data.