Archive for July, 2010

Download a solution from your Farm (SP2100)

July 30, 2010

Wanted to download a solution from my farm. So did it with PowerShell:


param([string]$folder)
write-host ""
write-host -f Green "Get Solutions from Farm - Stef van Hooijdonk - v1.0"
write-host ""
$snapin="Microsoft.SharePoint.PowerShell"
if (get-pssnapin $snapin -ea "silentlycontinue") {
  write-host -f Green "PSsnapin $snapin is loaded"
}
else {
  if (get-pssnapin $snapin -registered -ea "silentlycontinue") {
    write-host -f Green "PSsnapin $snapin is registered"
    Add-PSSnapin $snapin
    write-host -f Green "PSsnapin $snapin is loaded"
  }
  else {
  write-host -f Red "PSSnapin $snapin not found"
}
}
write-host ""
$folder = Join-Path -Path $folder \ -resolve
if ( Test-Path $folder ) {
  $farm = Get-SPFarm
  foreach($sol in $farm.Solutions){
    $solutionFileName = $folder +$sol.SolutionFile.Name
    $sol.SolutionFile.SaveAs($solutionFileName )
    Write-Host "- saved" $sol.SolutionFile.Name
  }
}
else {
  Write-Host -f Red "ERROR: Folder ""$folder"" does not exist"
}
write-host ""

SharePoint 2010 and WSS v4 Cumulative Update 1

July 22, 2010

I do not know how Stefan found this, but it’s here: the first cumulative update for WSS v4 and SharePoint 2010.

(22-07-2010) The knowledge base articles are not present yet, so no word on what is updated. Don’t rush to install them just yet 🙂

(26-7-2010) The knowledge base articles are present now. And the Claims based authentication issue with Outlook social connector is now fixed!!

ServicePack 1 when it will be released will include these also.

Download links are found here:

http://blogs.technet.com/b/stefan_gossner/archive/2010/07/22/the-first-cumulative-update-for-sharepoint-2010-family-has-been-released.aspx

(Direct links: )

Microsoft SharePoint Foundation 2010:

Microsoft SharePoint Server 2010:

Microsoft announces the release of the SharePoint 2010 Administration Toolkit v1

July 16, 2010

Jet Li posted this over at the SharePoint Team Blog:

“I am pleased to announce the availability of the first version of the SharePoint 2010 Administration Toolkit. In this toolkit we’ve included a couple of tools that were shipped releases and are now adapted to SharePoint 2010, along with two new tools.”

The toolkit can be downloaded from here: http://www.microsoft.com/downloads/details.aspx?FamilyId=718447d8-0814-427a-81c3-c9c3d84c456e&displaylang=en

The toolkit documentation can be found here:

SharePoint Foundation 2010: http://technet.microsoft.com/en-us/library/cc508986.aspx

SharePoint Server 2010: http://technet.microsoft.com/en-us/library/cc508851.aspx  

Read more: http://blogs.msdn.com/b/sharepoint/archive/2010/07/15/announcing-the-release-of-the-sharepoint-2010-administration-toolkit-v1.aspx

Claims Based authentication and the Outlook social connector don't work together

July 14, 2010

Following the updates on the Outlook social connector and the Facebook plugin for the Outlook social connector there is one little snag!

When using a SharePoint 2010 Web Application for your portal/mysites with Claims Based authentication the Outlook social connector cannot connect to it!

UPDATE: SP2010 CU1 fixes this!

With Fiddler you will see that Outlook will try to connect to http://portal/_vti_bin/Authentication.asmx

But this returns a response with the word (ModeResult) “Forms”

and that’s why Outlook will show that it cannot connect!

 There is a sort 0f solution for this, create a second webapplication, with a separate url, and connect it to the same User Profile Service application as your portal but configure it with windows authentication. Now users can use this second url in their Outlook Social Connector for Sharepoint.

Usefull tools for Claims Based authentication and SharePoint 2010

