Update the doc to include the help for rd.kodebug.
Signed-off-by: Xunlei Pang xlpang@redhat.com --- kexec-kdump-howto.txt | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+)
diff --git a/kexec-kdump-howto.txt b/kexec-kdump-howto.txt index f46563f..87f3821 100644 --- a/kexec-kdump-howto.txt +++ b/kexec-kdump-howto.txt @@ -706,4 +706,41 @@ Debugging Tips
Now minicom should be logging serial console in file console-logs.
+- Debug the large memory consumption by kernel modules + + Besides dracut "rd.memdebug=[0-3]" support to debug kdump system memory, + kdump supports a fine-grained memory monitor for kernel modules to help + figure out which kernel module consumes a large amount of memory(the larger, + the more precise the result is). + + One can pass "rd.kodebug" to kdump kernel through "KDUMP_COMMANDLINE_APPEND" + defined in /etc/sysconfig/kdump, touch /etc/kdump.conf, restart kdump, then + the memory consumption information by kernel modules will be printed out to + the console before the vmcore dumping starts. + + As an example, it prints out something below: + == debug_mem for kernel modules during loading begin == + 0 pages consumed by "pata_acpi" [load finished] + 0 pages consumed by "ata_generic" [load finished] + 0 pages consumed by "drm" [load finished] + 1 pages consumed by "ttm" [load finished] + 0 pages consumed by "drm_kms_helper" [load finished] + 834 pages consumed by "qxl" [load finished] + 0 pages consumed by "mii" [load finished] + 5 pages consumed by "8139cp" [load finished] + 0 pages consumed by "8139too" [load finished] + 0 pages consumed by "virtio" [load finished] + 0 pages consumed by "virtio_ring" [load finished] + 10 pages consumed by "virtio_pci" [load finished] + 0 pages consumed by "serio_raw" [load finished] + 0 pages consumed by "crc32c_intel" [load finished] + 199 pages consumed by "virtio_console" [load finished] + 0 pages consumed by "libcrc32c" [load finished] + 8 pages consumed by "xfs" [load finished] + == debug_mem for kernel modules during loading end == + + If you encounters OOM when using the feature, you can enlarge the reserved memory + via "crashkernel" and try again. If you find some kernel module is not included + in the print, you can enlarge the trace buffer via "trace_buf_size"(the default + size set is 5MB in total for all cpus), and try again.