network access for symbols as localsystem

This is a “talking to myself” message type. Read on if you have some time to
loose :slight_smile:

I’m using WinDBG to debug a service.

Under [HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File
Execution Options\MyExe.exe]
I set up Debugger=“C:\program files\debugging tools for windows\windbg.exe”

Everythings works fine, when I start my service, WinDBG starts and breaks
in.

Now, here my problems start. I want to access my symbols on a symbol server
throughout a share:
.sympath SRV*\server\share*http://msdl.microsoft.com/download/symbols

Since WinDBG is running as a NT AUTHORITY\SYSTEM, it can’t access the
network.

I prefer to not attach and still test my program as a service. Don’t want to
hardcode a breakpoint on start. I can’t log on the service as a user since
it needs interactive access to be debugged.

Just for the logs, I found out the solution while writing. (if it can help a
googler)
Simply connect the drive with the right credentials. Either simply run
.shell net use \server\share /user:domain\user password
and then .reload /f

*or* I coud have read the documentation too and see that there is a File |
Map Network Drive … command in WinDBG…

So I can delete my share with the menus… Furthermore, the .shell command
is done on the server, not on the client which isn’t great on remote debug,
which would have solved my problem too! i.e. use dbgsrv.exe instead of
windbg.exe and attach to the server with windbg…

It did my day!

I’m still wondering why it took me so much time to find all this out…

Marc-Antoine Ruel