This article was previously published under Q152460
SrvAny is a tool found in the Windows NT Resource Kit that is used forrunning Windows NT applications as services. It may be necessary in someinstances to troubleshoot an application started using the SrvAny service,and one of the best ways of doing this is by using Cmd.exe as theapplication starts interactively from SrvAny. From the command prompt youcan then start the application in question, watch for errors, checkregistry values relative to the service account, and perform othertroubleshooting steps. The following steps show how to set SrvAny to run aninteractive command prompt for such purposes.
Install Srvany.exe as a service by using another tool in the Windows NTResource Kit, Instsrv.exe. For example:
INSTSRV SrvAny c:\reskit\srvany.exe
Click Control Panel and then Services. From the list of services thatappears, select SrvAny, then click the Startup button.
Configure the service for automatic or manual startup type, depending on whether your troubleshooting involves an application that is started automatically through SrvAny each time the system is restarted, or only occasionally.
Select the System account as the service (or Log On As) account and enable the Allow Service To Interact With Desktop option. This is required for the command prompt to be interactive.
Click the OK button. (It's fine to leave the Control Panel, Services, applet running since it is used later in these instructions.)
If you require the regular use of the interactive command prompt, skip to step 4.
Start (or switch to) the Control Panel, Services, applet.
Select SrvAny from the list of services.
Select the Startup Parameters text entry field.
Enter the following text (modified to reflect your own Windows NT path):
NOTE: Due to the way the startup parameters are parsed, the double backslashes are required to be interpreted correctly as single backslashes.
Click the Start button to start the service.
Perform any necessary troubleshooting steps.
You do not need to continue with any of the following steps.
For regular use of the interactive command prompt, first ensure that the SrvAny service is configured to start automatically by reviewing step 2 above.NOTE: Having an interactive command prompt regularly established through SrvAny as outlined in this article makes this command prompt available to all Windows NT users of the computer, and, since this command prompt is configured to run under the security context of the System account, all Windows NT users of the computer have System account access from this command prompt and any applications started from it.
Start Registry Editor.
WARNING: Using Registry Editor incorrectly can cause serious, system-wide problems that may require you to reinstall Windows NT to correct them. Microsoft cannot guarantee that any problems resulting from the use of Registry Editor can be solved. Use this tool at your own risk.
Select the following registry key from the window entitled