Export (0) Print
Expand All
Expand Minimize

Scheduling Timed Jobs

Archived content. No warranty is made as to technical accuracy. Content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Several features of Microsoft's SharePoint Team Services and Microsoft FrontPage 2002 Server Extensions rely on scheduled background processes. For example, to be able to review usage analysis information, the information must be gathered, preferably when your site is not being heavily used. With SharePoint Team Services and FrontPage 2002 Server Extensions, you can schedule the following operations to occur automatically at specific times:

  • Running usage analysis

  • Checking server health

  • Backing up the database

Scheduled times apply to all Web sites on a particular virtual server. You cannot schedule usage analysis to run at 9 A.M. on one Web site and at 10 A.M. on another Web site within the same virtual server. You can schedule jobs for all virtual servers on a server computer, but any existing virtual server settings take precedence. For example, if you have a virtual server (Vserver1) set to run a job at midnight every night, and you set all virtual servers to run the job at 11 P.M. instead, the job is still run at midnight for Vserver1.

On the Microsoft Windows platform, the SharePoint Timer Service — a background utility included with SharePoint Team Services and FrontPage 2002 Server Extensions — handles scheduled jobs. To set times for the SharePoint Timer Service, you use commands in the command-line tool or HTML Administration pages. On UNIX, you use the built-in UNIX cron facility to schedule jobs.

Note   The SharePoint Timer Service is not available for FrontPage 2002 Server Extensions on the Windows Server 2003 family platform. To run the usage analysis, server health, and database back up processes manually, use the usage, check, and backupdb command-line operations without the schedule parameter. To schedule these operations, include the command-line operations in a batch or script file. For more information about the command-line operations for usage analysis, server health, and back up, see Command-line Operations.

About the Calendar

 Cc768015.spacer(en-us,TechNet.10).gif Cc768015.spacer(en-us,TechNet.10).gif

The SharePoint Timer Service relies on the Gregorian calendar for scheduling. For every job you schedule, you must specify a beginning time for that job based on a 24-hour clock. You specify the time in local time versus an offset from Universal Coordinate Time (UCT), and the time is stored in that format as well. Any other scheduling specifications (such as day of the week) are optional. If none are given, then the job is run at the given time every day.

The dates used by the SharePoint Timer Service are not stored in context. This means that you cannot schedule jobs to run every X days/weeks/months/years, where X is greater than 1. So, while you can schedule jobs to run every day, every week, every month, or every year, you cannot schedule a process for every two days, and so on. Neither can you schedule jobs for relative days in a month, such as the third Monday of every month.

You can, however, specify jobs to recur every <x> minutes, hourly at <minute>, daily at <time>, weekly at <day of week> <time>, monthly at <day of month> <time>, and yearly at <month> <day> <time>. You specify times using the HH:MM format. Specify days of the week by using the following abbreviations: Mon, Tue, Wed, Thu, Fri, Sat, Sun. Specify months by using the following abbreviations: Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec.

Note   The days of the week and names of the months must be typed in their English abbreviated form (for example, Mon, Tue, Wed and Jan, Feb, Mar). The SharePoint Timer Service does not recognize the names of the months or days of the week in other languages.

For example, you can set a process to run at the following times using the following syntax:

  • Every 10 minutes

  • Hourly at 10

  • Daily at 22:30

  • Weekly at Mon 1:21

  • Monthly at 1 2:00

  • Yearly at Jan 4 12:31

Scheduling Jobs Under Windows

 Cc768015.spacer(en-us,TechNet.10).gif Cc768015.spacer(en-us,TechNet.10).gif

You use commands in the command-line tool or HTML Administration pages to schedule jobs on the Microsoft Windows NT platform. The commands work like any other command in the command-line tool or HTML Administration pages. On the command line, you type the appropriate operation and include the scheduling information. On HTML Administration pages, you use the administration page for the job you want to schedule, and then select the time and date that you want to run the job.

Using the Command Line to Schedule Jobs

 Cc768015.spacer(en-us,TechNet.10).gif Cc768015.spacer(en-us,TechNet.10).gif

You schedule jobs from the command line by using the –schedule parameter with the operation you want to schedule. The following operations take the schedule parameter:

Operation

Definition

Usage

Runs usage analysis reports. Specify a time/day/month/year to run the usage analysis reports.

Check

Checks for problems with SharePoint Team Services and FrontPage 2002 Server Extensions and fixes them. Specify a time/day/month/year to run server health checks.

Backupdb

Backs up the data in the database. Specify a time/day/month/year to back up the database. SharePoint Team Services only.

The following example syntax shows how to set the usage analysis job to be run every Monday at 11:59 P.M. for port 80.

owsadm.exe –o usage –schedule "weekly at Mon 23:59" –p 80

Using HTML Administration Pages to Schedule Jobs

 Cc768015.spacer(en-us,TechNet.10).gif Cc768015.spacer(en-us,TechNet.10).gif

You can also schedule jobs by using HTML Administration pages. To do so, you go to the page that contains the settings for the job you want to schedule, and then select the day, date, month, year, and time that you want the jobs performed. For example, you would use the following procedure to set SharePoint Team Services weekly subscription notifications to be sent out at noon on Mondays. The Web subscriptions settings are managed from the Site Administration pages.

To view the Site Administration page 

  • If you are a server administrator, on the server computer click Start, point to Programs, point to Administrative Tools, and then click Microsoft SharePoint Administrator, and then on the Server Administration page, click the name of the site you want to manage.

  • If you are a site administrator, on your Web site, click Site Settings, and then under Web Administration, click Go to Site Administration.

To change the time for weekly subscription notifications 

  1. On the Site Administration page for the virtual server, under Web Discussions and Subscriptions, click Change Web subscription settings.

  2. In the Notification Recurrence Settings area, in the Weekly notifications box, specify the day of the week and the time to send out weekly notifications.

  3. Click Submit.

Scheduling Jobs Under UNIX

 Cc768015.spacer(en-us,TechNet.10).gif Cc768015.spacer(en-us,TechNet.10).gif

You use the built-in UNIX cron and crontab facilities to schedule jobs on the UNIX platform. To run a scheduled job for FrontPage 2002 Server Extensions, you simply add the job to the list for cron by using crontab. For example, if you want to back up the database every week, you would add the following Owsadm command-line syntax to the crontab file:

owsadm.exe –o backupdb –p 80

And then set the schedule using the standard crontab syntax. For UNIX, any FrontPage 2002 Server Extensions command can be a scheduled job. For more information about using cron and crontab, see the manual (man) pages for your UNIX system.

Related Links

 Cc768015.spacer(en-us,TechNet.10).gif Cc768015.spacer(en-us,TechNet.10).gif

For more information about running particular jobs, see the following topics: Analyzing Web Site Usage, Managing Web Document Discussions and Subscriptions, Backing Up and Restoring Data, and Monitoring Server Health.

Cc768015.spacer(en-us,TechNet.10).gif

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft