SharePoint 2010: How to Undo Portal Super Reader /Portal Super User Account Configuration for a Web Application

A common problem that I have recently seen crop up is where you configure your web application to use portal super reader and/or portal super user accounts, and for whatever reason, you need to “unset” the configuration or revert back to the default setting. I have seen some cases where administrators try to set the account value to an empty string or a null value, which is not correct:

$wa = Get-SPWebApplication “https://urlofthewebapplication"

$wa.Properties["portalsuperuseraccount"] = "$null" (Incorrect)

$wa.Properties["portalsuperuseraccount"] = "" (Incorrect)

Instead of setting the property to null or an empty string, we need to remove the property from the web application’s properties Hashtable. Here is the correct way to “unset” the portal super reader and the portal super user account properties of a web application:

$wa = Get-SPWebApplication “https://urlofthewebapplication”

$wa.Properties.Remove("portalsuperuseraccount")

$wa.Properties.Remove("portalsuperreaderaccount")

$wa.Update()

Happy SharePointing!

Comments

  • Anonymous
    June 25, 2012
    good post normally every one forgets to look for this until they face an error

  • Anonymous
    August 14, 2012
    Thanks a lot!

  • Anonymous
    September 06, 2012
    Most useful. Thanks much!

  • Anonymous
    December 11, 2012
    Thanks.. This was helpful..!

  • Anonymous
    May 03, 2013
    You can also use : $wa.Properties.Clear() $wa.Properties.Update()

  • Anonymous
    May 03, 2013
    @Ryan: The web application property bag stores a number of different configuration settings depending on your environment. Using the "Clear()" function will remove all properties associated to the web application, not just the portal super user/portal super reader properties and may lead to other issues. Please use the method outlined in the blog post.

  • Anonymous
    October 17, 2013
    Thanks Tehnoon for sharing this - this saved my day :-)