Please tell me how to write a Powershell script that will deploy all added farm solutions.
2 Answers
The best solution is to use a script that will add the solutions to the SharePoint farm, and deploy them by selecting web application you want to install the script.
Follow those links:
-
Thank you. Solutions have already been added. I just can not get to the Administration Center (do not ask why) and I want to deploy all the solutions have already been added.– SDGApr 4, 2012 at 8:15
finally i made the following script which will redeploy all the 200 info-path forms in share-point 2010 which was stucked on deploying because of stopped Timer Service
Remove-PSSnapin Microsoft.SharePoint.PowerShell -erroraction SilentlyContinue
Add-PSSnapin Microsoft.SharePoint.PowerShell -erroraction SilentlyContinue
$forms=Get-SPSolution | ? {($_.Name -like "form-*") -and ($_.Deployed -eq $false)}
foreach($Solution in $forms) {
if(($Solution -ne $null) -and ($Solution.ContainsWebApplicationResource){
Install-SPSolution -identity $Solution.SolutionId -AllwebApplications -GACDeployment -Force -Confirm:$false
}
else {
Install-SPSolution -identity $Solution.SolutionId -GACDeployment -Force -Confirm:$false
}
}
you may need to cancel all stuck in deploying jobs (or installing in infoPath Form management area) with below similar scipt
Get-SPTimerJob | ? {$_.Name -like "Solution-Deployment*" } | % { $_.Delete() }
-
Unfortunately , this script does not resolved my problem .at first it seems to be working but i cannot understand well why no InfoPath Forms deployed Globally in this way and I finally had to Deploy the 200 forms manually , because i was in a hurry. but because the script is working and have some good tips and will not delete it until i found a fix for it– ImanSep 6, 2015 at 11:05