1. Go to My Computer --> Properties --> Advanced --> Settings under Startup and Recovery --> Edit
2. You should see a line that is something like 'multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /fastdetect /NoExecute=OptIn'
3. You will need to add '/DEBUG /DEBUGPORT=COM1' to the end of this line
4. Once you have done all of this you should shut down the virtual machine
Now you will need to download the debugging tools from: http://www.microsoft.com/whdc/devtools/debugging/installx86.mspx and either install them on your host computer, or in a second virtual machine (depending on where you want to debug from).
Once you have done this you will need to do the following:
1. For host based debugging run "kd -y SRV*c:\websymbols*http://msdl.microsoft.com/download/symbols -k com:pipe,port=\\.\pipe\debugPipe,resets=0,reconnect" and then launch your target virtual machine.
2. For virtual machine based debugging run "kd -y SRV*c:\websymbols*http://msdl.microsoft.com/download/symbols -k com:port=com1" and then launch your target virtual machine.
Once the target virtual machine starts to boot - the debugger should connect and you will be good to go.
Cheers,
Ben
Note: To install the .msi file use this syntax msiexec /i filename.msi.
Reference: Virtual PC Guy, 2009. Kernel debugging Windows XP inside of a virtual machine. http://blogs.msdn.com/virtual_pc_guy/archive/2005/10/20/482413.aspx
No comments:
Post a Comment