Script reports all the scheduled jobs

If you are running many scheduled tasks on each server, it may be time consuming to log on to each server to check if a scheduled task has succeeded or failed. These scheduled tasks can be any of a number of operations:


  1. Ntbackup
  2. Veritas Backups
  3. Discleanup jobs
  4. Robocopy Jobs
  5. SQL backups

Whether a job is a success or failure, a log is generated in the application log or system log.

Requires Free Membership to View

ELDump is a free tool that reads the contents of the log file. This tool can be effectively used with some scripting to report all the jobs to a particular place. This can make the network administrator's job much easier.

You can write a script (as shown below) for a Veritas Backup exec job and schedule it to run after the Veritas backup job is completed. You should know the timeframe of when the backup exec job will be completed. The same can be done for all the scheduled tasks with some minor changes in the script. This is an effective way of reporting the scheduled jobs in a common place.

Here is the script:

echo off

net use \ServerReportc$ /del
(ServerReport is the server where all the scheduled jobs would be reported.)

net use \ServerReportc$ /user:domainnameuseraccount password
(Logging onto the ServerReport server.)

(Changing the path to the location where eldump is copied.)

eldump -l application -A 2 -m "backup exec" > c:BackupExec.log
(Checks all the backup exec logs in the last two hours and dumps it to backupexec.log file.)

FOR /F "tokens=13,14*" %%2 IN (c:backupexec.log)
DO if %%2==Job echo %computername% , %date%, %%2 %%3 %4>>\ ServerReportReport.txt
(Checks if the 13 character in a line is job. If it satisfies the condition then it reports in the reports.txt.)

Please let us know how useful you find this tip by rating it below! If you have a useful Windows tip, timesaver or workaround to share, submit it to our tip contest and you could win a prize!

This was first published in August 2006

There are Comments. Add yours.

TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

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:

Disclaimer: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.