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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

My scheduled script won't start (server: MS WIN2000)

Status
Not open for further replies.

bradsteele

Programmer
Oct 19, 2004
24
CA
Hi,

I have a script that backs up the company's code everyday. The script runs perfect and is not a problem. I try to get the computer to run it as a scheduled task and it just won't run. I have adminitrator rights and the path to the script is correct. Has anyone else every had a problem like this? Any Suggestions?
 
I think this problem is related to rights... when the Task Scheduler service runs the script, it is running under the System account. Therefore, the script may fail due to the security.



So, you can either change the logon for the Task Scheduler service, so that it uses an account with access. Or configure authentication in your scripts...


You can also try the RUNAS switch in your scheduled task:


Joseph L. Poandl
MCSE 2003

If your company is in need of experts to examine technical problems/solutions, please contact (Sales@njcomputernetworks.com)
 
I am running the script as administrator, but it still dosn't work.
 
does the script copy data from one box to another, if so you need to run the scheduled task as a domain admin or someone with rights to both machines. Just running the scheduled task as an admin on that box doesn't give the local admin of that box rights to another box on the network
 
Log onto the console and and an at job from the cmd like:

at 14:35 /interative cmd.exe /k

This will open a cmd window using the rights that the scheduler is using. Run your command from inside this new cmd window and see what happens.

Good luck,
Debi
 
i think, the first thing i´ll check is if the accoount´s password that you use in this scheduled task is correct.

I know it is so simple, but some times it is the cause of the problem...

 
Make sure you have the full executable path inside your script. For example if you were to use the xcopy command in a batch file you must use:
c:\windows\system32\xcopy.exe source dest
so it will work when you are not logged into the console.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top