The Windows Debugging Tools are an industry-standard toolkit for debugging Windows applications. Instead of re-inventing the wheel, the LeanSentry Agent uses the Windows Debugging tools to conduct some of its diagnostics.
NOTE: We recommend that you install Windows Debugging Tools on your servers ahead of time, so that LeanSentry can perform diagnostics should you ever need them in the future.
Why does LeanSentry use Windows Debugging Tools?
The Windows Debugging Tools are developed and supported by Microsoft, and have been actively used by hundreds of thousands of IT and developer professionals worldwide for over a decade. They are the most stable, well-understood, and frequently used tools for production-grade debugging.
Because even the best third party profilers and debugging technologies often cause production problems, LeanSentry relies on the Windows Debugging Tools to perform safe production troubleshooting when a deeper analysis is needed.
LeanSentry currently uses the Windows Debugging tools for: memory diagnostics, crash diagnostics (upcoming feature), advanced debugging (upcoming feature).
What do I need to do?
Simply make sure the Windows Debugging Tools are installed on the server. The LeanSentry Agent will automatically use them when performing certain diagnostics, in accordance with diagnostic settings you configure in LeanSentry.
NOTE: The Windows Debugging Tools do not run on their own, and will not perform any undesired actions on their own.
How do I install the Windows Debugging Tools?
1. Download them from the Microsoft Windows SDK site:
- For most cases, including ASP.NET CORE applications, download from the latest Windows 10 SDK:
https://docs.microsoft.com/en-us/windows-hardware/drivers/debugger/debugger-download-tools
Older downloads:
- For Windows Server 2008, Windows 7 SDK: https://www.microsoft.com/en-us/download/details.aspx?id=8279
- For Windows Server 2012+, Windows 8 SDK: https://msdn.microsoft.com/en-us/windows/hardware/hh852365
.
2. When installing, be sure to select only the Windows Debugging Tools:
WARNINGs:
- To make sure you do not install more than necessary, be sure to uncheck the other components. Particularly be sure to uncheck .NET Framework 4.5.1 to avoid installing an update to the .NET framework.
- It is strongly recommended to install to the default location. If changing the location, follow the instructions below to configure the LeanSentry Agent to find the debuggers.
3. That's it. After installation, The LeanSentry Agent should automatically detect the debuggers within a few minutes.
If you installed the debuggers in the default location, no additional actions are necessary.
If you installed the debuggers in a custom location, OR, the Agent is having trouble finding them, you can manually configure the path to the debuggers as follows:
1. Open/create the preferences.config file in c:\leanserver\sentinelagent.
2. Provide the paths to 32 bit and 64 bit ntsd.exe in the debuggers' installed directory by setting the debuggerLocation64 and debuggerLocation32 settings as follows:
<?xml version="1.0" encoding="utf-8"?> <configuration> <appSettings> <add key="debuggerLocation64" value="C:\Program Files (x86)\Windows Kits\8.1\Debuggers\x64\ntsd.exe" /> <add key="debuggerLocation32" value="C:\Program Files (x86)\Windows Kits\8.1\Debuggers\x86\ntsd.exe" /> </appSettings> </configuration>
3. After this is done, the Agent should pick up the changes within several minutes. To apply the changes immediately, restart the LeanSentry Agent service.
Deploying the Windows Debugging tools automatically
NOTE: LeanSentry now supports automatically deploying Windows Debuggers from a publicly accessible url (a file URL from your website). You can configure this in your environment settings after deploying LeanSentry.
Steps:
1. Download the debugger MSIs from Microsoft (see article).
2. Place the MSIs on a publicly available url (we recommend keeping the url secret, do not use file sharing websites).
3. Configure the debugger urls in your environment settings/Other tab.
Comments
0 comments
Article is closed for comments.