Stop admin services, start immediately timer jobs, start admin services.
- net stop SPAdminV4
- Start-SPAdminJob
- net start SPAdminV4
Good articles on SharePoint Variation
Run Sharepoint Configuration Wizard from powershell.
psconfig.exe -cmd upgrade -inplace b2b -force -wait -cmd installcheck –noinstallcheck
psconfig.exe -cmd upgrade -inplace b2b -force -wait -cmd installcheck –noinstallcheck
import-spweb -Identity http://xxx/xx -path C:\SPBU\Banners2\ExportList-
import-spweb -Identity http://xxx/xx -path C:\SPBU\Promotions\ExportList- 074335ed-2b00-4a1f-9db5- d3df31e2bcc9.DAT
Export content from SharePoint
function Export-All-SPWeb-Lists([ string]$WebURL, [string]$ExportRootPath)
{
[System.Reflection.Assembly]: :LoadWithPartialName(" Microsoft.SharePoint") > $null
[System.Reflection.Assembly]: :LoadWithPartialName(" Microsoft.SharePoint. Deployment") > $null
$versions = [Microsoft.SharePoint.
$exportObject = New-Object Microsoft.SharePoint.
$exportObject.Type = [Microsoft.SharePoint. Deployment. SPDeploymentObjectType]::List
$exportObject. IncludeDescendants = [Microsoft.SharePoint. Deployment. SPIncludeDescendants]::All
$settings = New-Object Microsoft.SharePoint.
$settings.ExportMethod = [Microsoft.SharePoint.
$settings.IncludeVersions = $versions
$settings.IncludeSecurity = [Microsoft.SharePoint. Deployment.SPIncludeSecurity]: :All
$settings. OverwriteExistingDataFile = 1
$settings.ExcludeDependencies = $true
$site = new-object Microsoft.SharePoint.SPSite($
#Write-Host "WebURL", $WebURL
$web = $site.OpenWeb()
#$list = $web.GetList($ListURL)
foreach($list in $web.lists)
{
$settings.SiteUrl = $web.Url
$exportObject.Id = $list.ID
$newFolderPath = $ExportRootPath + $list.Title
New-Item $newFolderPath -type directory -force
$settings.FileLocation = $newFolderPath
$settings.BaseFileName = "ExportList-"+ $list.ID.ToString() +".DAT"
$settings.FileCompression = 1
Write-Host "List", $list.Title
Write-Host "FileLocation", $settings.FileLocation
$settings.ExportObjects.Add(
$export = New-Object Microsoft.SharePoint.
$export.Run()
}
$web.Dispose()
$site.Dispose()
}
Export-All-SPWeb-Lists "http://mySharePointWebApp/
No comments:
Post a Comment