Issues with 2 VM kernel debug

Ok, so I know this is a weird setup, but I’m a Linux guy who’s recently gotten into kernel programming. And it seems like my issue is specific to the debug stub in the Win 7 kernel.

Here’s my setup:
Host OS: Ubuntu 9.10 Linux
Virt: VirtualBox 3.2 (had same behavior on 3.1)
Debug VM: Windows XP
Target VM: Win 7

I have the two VMs hooked up with a host pipe serial port that works great when both VMs are up normally. I run TeraTerm and they talk back and forth, I can even paste in a whole lot of data and it seems to go pretty quickly.

However, when I start up the Win 7 VM in Debug mode, it connects, but the connection is terribly slow and the Win 7 VM process is taking up 100% of one of the CPUs (it normally does this on boot though). I can monitor the data going through the virtual serial connection, and it looks like there are 3 or 4 second pauses in between bursts of data. It takes about a half an hour to get the “Connected to Windows 7 host…” message, but it eventually does come up and I can break in, but it’s still awfully slow. I’ve set the VirtualBox option to yield the CPU while polling serial for both VMs, but that didn’t help.

Anybody have any ideas?

Thanks,
Justin

  1. Are you seeing lots of traces?

  2. I’m a little confused by what you mean by ‘Debug VM?’ I assume that
    that’s the ‘host’ in windbg terminology (where windbg is running). Do you
    mean that you’re running a CHK build there when you say ‘Debug?’ I assume
    not, but if you are, that’s not going to help.

  3. I’ve only used a setup like this once or twice and it is to be sure
    quite slow, though not as slow as you are reporting, at least as I recall.

  4. What sort of hardware are you running on the Ubuntu box? In particular,
    how much memory?

  5. I would recommend enabling protocol debugging (CTRL+ALT+D) and see if
    can provide any more information about what’s going over the line. If you
    try this, you might want to post the output.

  6. Though I don’t think that this will solve your problem proper, given
    that you’re using Virtual Box (or if you were using VMWare workstation, for
    that matter), I would DEFINITELY recommend that you take a look at
    VirtualKD:

http://virtualkd.sysprogs.org/

It rocks, all around. In my opinion, it’s the best windbg transport/setup
going, so I use it whenever I can (if you’re dealing with drivers for actual
hardware (with perhaps a couple of exceptions), you can’t use it). I assume
that it will work in a 2 VM setup, and if it does, it will greatly increase
the speed of debugging.

Good luck,

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Monday, June 28, 2010 10:55 AM
To: Kernel Debugging Interest List
Subject: [windbg] Issues with 2 VM kernel debug

Ok, so I know this is a weird setup, but I’m a Linux guy who’s recently
gotten into kernel programming. And it seems like my issue is specific to
the debug stub in the Win 7 kernel.

Here’s my setup:
Host OS: Ubuntu 9.10 Linux
Virt: VirtualBox 3.2 (had same behavior on 3.1) Debug VM: Windows XP Target
VM: Win 7

I have the two VMs hooked up with a host pipe serial port that works great
when both VMs are up normally. I run TeraTerm and they talk back and forth,
I can even paste in a whole lot of data and it seems to go pretty quickly.

However, when I start up the Win 7 VM in Debug mode, it connects, but the
connection is terribly slow and the Win 7 VM process is taking up 100% of
one of the CPUs (it normally does this on boot though). I can monitor the
data going through the virtual serial connection, and it looks like there
are 3 or 4 second pauses in between bursts of data. It takes about a half
an hour to get the “Connected to Windows 7 host…” message, but it
eventually does come up and I can break in, but it’s still awfully slow.
I’ve set the VirtualBox option to yield the CPU while polling serial for
both VMs, but that didn’t help.

Anybody have any ideas?

Thanks,
Justin


WINDBG is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

mm, thanks for getting back to me.

Here’s some answers to your questions:

  1. I’m not sure what you mean by traces? If you mean traffic over the serial connection then yes, I am.

  2. Yeah, by “Debug VM” I mean “host” where WinDbg is running. It’s the release build of XP.

  3. Core 2 Duo 2.26 GHz, 4GB RAM (can definitely handle multiple VMs)

  4. See the attached output from the protocol debugging below. Looks like a lot of ACK timeouts? That seems to be corresponding to the regular 3-4 second pause I was seeing on the serial traffic.

  5. I’ve heard about VirtualKD and that’s probably what I would’ve gone with if I’d started from scratch. Unfortunately I’m trying to get this working for a class next week.

Output from protocol debugging:

Microsoft (R) Windows Debugger Version 6.12.0002.633 X86
Copyright (c) Microsoft Corporation. All rights reserved.

