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

Windows 2000 Task Scheduler question

Status
Not open for further replies.

bigfoot

Programmer
Joined
May 4, 1999
Messages
1,779
Location
US
The guy before me was using the Task Scheduler to run a batch file every morning that kicks off reports.
He's running the tasks under a network account.
If the server is not logged in, it seems like the reports do not run.

What accound should I be using to run these so that even if the server is not logged in, they will still run.

Sorry, I'm a bit new to the Task Scheduler.
 
Is the run only if logged in box ticked in properties?
 
I don't have that option anywhere. Sorry.

I'm running Windows 2000, version 5 of the Task Sched. SP4.

Hope this helps.
 
The exit codes returned can be viewed via Scheduled Tasks / Advanced / View Log.


The most common exit codes are:

0 or 0x0: The operation completed successfully.

1 or 0x1: Incorrect function called or unknown function called.

10 or 0xa: The environment is incorrect.


There is a section on the MS site for XP but i can't find the 2k one anymore but it might be worth a look.


 
Got this late. Today they all ran and the code was (0).

Should I be running them under Administrator?
Then if the machine was not loged in, then it would still run? No clue.
 
I think when the PC is not logged on then it runs under the local system user.

What is the task doing and it it doing it on the local machine or accross the network?
 
Thanks so much for the help.

It's running a .BAT batch file that is calling a program called V-Cut, or Visual Cut.
V-Cut runs Crystal Reports which connect to a database on another server and run reports. it outputs these reports in PDF format to a drive on a 3rd server, then sends an email to our warehouse people.

The pdf also on the server.

This is my first experience with V-Cut. Never used it before but it seems to work.
I was thinking of kicking the reports off from our SQL Server, but I was not sure it would work.

Like I said, I did not set this up, but it's mine now. :-)

 
I've never used it either It might be easier to lock the screen on the server so they run correctly, we have to do this on our Sybase server for that to run correctly.
 
The server room is locked. No one enters past our IT people.

It's when the server goe down and comes back or they forget to log it on.

So you're thinking it can't be done either? Meaning it has to be logged in?

What about a service?
I'm almost ready to write the thing in VB.NET.
 
It is possible that under the 2k task schedular that it might have to be.

Have you tried running the task under the same account that you use to logon to the server?
 
You don't need to be logged in. I have run many tasks in 2K server using domain accounts (not admin or domain admin), while logged out. If your logs are returning error code 0, then the task is running, but something else may be failing along the way that's not directly related to whether or not the task itself runs.
 
I'll have to test this early in the morning and change the job to print an hour earler so as not to mess up the data.
The reports are time sensitive.

Since I didn't check the logs yesterday, then I don't know what they returned as a result of a failure.
Only way is to copy the job and fire it off earler with the server logged out.

Thanks for the help.

Have you tried running the task under the same account that you use to logon to the server?
Not yet. we log in under administrator.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top