Debuggers don't stop to breakpoints anymore
Posted: Tue Jun 15, 2010 3:43 am
Hi guys, I have a really absurd issue with ALL my virtual machines + gdb..
I have been working for years with qemu + gdb, and it worked perfectly, two days ago it started missing breakpoints..
I use NO kvm, start qemu with: "qemu -s -S -m 16 -hda image.img", then start gdb and connect to the process.
I only set one breakpoint to 0x7c00 (with the command "b *0x7c00") and press 'c'. It starts running, gdb stops to 0x7c00 but qemu keeps running.... When i step one instruction forward with gdb, it jumps to 0x000000a0 but it is not possible since the instruction at 0x7c00 is a MOV and the disassemble at that point shows the source correctly...
I thought was a qemu issue, so downloaded bochs.. Other strange thing: I start bochs, then run gdb and connect, set the bpoint and continue.. It recieves a SIGTRAP to 0x000e0000 (at which there is a code that is not mine..obviously..). If i continue again, the boot code is executed correctly but the breakpoint is never hit.
The problem is not in the source code since I edited/re-wrote it and even substituted it with a newly created 'hello world' boot code..
I'm starting to get mad..
I use:
Ubuntu 10.04 LTS
Kernel 2.6.32-22-generic
qemu 0.12.3 NO KVM
gdb 7.1
I have been working for years with qemu + gdb, and it worked perfectly, two days ago it started missing breakpoints..
I use NO kvm, start qemu with: "qemu -s -S -m 16 -hda image.img", then start gdb and connect to the process.
I only set one breakpoint to 0x7c00 (with the command "b *0x7c00") and press 'c'. It starts running, gdb stops to 0x7c00 but qemu keeps running.... When i step one instruction forward with gdb, it jumps to 0x000000a0 but it is not possible since the instruction at 0x7c00 is a MOV and the disassemble at that point shows the source correctly...
I thought was a qemu issue, so downloaded bochs.. Other strange thing: I start bochs, then run gdb and connect, set the bpoint and continue.. It recieves a SIGTRAP to 0x000e0000 (at which there is a code that is not mine..obviously..). If i continue again, the boot code is executed correctly but the breakpoint is never hit.
The problem is not in the source code since I edited/re-wrote it and even substituted it with a newly created 'hello world' boot code..
I'm starting to get mad..
I use:
Ubuntu 10.04 LTS
Kernel 2.6.32-22-generic
qemu 0.12.3 NO KVM
gdb 7.1