Opened \.\com1
Waiting to reconnect…
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
Throttle 0x10 write to 0x1
SYNCTARGET: Received KD_RESET ACK packet.
SYNCTARGET: Target synchronized successfully…
Done.
READ: Wait for type 7 packet
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Packet type = 7, KdApi64 = 1
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Data packet with unmatched ID = 80800000 (expected 80800001), acking
Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
PacketType=5, ByteCount=0, PacketId=1835cf,
READ: Received RESEND packet
READ: Target requests resend.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800000,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=38, PacketId=80800001,
READ: Received Type 2 data packet with id = 80800001 successfully.

DbgKdGetVersion returns 00000000
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=38, PacketId=80800001,
READ: Received Data packet with unmatched ID = 80800001 (expected 80800000), acking
Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800001,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=3c, PacketId=80800000,
READ: Received Type 2 data packet with id = 80800000 successfully.

KdReadVirtual(82b6afec, 4) returns 00000000, 4

>>>>>>> LiveKernelTargetInfo::InitFromKdVersion(0xFFFFFFFF82928BE8,0xFFFFFFFF82928BE8)
Target MajorVersion 0000000f
Target MinorVersion 00001db0
Target ProtocolVersion 00000006
Target KdSecondaryVersion 00000000
Target Flags 00000003
Target MachineType 0000014c
Target MaxPacketType c
Target MaxStateChange 3
Target MaxManipulate 2f
Target KernBase 82808000
Target PsLoadedModuleList 82947570
Target DebuggerDataList 82b6afec
Connected to Windows 7 7600 x86 compatible target at (Mon Jun 28 12:08:54.206 2010 (UTC - 4:00)), ptr64 FALSE
>> State change event 3031, proc 0 of 1, str ‘\SystemRoot\system32\ntoskrnl.exe’
Kernel Debugger connection established.
Symbol search path is: C:\WINDOWS\symbols\Windows7
Executable search path is:
>>>>>>> TargetInfo::ReadKdDataBlock(0xFFFFFFFF82928BE8,0xFFFFFFFF82928BE8)
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=3c, PacketId=80800000,
READ: Received Data packet with unmatched ID = 80800000 (expected 80800001), acking
Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800000,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=50, PacketId=80800001,
READ: Received Type 2 data packet with id = 80800001 successfully.

KdReadVirtual(82928be8, 18) returns 00000000, 18
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=50, PacketId=80800001,
READ: Received Data packet with unmatched ID = 80800001 (expected 80800000), acking
Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800001,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=360, PacketId=80800000,
READ: Received Type 2 data packet with id = 80800000 successfully.

KdReadVirtual(82928c00, 328) returns 00000000, 328
ReadKdDataBlock 00000000
KernBase 82808000
BreakpointWithStatus 82860bc0
SavedContext 00000000
ThCallbackStack 00000130
NextCallback 00000008
FramePointer 00000018
PaeEnabled 00000000
KiCallUserMode 82864de0
KeUserCallbackDispatcher 00000000
PsLoadedModuleList 82947570
PsActiveProcessHead 82940658
MmPageSize 00001000
MmLoadedUserImageList 82947b58
MmSystemRangeStart 82967700
KiProcessorBlock 82967840
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=360, PacketId=80800000,
READ: Received Data packet with unmatched ID = 80800000 (expected 80800001), acking
Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800000,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=13d, PacketId=80800001,
READ: Received Type 2 data packet with id = 80800001 successfully.

KdReadVirtual(8284a468, 105) returns 00000000, 105
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=13d, PacketId=80800001,
READ: Received Data packet with unmatched ID = 80800001 (expected 80800000), acking
Throttle 0x10 write to 0x1
READ: Received INVALID packet type.
Throttle 0x10 write to 0x1
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received VALID data packet 80800000while waiting for ACK.
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Data packet instead of ack, stored.
READ: Wait for type 2 packet
READ: Grab packet from buffer.
READ: Unexpected Packet type 7 (Acked). Expecting Packet type 2
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
READ: Timeout.
WRITE: Write type 2 packet
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet

  1. I mean trace statements - debug information showing up in windbg

  2. Indeed, not good, but I need to look at it more closely first.

  3. For what it’s worth, if you’re using VMWare, VirtualKD is VERY easy to
    get working and makes your kd life MUCH more pleasant; that being said, I’ve
    never used it with VirtualBox.

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Monday, June 28, 2010 12:26 PM
To: Kernel Debugging Interest List
Subject: RE:[windbg] Issues with 2 VM kernel debug

mm, thanks for getting back to me.

