31 August 2010

AutoExNT: Running a batch file before logging into WINDOWS

If you ever need to run a batch file on a SYSTEM level before logging into WINDOWS (e.g. to set static ARP entries), then AutoExNT is the right tool for you!
Check out http://support.microsoft.com/kb/243486 for help on how to do the AUTOEXNT stuff.

Basically you'll need to create a batch file and then do these two simple steps:
  1. Copy the Autoexnt.bat file you just created, in addition to the Autoexnt.exe, Servmess.dll, and Instexnt.exe files located in the Resource Kit CD-ROM to the %SystemRoot%\System32 folder on your computer.
  2. At a command prompt, type instexnt install, and then press ENTER. 
Then, if you want to only run the service ONCE add in the line "sc config autoexnt start= disabled" to the end of your batch file (or before you run the command, just in case you only want to run the file once, regardless of success: you don't want to be stuck in an infinite loop if your program / command is faulty and it never disables the service).

DOWNLOAD? Go to http://www.microsoft.com/downloads/details.aspx?familyid=9d467a69-57ff-4ae7-96ee-b18c4790cffd&displaylang=en and grab all the Windows Server 2003 Resource Tool Kits! Have fun!

No comments: