Wednesday, November 13, 2013

Steps to Activate the custom timer job => Access denied when deploying a timer Job or activating a feature from SharePoint 2010 content web application


The following step i have used to followed to active the timer job.

Step 1: run the script in powershell command
function Set-RemoteAdministratorAccessDenied-False()
{
    # load sharepoint api libs
    [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint") > $null
    [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint.Administration") > $null

  # get content web service
 $contentService = [Microsoft.SharePoint.Administration.SPWebService]::ContentService
  # turn off remote administration security
 $contentService.RemoteAdministratorAccessDenied = $false
  # update the web service
 $contentService.Update()
     
}

Set-RemoteAdministratorAccessDenied-False

step 2: activate the timer job feature in site collection feature.

No comments:

Post a Comment