Here’s some answers to your questions:

  1. I’m not sure what you mean by traces? If you mean traffic over the
    serial connection then yes, I am.

  2. Yeah, by “Debug VM” I mean “host” where WinDbg is running. It’s the
    release build of XP.

  3. Core 2 Duo 2.26 GHz, 4GB RAM (can definitely handle multiple VMs)

  4. See the attached output from the protocol debugging below. Looks like a
    lot of ACK timeouts? That seems to be corresponding to the regular 3-4
    second pause I was seeing on the serial traffic.

  5. I’ve heard about VirtualKD and that’s probably what I would’ve gone with
    if I’d started from scratch. Unfortunately I’m trying to get this working
    for a class next week.

Output from protocol debugging:

Microsoft (R) Windows Debugger Version 6.12.0002.633 X86 Copyright (c)
Microsoft Corporation. All rights reserved.

Opened \.\com1
Waiting to reconnect…
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
SYNCTARGET: Timeout.
Throttle 0x10 write to 0x1
Throttle 0x10 write to 0x1
SYNCTARGET: Received KD_RESET ACK packet.
SYNCTARGET: Target synchronized successfully…
Done.
READ: Wait for type 7 packet
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Packet type = 7, KdApi64 = 1
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Data packet with unmatched ID = 80800000 (expected 80800001),
acking Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
PacketType=5, ByteCount=0, PacketId=1835cf,
READ: Received RESEND packet
READ: Target requests resend.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800000,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=38, PacketId=80800001,
READ: Received Type 2 data packet with id = 80800001 successfully.

DbgKdGetVersion returns 00000000
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=38, PacketId=80800001,
READ: Received Data packet with unmatched ID = 80800001 (expected 80800000),
acking Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800001,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=3c, PacketId=80800000,
READ: Received Type 2 data packet with id = 80800000 successfully.

KdReadVirtual(82b6afec, 4) returns 00000000, 4

>>>>>>> LiveKernelTargetInfo::InitFromKdVersion(0xFFFFFFFF82928BE8,0xFF
>>>>>>> FFFFFF82928BE8)
Target MajorVersion 0000000f
Target MinorVersion 00001db0
Target ProtocolVersion 00000006
Target KdSecondaryVersion 00000000
Target Flags 00000003
Target MachineType 0000014c
Target MaxPacketType c
Target MaxStateChange 3
Target MaxManipulate 2f
Target KernBase 82808000
Target PsLoadedModuleList 82947570
Target DebuggerDataList 82b6afec
Connected to Windows 7 7600 x86 compatible target at (Mon Jun 28
12:08:54.206 2010 (UTC - 4:00)), ptr64 FALSE
>> State change event 3031, proc 0 of 1, str
‘\SystemRoot\system32\ntoskrnl.exe’
Kernel Debugger connection established.
Symbol search path is: C:\WINDOWS\symbols\Windows7 Executable search path
is:
>>>>>>> TargetInfo::ReadKdDataBlock(0xFFFFFFFF82928BE8,0xFFFFFFFF82928B
>>>>>>> E8)
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=3c, PacketId=80800000,
READ: Received Data packet with unmatched ID = 80800000 (expected 80800001),
acking Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800000,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=50, PacketId=80800001,
READ: Received Type 2 data packet with id = 80800001 successfully.

KdReadVirtual(82928be8, 18) returns 00000000, 18
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=50, PacketId=80800001,
READ: Received Data packet with unmatched ID = 80800001 (expected 80800000),
acking Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800001,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=360, PacketId=80800000,
READ: Received Type 2 data packet with id = 80800000 successfully.

KdReadVirtual(82928c00, 328) returns 00000000, 328 ReadKdDataBlock 00000000
KernBase 82808000
BreakpointWithStatus 82860bc0
SavedContext 00000000
ThCallbackStack 00000130
NextCallback 00000008
FramePointer 00000018
PaeEnabled 00000000
KiCallUserMode 82864de0
KeUserCallbackDispatcher 00000000
PsLoadedModuleList 82947570
PsActiveProcessHead 82940658
MmPageSize 00001000
MmLoadedUserImageList 82947b58
MmSystemRangeStart 82967700
KiProcessorBlock 82967840
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=360, PacketId=80800000,
READ: Received Data packet with unmatched ID = 80800000 (expected 80800001),
acking Throttle 0x10 write to 0x1
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
PacketType=4, ByteCount=0, PacketId=80800000,
READ: Received correct ACK packet.
READ: Wait for type 2 packet
PacketType=2, ByteCount=13d, PacketId=80800001,
READ: Received Type 2 data packet with id = 80800001 successfully.

