How to enable Session State in SharePoint 2010

Hi Folks,

If you are trying to use any of SharePoint 2010 Features that use Session state service in SharePoint, Then you need to enable session state service in SharePoint 2010 since it is disabled by default, Here is how to do it:

1) Open SharePoint 2010 Management Shell (As Administrator) and type the following command:

enable-SPSessionStateService

The shell will prompt you to enter the required DB name to store the session state data, type the database name.

Once you get the prompt back to you, You can check the created DB name, under sharepoint instance: SERVERNAME\SHAREPOINT to make sure the DB has been created.


2) Open the site web.config file and enable the session state on the site:

enableSessionState=”true”

3) Reset IIS.

Check the feature or navigate to the site template that depends on session state ( For Example: Project Database site template) and will see it is working.

Hope it helps.

Regards,
Mostafa Elzoghbi

Leave a Reply

Your email address will not be published. Required fields are marked *


*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>