Geeks With Blogs

Tangible Thoughts SharePoint, MOSS? and all the other questions

All right I admit, that's a very abstract title for a blog post, and its not eye catchy or snazzy as something like “What to do when you get a “Object reference not set to an instance of an object. exception on a SharePoint farm that uses SQLSessionState. “

But hey its supposed to grab your attention if you are having this problem.

Ok so the error is

Server Error in '/' Application.
Object reference not set to an instance of an object.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]
   Microsoft.Office.Server.Administration.SqlSessionStateResolver.System.Web.IPartitionResolver.ResolvePartition(Object key) +76
   System.Web.PartitionManager.GetPartition(IPartitionResolver partitionResolver, String id) +244
   System.Web.SessionState.SqlSessionStateStore.GetConnection(String id, Boolean& usePooling) +52
   System.Web.SessionState.SqlSessionStateStore.SetAndReleaseItemExclusive(HttpContext context, String id, SessionStateStoreData item, Object lockId, Boolean newItem) +178
   System.Web.SessionState.SessionStateModule.OnReleaseState(Object source, EventArgs eventArgs) +355
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +92
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64

 

What I would like to highlight is amongst the various other technical issues as to why this might happen, one of them could be as simple as accessing SharePoint through a URL that resolves to the WFE but SharePoint is unaware of it.

Ok so what that means is, supposed you setup your SharePoint site to be http://MySharePointSite but you accessed it as http://MySharePointSite.domain.com then this could be the reason for the above error.

The solution is to get SharePoint to know about the access method you are using,

i.e. add an alternate access mapping.


Crossposted from tariqayad.com

Posted on Thursday, September 16, 2010 1:13 PM .NET , SharePoint | Back to top


Comments on this post: SQLSessionState, SharePoint & Object reference not set to an instance of an object.

No comments posted yet.
Your comment:
 (will show your gravatar)


Copyright © Tariq | Powered by: GeeksWithBlogs.net