Bug 839263
Summary: | cannot set gdb breakpoints on kvm guest | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Stefan Assmann <sassmann> |
Component: | qemu-kvm | Assignee: | Virtualization Maintenance <virt-maint> |
Status: | CLOSED NOTABUG | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | low | Docs Contact: | |
Priority: | unspecified | ||
Version: | 7.0 | CC: | acathrow, areis, bsarathy, dyasny, juzhang, knoel, mkenneth, sluo |
Target Milestone: | pre-dev-freeze | ||
Target Release: | --- | ||
Hardware: | x86_64 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2012-07-12 12:24:06 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Stefan Assmann
2012-07-11 12:06:46 UTC
You may have more luck with hardware breakpoints (hbreak in gdb). Moving to RHEL7: not a high priority and doesn't work on upstream yet. Software breakpoints will not work in the scenario described, since the kernel is loaded after the breakpoints are set. The INT 3 instructions are overwritten by the kernel (well, actually the breakpoints aren't even set correctly because paging is enabled). You'll have better luck with hbreak. You can also use break after the kernel has been loaded, but hbreak will be more reliable. Closing as invalid. Thanks Avi and Ademar! Now gdb stops at the hbreak, but shows the following error. Reading symbols from /home/nfs/rhel6/vmlinux...done. Remote debugging using localhost:1234 0x0000000000000000 in ?? () Hardware assisted breakpoint 1 at 0xffffffff810daaf0: file kernel/irq/manage.c, line 1041. Continuing. kvm: 26628: cpu0 disabled perfctr wrmsr: 0xc1 data 0xabcd Remote 'g' packet reply is too long: 000000000000000096512d81ffffffff800000000000000000000000000000009c4e2c81ffffffff0900000000000000c03d6a070088ffff883d6a070088ffff8fac7781ffffffff9c4e2c81fffffffff017c3060088ffff90000000000000000900000000000000a09476070088ffff01000000000000000000000000000000f0aa0d81ffffffff4602000010000000180000001800000018000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007f0300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000801f0000 (gdb) bt Target is executing. Any clues? This is a longstanding gdb bug, caused by target mode switches. A workaround is to let the guest boot into 64-bit mode, stop it, set the hardware breakpoint, continue the guest, and issue system_reset. |