From Fedora Project Wiki
No edit summary |
No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 8: | Line 8: | ||
#Apply changes and start kdump via service kdump restart | #Apply changes and start kdump via service kdump restart | ||
|actions= | |actions= | ||
{{admon/note|Download crash-simple.cmd and crash.cmd at|http://hongqing.fedorapeople.org/script/crash-simple.cmd http://hongqing.fedorapeople.org/script/crash.cmd}} | |||
#Trigger crash via:<pre>echo c > /proc/sysrq-trigger</pre> | #Trigger crash via:<pre>echo c > /proc/sysrq-trigger</pre> | ||
#Analyse vmcore:<pre>readelf -a /var/crash/xxx/vmcore</pre><pre>objdump -x /var/crash/xxx/vmcore</pre><pre>eu-readelf -a /var/crash/xxx/vmcore</pre> | #Analyse vmcore:<pre>readelf -a /var/crash/xxx/vmcore</pre><pre>objdump -x /var/crash/xxx/vmcore</pre><pre>eu-readelf -a /var/crash/xxx/vmcore</pre> | ||
Line 17: | Line 18: | ||
#vmcore was found under path /var/crash/xxx/vmcore | #vmcore was found under path /var/crash/xxx/vmcore | ||
#readelf should return 0, and no "warning" "warnings" found on output | #readelf should return 0, and no "warning" "warnings" found on output | ||
##objdump should return 0 | |||
##eu-readelf should return 0 | |||
#No warning or error should be should found on crash output | #No warning or error should be should found on crash output | ||
#No warning or error should be should found on gdb output | #No warning or error should be should found on gdb output | ||
}} | }} | ||
[[Category:Kdump_Test_Cases]] | [[Category:Kdump_Test_Cases]] |
Latest revision as of 08:40, 26 March 2012
Description
Setup
- Install Fedora 17 on your machine
- After system installed, check if kexec-tools kernel-debuginfo and crash is installed via
rpm -q kexec-tools kernel-debuginfo crash
Or via yumyum install kexec-tools kernel-debuginfo crash
- Reserve crashkernel for kdump by grubby
grubby --args="crashkernl=128M" --update-kernel=$(grubby --default-kernel)
Reboot system and check /proc/cmdlinecat /proc/cmdline | grep "crashkernel"
- Edit /etc/kdump.conf, add this line:
ext4 /dev/mapper/vg_dhcp6558-lv_root
core_collector makedumpfile -E -d 31
- Apply changes and start kdump via service kdump restart
How to test
- Trigger crash via:
echo c > /proc/sysrq-trigger
- Analyse vmcore:
readelf -a /var/crash/xxx/vmcore
objdump -x /var/crash/xxx/vmcore
eu-readelf -a /var/crash/xxx/vmcore
- Use crash to analyse vmcore:
crash -i crash-simple.cmd /usr/lib/debug/lib/modules/xxx/vmlinux /var/crash/xxx/vmcore
crash -i crash.cmd /usr/lib/debug/lib/modules/xxx/vmlinux /var/crash/xxx/vmcore
- Use gdb to analyse vmcore:
gdb -x gdb.cmd /usr/lib/debug/lib/modules/xxx/vmlinux /var/crash/xxx/vmcore
Expected Results
- Dump process could be monitered if console is connected
- System reboot successfully after dump vmcore finshed
- vmcore was found under path /var/crash/xxx/vmcore
- readelf should return 0, and no "warning" "warnings" found on output
- objdump should return 0
- eu-readelf should return 0
- No warning or error should be should found on crash output
- No warning or error should be should found on gdb output