WEBSITE

Sharepoint 2013 : Farm Management - Disable a Timer Job,Start a Timer Job, Set the Schedule for a Timer Job

7/24/2014 9:26:49 PM

Disable a Timer Job


Scenario/Problem: You want to disable a specific timer job.


Solution: Use the Disable-SPTimerJob cmdlet.

To disable a timer job, execute the Disable-SPTimerJob cmdlet with the Identity of the timer job or a timer job variable. Listing 1 shows a sample command line.

Listing 1. Disabling a Timer Job


$timerJob = Get-SPTimerJob -Identity "DocIDEnable"
Disable-SPTimerJob $timerJob

Start a Timer Job


Scenario/Problem: You want to start a specific timer job.


Solution: Use the Start-SPTimerJob cmdlet.

To start a timer job, execute the Start-SPTimerJob cmdlet with the Identity of the timer job or a timer job variable. Listing 2 shows a sample command line.

Listing 2. Starting a Timer Job


$timerJob = Get-SPTimerJob -Identity "DocIDEnable"
Start-SPTimerJob $timerJob


In this scenario, the timer job kicks off when you start it manually. This is the same as selecting the Run Now button in Central Administration.


Tip

You cannot start a timer job that is disabled. Use Enable-SPTimerJob first to ensure that the timer job is enabled before attempting to start the job.

Set the Schedule for a Timer Job


Scenario/Problem: You need to set or modify the schedule of a specific timer job.


Solution: Use the Set-SPTimerJob cmdlet.

Setting the schedule for a timer job can be facilitated by using the Set-SPTimerJob cmdlet. Execute the Start-SPTimerJob cmdlet with the Identity of the timer job or a timer job variable along with the Schedule parameter. Listing 3 shows a sample command line.

Listing 3. Setting the Schedule for a Timer Job


$timerJob = Get-SPTimerJob -Identity "DocIDEnable"
Set-SPTimerJob -Identity $timerJob -Schedule "Daily at 18:00:00"


The Schedule parameter is a string value but must conform to one of the following schedule string formats:

• Every X minutes between 0 and 59.

• Hourly between 0 and 59.

• Daily at hh:mm:ss.

• Weekly between <day> hh:mm:ss and <day> hh:mm:ss. (<day> is the three-letter day of the week: Sun, Mon, Tue, Wed, Thu, Fri, or Sat.)

• Monthly at dd hh:mm:ss.

• Yearly at <month> dd hh:mm:ss. (<month> is the three-letter month: Jan, Feb, Mar, and so on.)


Other  
  •  Sharepoint 2013 : Farm Management - Display Available Timer Jobs on the Farm, Get a Specific Timer Job, Enable a Timer Job
  •  Sharepoint 2013 : Farm Management - Review Workflow Configuration Settings,Modify Workflow Configuration Settings
  •  Sharepoint 2013 : Farm Management - Review SharePoint Designer Settings, Configure SharePoint Designer Settings
  •  Sharepoint 2013 : Farm Management - Remove a Managed Path, Merge Log Files, End the Current Log File
  •  Sharepoint 2013 : Introducing jQuery for SharePoint developers (part 2) - Understanding jQuery methods,Understanding jQuery event handling
  •  Sharepoint 2013 : Introducing jQuery for SharePoint developers (part 1) - Referencing jQuery, Understanding the global function, Understanding selector syntax
  •  Sharepoint 2013 : Introducing JavaScript for SharePoint developers (part 3) - Creating custom libraries
  •  Sharepoint 2013 : Introducing JavaScript for SharePoint developers (part 2) - Understanding JavaScript functions, Understanding JavaScript closures, Understanding JavaScript prototypes
  •  Sharepoint 2013 : Introducing JavaScript for SharePoint developers (part 1) - Understanding JavaScript namespaces, Understanding JavaScript variables
  •  Sharepoint 2013 : List and library essentials - Creating and deleting lists
  •  
    Video
    Top 10
    Michael Kors Designs Stylish Tech Products for Women
    Review : Sigma 24mm f/1.4 DG HSM Art
    Review : Canon EF11-24mm f/4L USM
    Review : Creative Sound Blaster Roar 2
    Review : Philips Fidelio M2L
    Review : Alienware 17 - Dell's Alienware laptops
    Review Smartwatch : Wellograph
    Review : Xiaomi Redmi 2
    Extending LINQ to Objects : Writing a Single Element Operator (part 2) - Building the RandomElement Operator
    Extending LINQ to Objects : Writing a Single Element Operator (part 1) - Building Our Own Last Operator
    REVIEW
    - First look: Apple Watch

    - 3 Tips for Maintaining Your Cell Phone Battery (part 1)

    - 3 Tips for Maintaining Your Cell Phone Battery (part 2)
    Popular Tags
    Video Tutorail Microsoft Access Microsoft Excel Microsoft OneNote Microsoft PowerPoint Microsoft Project Microsoft Visio Microsoft Word Active Directory Exchange Server Sharepoint Sql Server Windows Server 2008 Windows Server 2012 Windows 7 Windows 8 Adobe Flash Professional Dreamweaver Adobe Illustrator Adobe Photoshop CorelDRAW X5 CorelDraw 10 windows Phone 7 windows Phone 8 Iphone