Daniel Castro
2011-Jul-27 03:53 UTC
[Xen-devel] Help debugging domain builder, qemu upstream and hvmloader
Hello All, I run into this problem when I modify seabios. (XEN) hvm.c:1131:d13 Triple fault on VCPU 0 - invoking HVM system reset. Since there is no fault handlers in the early stages of guest boot I am in the need to debug the domain builder, upstream qemu and/or hvmloader to see where exactly the fault is being generated. I have no experience on debugging and this seems like a good time to start. Any pointers, or guides anyone can provide me will be of great help. After this I will document the process for later uses. PD: Xen is compiled with debugging on, so is qemu and seabios. Thanks, Daniel -- +-=====---------------------------+ | +---------------------------------+ | This space intentionally blank for notetaking. | | | Daniel Castro, | | | | Consultant/Programmer.| | | | U Andes | +-------------------------------------+ _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2011-Jul-27 07:15 UTC
Re: [Xen-devel] Help debugging domain builder, qemu upstream and hvmloader
On 27/07/2011 04:53, "Daniel Castro" <evil.dani@gmail.com> wrote:> Hello All, > > I run into this problem when I modify seabios. > (XEN) hvm.c:1131:d13 Triple fault on VCPU 0 - invoking HVM system reset. > > Since there is no fault handlers in the early stages of guest boot I > am in the need to debug the domain builder, upstream qemu and/or > hvmloader to see where exactly the fault is being generated.You can put ''on_reboot = preserve'' in your domain config file so that the crashed domain is not automatically destroyed and restarted. Then you can use the tool xenctx to grab the register state including crashing EIP value. -- Keir> I have no experience on debugging and this seems like a good time to start. > > Any pointers, or guides anyone can provide me will be of great help. > After this I will document the process for later uses. > > PD: Xen is compiled with debugging on, so is qemu and seabios. > > Thanks, > > Daniel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Wei Liu
2011-Jul-27 07:44 UTC
Re: [Xen-devel] Help debugging domain builder, qemu upstream and hvmloader
On Wed, 2011-07-27 at 12:53 +0900, Daniel Castro wrote:> Hello All, > > I run into this problem when I modify seabios. > (XEN) hvm.c:1131:d13 Triple fault on VCPU 0 - invoking HVM system reset. > > Since there is no fault handlers in the early stages of guest boot I > am in the need to debug the domain builder, upstream qemu and/or > hvmloader to see where exactly the fault is being generated. > > I have no experience on debugging and this seems like a good time to start.Ian Campbell once mentioned his trick to debug QEMU (following paragraphs quoted from his email): ====================================================================When I have an issue with qemu I often specify the device model in my guest configuration as a script containing: echo $@ > /tmp/qemu-dm sleep 1h Then immediately after running "xl create" I can examine /tmp/qemu-dm and run the qemu by hand in the foreground, or under gdb etc. (there is a timeout in xl waiting for qemu to announce itself so you need to be reasonably prompt...) ==================================================================== Wei. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Wei Liu
2011-Jul-27 10:11 UTC
Re: [Xen-devel] Help debugging domain builder, qemu upstream and hvmloader
Adding @xen-devel back in CC list. On Wed, 2011-07-27 at 18:53 +0900, Daniel Castro wrote:> > Ian Campbell once mentioned his trick to debug QEMU (following > > paragraphs quoted from his email): > > > > ====================================================================> > When I have an issue with qemu I often specify the device model in my > > guest configuration as a script containing: > > echo $@ > /tmp/qemu-dm > > sleep 1h > > > > Then immediately after running "xl create" I can examine /tmp/qemu-dm > > and run the qemu by hand in the foreground, or under gdb etc. (there is > > a timeout in xl waiting for qemu to announce itself so you need to be > > reasonably prompt...) > > ====================================================================> > Works perfectly, now I need to learn how to use gdb. Any good document > comes to mind? >Google helps a lot. GDB manual is the best document I know. Wei. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Reasonably Related Threads
- Bug#737905: Xen: hvmloader causes immediate VCPU triple fault with SeaBIOS 1.7.4
- [PATCH RFC] hvmloader: Make ROM dependencies optional
- [PATCH v2 0/3] hvmloader: Make ROM dependencies optional
- [PATCH] hvmloader: fix SeaBIOS interface
- 4.3.0-3 fresh build - hvmloader Triple fault on VCPU0