Welcome to MSDN Blogs Sign in | Join | Help

How to attach WinDbg to a service?

There are various ways to do this.

  1. Find the PID for process that is hosting the service. You can do this with the help of command,
    tasklist /svc

    Look for service and associated PID, then go to command prompt, into the directory where windbg is installed and give command,
    windbg.exe -p <ProcessID>
  2. Another way is to directly use the service name as parameter to windbg. This is more convenient way, but hardly known to users/developers. You can use following command,

    windbg.exe -psn RPCSS

    Above command will find out the process which is hosting RPCSS process and then attach the debugger to that process.

Stay tuned.. Wave

Published Saturday, October 27, 2007 9:19 AM by Jigar Mehta
Filed under: ,

Comments

# MSDN Blog Postings &raquo; How to attach WinDbg to a service?

Saturday, October 27, 2007 2:16 AM by MSDN Blog Postings » How to attach WinDbg to a service?

# re: How to attach WinDbg to a service?

Here is a KB article that has few other options to attach windbg to a service.

http://support.microsoft.com/kb/824344

Wednesday, November 07, 2007 6:24 PM by jigarme@live.com
Anonymous comments are disabled
 
Page view tracker