KdReadVirtual(8284a468, 105) returns 00000000, 105
WRITE: Write type 2 packet
READ: Wait for ACK packet
PacketType=2, ByteCount=13d, PacketId=80800001,
READ: Received Data packet with unmatched ID = 80800001 (expected 80800000),
acking Throttle 0x10 write to 0x1
READ: Received INVALID packet type.
Throttle 0x10 write to 0x1
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received VALID data packet 80800000while waiting for ACK.
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Data packet instead of ack, stored.
READ: Wait for type 2 packet
READ: Grab packet from buffer.
READ: Unexpected Packet type 7 (Acked). Expecting Packet type 2
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
PacketType=7, ByteCount=112, PacketId=80800000,
READ: Received Type 7 data packet with id = 80800000 successfully.

READ: Unexpected Packet Id (Acked).
READ: Timeout.
WRITE: Write type 2 packet
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x38 write to 0x32
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet
READ: Timeout.
WRITE: Wait for ACK failed. Resend Packet.
Throttle 0x10 write to 0x1
Throttle 0x38 write to 0x1
READ: Wait for ACK packet


WINDBG is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

I think VirtualKD is Windows only though, right? I assumed I was disqualified since my host OS is Linux.

You would run it the ‘host’ vm (XP).

mm
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Monday, June 28, 2010 12:55 PM
To: Kernel Debugging Interest List
Subject: RE:[windbg] Issues with 2 VM kernel debug

I think VirtualKD is Windows only though, right? I assumed I was
disqualified since my host OS is Linux.


WINDBG is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Ignore me - you’re right. No VirtualKD for you. What I said doesn’t make
any sense.

Sorry about that.

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Monday, June 28, 2010 12:55 PM
To: Kernel Debugging Interest List
Subject: RE:[windbg] Issues with 2 VM kernel debug

I think VirtualKD is Windows only though, right? I assumed I was
disqualified since my host OS is Linux.


WINDBG is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Partial success - I think

Looks like there is an ongoing issue with serial port emulation in VirtualBox, see here:
http://www.virtualbox.org/ticket/1548

In the above traffic it looks like WinDbg is waiting for acks which timeout, and then it sends a retry, and repeats, and then finally the packet comes through, along with a whole bunch of unexpected ACKs. So basically its buffering reads.

So in Device Manager on the WinDbg VM, I set COM1 to not use FIFO buffers, and this seemed to speed things up a bit, now there are only 1-2 second pauses in the connection instead of 3-4.

My guess is that the KD stub in Win 7 is also buffering reads. I’ve set COM1 to not use buffers, but I’m guessing that KD uses its own pre-boot serial driver. Is there any way to set it to not buffer?

Kd does use it’s own driver(s), and as far as I know there is no way to
configure them in any way, other than of course the connection parameters.

On that note, what’s the windbg command line you are using to connect to the
target? In particular, are you using the ‘resets=0’ option?

mm

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Monday, June 28, 2010 2:16 PM
To: Kernel Debugging Interest List
Subject: RE:[windbg] Issues with 2 VM kernel debug

Partial success - I think

Looks like there is an ongoing issue with serial port emulation in
VirtualBox, see here:
http://www.virtualbox.org/ticket/1548

In the above traffic it looks like WinDbg is waiting for acks which timeout,
and then it sends a retry, and repeats, and then finally the packet comes
through, along with a whole bunch of unexpected ACKs. So basically its
buffering reads.

So in Device Manager on the WinDbg VM, I set COM1 to not use FIFO buffers,
and this seemed to speed things up a bit, now there are only 1-2 second
pauses in the connection instead of 3-4.

My guess is that the KD stub in Win 7 is also buffering reads. I’ve set
COM1 to not use buffers, but I’m guessing that KD uses its own pre-boot
serial driver. Is there any way to set it to not buffer?


WINDBG is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Can windbg run under Wine? then you could drop one VM.

–pa

wrote in message news:xxxxx@windbg…
> Partial success - I think
>
> Looks like there is an ongoing issue with serial port emulation in
> VirtualBox, see here:
> http://www.virtualbox.org/ticket/1548
>
> In the above traffic it looks like WinDbg is waiting for acks which
> timeout, and then it sends a retry, and repeats, and then finally the
> packet comes through, along with a whole bunch of unexpected ACKs. So
> basically its buffering reads.
>
> So in Device Manager on the WinDbg VM, I set COM1 to not use FIFO buffers,
> and this seemed to speed things up a bit, now there are only 1-2 second
> pauses in the connection instead of 3-4.
>
> My guess is that the KD stub in Win 7 is also buffering reads. I’ve set
> COM1 to not use buffers, but I’m guessing that KD uses its own pre-boot
> serial driver. Is there any way to set it to not buffer?
>