Microsoft KB Archive/137238

{|
 * width="100%"|

-

The information in this article applies to:


 * Microsoft Windows NT 3.1
 * Microsoft Windows NT Advanced Server, version 3.1
 * Microsoft Windows NT Workstation versions 3.5, 3.51
 * Microsoft Windows NT Server versions 3.5, 3.51
 * Microsoft LAN Manager, versions 2.2b, 2.2c

-

SUMMARY
Windows NT debugging capabilities save your business from long server-down times and give you quicker turn-around times for bug fixes. This article discusses the advantages Windows NT provides for debugging support and compares them with the debugging capabilities of LAN Manager for OS/2.

MORE INFORMATION
Windows NT offers the following advantages over LAN Manager in regards to kernel mode and user mode debugging:

Pre-Problem (STOP Error or System Hanging, Etc.) Preparation and Effects on Performance

Windows NT pre-problem preparation for the problem (target) computer:


 * Windows NT requires little or no pre-problem setup on the target computer for debugging depending on which version of Windows NT you are running and what type of problem you are debugging or want to prepare for.

There are different types of debugging options that can be configured with Windows NT startup switches. You may set these startup options in the BOOT.INI file on I386 computers, through the Setup menu on MIPS RISC-based computers, or through the Supplementary Menu on Digital Alpha AXP RISC-based computers. More information about debug switches is provided below.
 * Windows NT does not require that you install a debug kernel (the startup switches enable the debug kernel)
 * Windows NT does not require that you install the symbols on the target server. (The symbols provide the debugger with function names and global variable names, and enable the debugger to locate those functions and variables in the executable image.) The symbols can be located on the host computer which may be the computer of a consultant or support professional. (The host is the computer that you use to debug and initiate requests to the target computer being debugged.)
 * In Windows NT 3.5 and 3.51, if you enable the /CrashDebug switch to debug STOP messages (in Windows NT 3.1 it is enabled by default), there is no performance degradation. If you enable the /Debug switch to debug system hanging problems, for example, there is no performance degradation, unless a debug event such as a breakpoint occurs on the target computer or unless you break in from the host computer and execute commands.

For additional information on how to set certain startup switches on your MIPS or I386 computer, see the Windows NT 3.5 Resource Kit, Volume 3, pages 36 - 40.

LAN Manager pre-problem preparation on target computer:


 * You must install the debug kernel on the target server before the problem occurs.
 * You must install the symbols on the target server before a problem occurs.
 * The debug kernel slows down the server performance noticeably. Because of performance degradation, you must replace the debug kernel with the regular kernel after the problem has been debugged.

Dynamic Versus Non-Dynamic Loading of Symbols

In Windows NT, you can dynamically load and unload symbols during a debug session.

In LAN Manager, you cannot dynamically load symbols because they must be loaded at boot time. Therefore, if you fail to install the correct symbols, or if you fail to install any symbols, very little or no debugging can be done until you install the correct symbols, reboot the computer, and reproduce the problem.

Location of Symbol Files

In Windows NT debugging sessions, you may copy the symbol files to any location accessible by the host debugger.

NOTE: You may create symbol trees for various configurations on a symbol server, to which the host debuggers can connect during debug sessions. Maintaining symbol trees for various configurations may be useful if you maintain multiple standard configurations. For example, if you have any Windows NT Service Pack fixes, hot fixes, or Compaq Support Software Diskette (SSD) fixes installed, you must load a combination of the base build symbols and the symbols for the fixes.

In LAN Manager debugging sessions, the symbol files may reside only on the target server. This may cause disk space problems and may require you to delete the files after the debug is done. Supported Debugger Programs (Debuggers)

Windows NT supports multiple smart debuggers on the host debugger, some of which are graphical debuggers. The primary debuggers that you may use to debug kernel mode or user mode exceptions are the following:


 * Microsoft Windows NT Kernel Debugger (The executable file names indicate the computer processor for which they are used: I386KD.EXE, MIPSKD.EXE, ALPHAKD.EXE, PPCKD.EXE)
 * Microsoft Windows NT WinDbg (WINDBG.EXE)
 * Microsoft Windows NT Symbolic Debugger (NTSD.EXE)
 * Microsoft Windows NT Console Debugger (CDB.EXE)

For additional information on the Windows NT debuggers, please see the following article in the Microsoft Knowledge Base: "Q121652 List of Debuggers Supported with Windows NT" LAN Manager supports only an unsophisticated dumb terminal debugger.

Post-Mortem Debugger for Unhandled User-Mode Exceptions

Windows NT allows you to specify a post-mortem debugger for unhandled user- mode exceptions. The primary debuggers used to debug user-mode exceptions are the following:


 * Microsoft Dr. Watson for Windows NT
 * Microsoft Windows NT Kernel Debugger
 * Microsoft Visual C++ interface

For additional information, please see the following article in the Microsoft Knowledge Base: "Q121434 Specifying the Debugger for Unhandled User Mode Exceptions" LAN Manager does not allow you to specify a post-mortem debugger for unhandled user-mode exceptions.

Automatic STOP-Recovery and Off-Line Debugging

The following STOP-recovery options in Windows NT version 3.5 and 3.51 allow for minimal server-down time and off-line debugging in most situations:


 * Send an administrative alert.
 * Write a message to the system log.
 * Create a kernel mode dump file.
 * Create a user mode dump file (available since Windows NT version 3.51).
 * Automatically reboot.

The new Dr. Watson for Windows NT can be configured to dump the virtual address space for the program that generated the fault to a dump file, which can be read with the modified Windows NT WinDbg program.

Windows NT 3.51 also introduces three new utilities that assist customers in handling kernel mode crash dump files:


 * DUMPEXAM.EXE performs basic debugging analysis of a kernel mode crash dump file. It generates a text file with the output of the analysis.
 * DUMPCHK.EXE performs a validity check on a kernel mode crash dump. This utility verifies that the file was written correctly and is readable by a debugger.
 * DUMPFLOP.EXE copies a dump file to floppy diskettes and reassembles a dump file from floppy diskettes.

LAN Manager does not provide any capability for automatic recovery or off- line debugging. You may not reboot the server as long as the support professional is working on debugging the problem.

Source-Level Debugging

Windows NT provides source-level debugging with some debuggers. This allows you to debug directly using the source code in a higher level language such as C, rather than using disassembled computer code.

The LAN Manager debugger displays code in symbolic assembly language. This provides function names, however, the remaining code is in assembly language.

Additional query words: prodnt prodlm 2.20b 2.20c 3.10 dbg crash crashes crashed

Keywords         : Version          : winnt:3.1,3.5,3.51; :2.2b,2.2c,3.1 Platform         : winnt Issue type       :
 * }