Tuesday, 15 July 2014

Object Cache: The super user account utilized by the cache is not configured. This can increase the number of cache misses, which causes the page requests to consume unneccesary system resources.



A colleague had tried to fix this problem yesterday, and I came in this morning to find one web application was down.  It gave me a correlation ID, which led me to the following...



After checking the ULS logs I didn't immediately suspect the change of superuser/superreader accounts to be to blame but the event viewer was showing loads of event 7362 errors.

As the warning in the event log suggests there is a way to fix this by running an STSADM command. Unfortunately this is only part of the story.
The way to correct this problem is to first create two normal user accounts in AD. These are not service accounts. You could call them domain\superuser and domain\superreader, but of course that’s up to you.
The domain\superuser account needs to have a User Policy set for that gives it Full Control to the entire web application. In order to do this you perform the following steps:

  • Go to Central Administration
  • Go to Application Management
  • Go to Manage Web Application
  • Select the web application 
  • Click User Policy
  • Add Users
  • Click Next
  • Fill in domain\superuser
  • Select Full Control
  • Click OK

The domain\superreader account needs to have a User Policy set for that gives it Full Read to the entire web application. In order to do this you perform the following steps:

  • Go to Central Administration
  • Go to Application Management
  • Go to Manage Web Application
  • Select the web application 
  • Click User Policy
  • Add Users
  • Click Next
  • Fill in domain\superreader
  • Select Full Read
  • Click OK

If you are using claims authentication the accounts can only be updated using powershell, not stsadm. The user name also needs to be preceded by i:0#.w|

Finally perform an IISRESET

Thursday, 10 July 2014

Export All Unique Permissions from Site Collection using PowerShell

This handy script loops though all sites, lists, libraries and documents in a Site collection and exports all the permissions into a csv.
Just remember to replace '' with your site collection URL.


Recycling IIS the easy way

Sometimes (not very often) I need to recycle IIS on all the servers in the farm. Rather than go round one by one I use this handy Powershell script.

Save the following code as a *.ps1 then right click and 'Run with Powershell'

Hiding users with 'Limited Access'

I often get asked by users why SharePoint adds users into the site permissions with 'Limited Access'. I got a little tired of explaining this to everyone so decided to add some javascript to the master page to remove all users with limited access from the view.