Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems with subst.exe and autoexec.bat

Status
Not open for further replies.

ADiplomat

IS-IT--Management
Jan 24, 2005
3
0
0
US
I'm currently trying to setup a virtual drive on Windows 2000 Server using c:\winnt\system32\subst.exe. If I do the command in a command prompt shell, it works fine. If, however, I put the command in autoexec.bat, the virtual drive is not created.

I can't even prove that autoexec.bat is even getting parsed in this case. I have checked the registry to make sure that the setting is correct for parsing autoexec.bat:

[HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Winlogon]
"ParseAutoexec"="1"

Any help would be greatly appreciated.

Michael Christenson
Disaster Recovery Coordinator
Summit Information Systems
 
The first step would be to just run the file (autoexec.bat) from a command prompt.
If it works then you should start investigating why its not working on boot.
 
Yep, I just left that step out :) Already tested that out and it works fine, which is the strange thing.

I've researched elsewhere and get mixed reports as to whether Windows 2000 (Pro or Server) will even process autoexec.bat at startup.

I've tested putting a .bat file into the startup directory, and that works fine as well, but unfortunately I need this virtual drive created at or before the time that the Windows services start up.



Michael Christenson
Disaster Recovery Coordinator
Summit Information Systems
 
Try creating a new string value in the registry:

HKLM\Software\Microsoft\Windows\CurrentVersion\Run

directly to the batch file eg:
"C:\runthis.bat"

Also what about trying to create a shortcut to the batch file and using that (the .lnk file) as what's run to start the batch file.

Hope that helps!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top