Run your scripts without logging in

One of the most valuable (and least publicized) tools in the Win2k Resource Kit is a little service called AutoExNT.

One of the great advantages to having an application that runs as a service is that you can be sure that when the...

system boots or reboots, the service will load without any effort on your part.

However, there are many circumstasnces where you would like something to happen at boot time that cannot normally be loaded as a service. Maybe you need to run a script or batch file, a Java application, or some other type of software that is not optimized to run as a service. What you usually end up doing in these cases is logging into the system manually, running the script or application, and then locking the workstation. If a server reboots at 3am on a Sunday, then I hope you left your pager on!

Fortunately, there is an alternative. One of the most valuable (and least publicized) tools in the Win2k Resource Kit is a little service called AutoExNT. When this service is run, it looks in the system32 directory for a batch file called autoexnt.bat. It runs this batch file, then shuts itself off. Thus, you can script virtually any activity to occur on your remote server or workstation at boot time. No manual intervention is required.

There are uses for AutoExNT in circumstances other than boot time. Since it stops itself on completion, you could set this service to manual and use it as a simple trigger for complex scripts on the remote server. Just start the service remotely and the script will run. When the service stops you can do it all over again.


This was first published in December 2001

PRO+

Content

Find more PRO+ content and other member only offers, here.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchServerVirtualization

SearchCloudComputing

SearchExchange

SearchSQLServer

SearchWinIT

SearchEnterpriseDesktop

SearchVirtualDesktop

  • Virtual desktop security guide

    To secure virtual desktops, consider antivirus, certificates and network vulnerabilities. Just remember, VDI doesn't always ...

  • Guide to low-cost desktop virtualization

    In this guide, learn to virtualize desktops without spending more than you would when deploying PCs, and what VDI vendors are ...

  • VDI pilot project guide

    A VDI pilot project should start with a VDI project plan. Know what pitfalls to avoid and test product options to achieve a ...

Close