July 14, 2010

If you want to create a your own Security Token Service that is compatible with SharePoint 2010 have a look here and download the Windows Identity Foundation (formaly known as Geneva)  SDK:

http://www.microsoft.com/downloads/details.aspx?FamilyID=c148b2df-c7af-46bb-9162-2c9422208504&displaylang=en

This will install 4 VS 2010 Project Templates on which you can base your Custom STS, I used the first one :

Part of a STS is the WS-Federation Metadata document ( . you can create one for your STS with this tool:

http://weblogs.thinktecture.com/cweyer/2009/05/geneva-based-ws-federation-metadata-document-generation-wizard-or-oops-i-did-it-again.html

When you want to trust a STS Token Service within your SP2010 Farm you can use this tool:

http://shojeeb.com/sharepoint/sharepoint-federation-utility-spfedutil-exe/

Claims based authentication and SharePoint 2010 QFE

July 14, 2010

When using SharePoint 2010 with a Claims Based Authentication Web Application you will receive an issue in your Central Administration Healt analyser:

“Web Applications using Claims authentication require an update”

Just install this hotfix: http://code.msdn.microsoft.com/KB979917 ( the first recorded SP2010 update? )

More info on the issue: http://technet.microsoft.com/en-us/library/ff686815.aspx

Claims Based authentication and the PublishingCache

July 6, 2010

If you are using Claims Based Authentication on your WebApplication then the Publishing Cache doesn’t work properly.

Have a look into your Developer Dashboard to see what is going on:

The warning and critical error are:

  • 7362 – Warning Publishing Cache
  • 7363 – Critical Publishing Cache

Why is this? Because with Claims Based Authentication the Cache account cannot access the Content Databases.

The solution is to provide your SPWebApplication with two settings (Properties):

  • portalsuperuseraccount
  • portalsuperreaderaccount

If you are lazy, like me, you probably want to automate this into a PowerShell script:

Update 6 juli 2010: This script sets the default managed account as the portalsuperuseraccount and portalsuperreaderaccount. In a production scenario this will work, but it is wiser to use a read only account. Give this account Full Read permission through a Web Application Policy, follow this step-by-step-guide.

write-host ""
write-host -f White "Configure the WebApp property: portalsuperreaderaccount"
write-host ""
write-host -f Green "Stef van Hooijdonk - v1.0"
write-host ""

$snapin="Microsoft.SharePoint.PowerShell"
if (get-pssnapin $snapin -ea "silentlycontinue") {
	write-host -f Green "PSsnapin $snapin is loaded"
}
else {
	if (get-pssnapin $snapin -registered -ea "silentlycontinue") {
		write-host -f Green "PSsnapin $snapin is registered"
		Add-PSSnapin $snapin
		write-host -f Green "PSsnapin $snapin is loaded"
	}
	else {
		write-host -f Red "PSSnapin $snapin not found"
	}
}

write-host -f Green "Getting current Farm"
$farm = Get-SPFarm

write-host -f Green "Getting Default ServiceAccount (Managed)"
$cacheAccount= $farm.DefaultServiceAccount.Name

write-host ""
write-host -f Green "Going to loop Claims Based authentication WebApplications"
write-host ""

Get-SPWebApplication | foreach-object {

	if ($_.UseClaimsAuthentication ) {
	write-host -f white $_.Url " is a Claims Based Authentication WebApp"

	write-host -f yellow " - Setting Property: portalsuperuseraccount $cacheAccount for" $_.Url
	$_.Properties["portalsuperuseraccount"] = "$cacheAccount"

	write-host -f yellow " - Setting Property: portalsuperreaderaccount $cacheAccount for" $_.Url
	$_.Properties["portalsuperreaderaccount"] = "$cacheAccount"

	$_.Update()
	write-host "Saved properties"
	}

}
Write-host ""
Write-host -f red "Going to run IISReset"
Write-host ""
IISreset /noforce
Write-host ""