SharePoint 2010 provides many new cmdlets that let you interact and configure content deployment settings. These new cmdlets include the following:

  • New-SPContentDeploymentJob
  • Start-SPContentDeploymentJob
  • Get-SPContentDeploymentPath
  • Set-SPContentDeploymentPath
  • Remove-SPContentDeploymentPath
  • Set-SPContentDeploymentJob
  • Get-SPContentDeploymentJob
  • Remove-SPContentDeploymentJob

You can read up on content deployment and these cmdlet here. The cmdlet that you will find are related to Content Deployment Paths and Jobs. While these work very well and are easy to use, they are only part of the story. To fully configure Content Deployment, you need to set the ‘Accept Content Deployment Jobs’. SharePoint does not give you a cmdlet for these properties.

The code snippet below provides settings for content deployment within the same farm. If you wish to deploy content to another SharePoint farm, modify the ExportWebServer property below.

# Set the variables

$acceptJobs = $true

$secureConnection = $false

$tempFolder = “C:ProgramDataContentDeployment”

$ImportWebServer = “PS-SPS”

$exportWebServer = “PS-SPS”

$reportsPerJob = 20

$pollingInterval = 10

$fileMaxSize = 10

$blockMultiple = $true

# Get an instance of the ContentDeploymentConfiguration object and set the properties

$cs =[Microsoft.SharePoint.Publishing.Administration.ContentDeploymentConfiguration]::GetInstance()

$cs.AcceptIncomingJobs = $acceptJobs

$cs.RequiresSecureConnection = $secureConnection

$cs.TemporaryFolder = $tempFolder

$cs.ImportWebServer = $importWebServer

$cs.ExportWebServer = $exportWebServer

$cs.DefaultReportsPerJob = $reportsPerJob

$cs.RemotePollingINterval = $pllingInterval

$cs.FileMaxSize = $fileMaxSize

$cs.BlockMultipleJobsPerPath = $blockMultiple



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s