Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
Operating System - Microsoft
cancel
Showing results for 
Search instead for 
Did you mean: 

Windows NT automatic command execution after boot

Vijaya Kumar_3
Respected Contributor

Windows NT automatic command execution after boot

Is there a way to add command line or Batch file to NT Server, by which whenever the boot is completed it has to execute this batch file.

I am an unix guy and dont know much about NT. I am looking for version of adding shell scripts to rc.local file in NT.

Thanks
VJ
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
9 REPLIES
Roger Faucher
Honored Contributor

Re: Windows NT automatic command execution after boot

VJ:

If you click Start/Programs/Startup, you will see a list of programs that run at Startup. If you insert the pointer to your batch file there, it should do what you want it to.

HTH

Make a great day!

Roger
Make a great day!

Roger
Vijaya Kumar_3
Respected Contributor

Re: Windows NT automatic command execution after boot

I hope it is with login not with system startup.
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
Antoniov.
Honored Contributor

Re: Windows NT automatic command execution after boot

Hi,
before you have create a new link to your batch file, then insert this link into startup folder; click on [Start], [Tools], [Application Bar], [Start Menu] and add to startup folder.
(I hope right translated in english :-~)

Antonio Vigliotti
Antonio Maria Vigliotti
Ganesh Babu
Honored Contributor

Re: Windows NT automatic command execution after boot

Yes the steps mentioned by Roger & Antonniov is for login not the system startup..

Ganesh
Jon Finley
Honored Contributor

Re: Windows NT automatic command execution after boot

There are a few ways to insert a Startup and Shutdown script on to the system.

gpedit.msc is the easiest.

Look under Local Computer policy, Computer configuration, Windows settings, Scripts.

Jon
"Do or do not. There is no try!" - Yoda
Vijaya Kumar_3
Respected Contributor

Re: Windows NT automatic command execution after boot

Thanks Jon.

But it is for Windows 2000. But i need it for NT

Thanks
VJ
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
Antoniov.
Honored Contributor

Re: Windows NT automatic command execution after boot

You can add a new entry in windows registry at HK_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run

Antonio Vigliotti
Antonio Maria Vigliotti
Thomas Bianco
Honored Contributor

Re: Windows NT automatic command execution after boot

Antoniov has it right, but i think you need runservices, as it will run at system startup.

while i'm on services, you might consider using servany (part of the windows resource kit) to create this batch file as a service.

if you've got the ie4 desktop update you might look at scheduled tasks, it has a "on boot" scheduled method, thou i think it's really on logon.
There have been Innumerable people who have helped me. Of course, I've managed to piss most of them off.
Chad Miller_5
Trusted Contributor

Re: Windows NT automatic command execution after boot

Isn't that what autoexec.nt and config.nt are for? Been a while since I have done NT stuff, but you should be able to launch commands before the login process with these files.