Issue with Azure SDK on a SharePoint Server

This is a fantasic blog by Christian Glessner which
may help many you. Christian was a speaker at the European SharePoint Conference in Berlin, so check out
what he learned :

Few weeks ago I and Hilton Giesenow prepared togheter a
SharePoint & Azure session for the TechEd Africa and the
European SharePoint conference. During the preparation we
discovered an issue running the Azure Compute Emulator on a
SharePoint box (Azure SDK 1.5 and 1.6). First it seemed that the
user profile service screwed up after you had started the emulator
for the first time, but further investigations had shown that many
service applications didn’t work properly anymore. The problem was,
that the emulator sets the IIS anonymous user account to the
application pool’s identity. Many thanks to Wictor Wilen for
telling us which IIS setting has been affected ( we owe you a
pint=>summit 2011 🙂

The Error
The SharePoint error after you have started the Azure Compute
Emulator for the first time:  “Object reference not set to an
instance of an object”

pic 1

 

SharePoint trace:

Unexpected System.NullReferenceException: Object reference not
set to an instance of an object.
at
Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_ApplicationProperties()
at
Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_PartitionIDs()
at
Microsoft.Office.Server.Administration.UserProfileApplicationProxy.IsAvailable(SPServiceContext
serviceContext)
at
Microsoft.Office.Server.WebControls.MyLinksRibbon.get_PortalAvailable()
at
Microsoft.Office.Server.WebControls.MyLinksRibbon.EnsureMySiteUrls()
at
Microsoft.Office.Server.WebControls.MyLinksRibbon.get_PortalMySiteUrlAvailable()

Fix it
To fix this you have just to set the IIS anonymous user back to
IUSR. But unfortunately you have to do this every time after you
have run the emulator.

Open IIS Manager (inetmgr) and do the following steps.

ESPC call for speakers 2024
Azure SDK

Azure SDK

Azure SDK

Done.

Fix it with PowerShell
If you don’t like clicking like a monkey, you can fix it with
PowerShell
PS> import-module webadministration

PS> set-webconfigurationproperty
/system.webServer/security/authentication/anonymousAuthentication
-name userName -value “IUSR”

Hope this will save you time.

 

Share this on...

Rate this Post:

Share: