ASP.Net Interview Question: What are the steps to configure SQLServer mode?

  • SQLSERVER mode session data is stored in a different process so you must ensure that your objects are serializable.
  • IIS metabase (\LM\W3SVC\2) must be identical across all servers in that farm.
  • By default Session objects are stored in Tempdb, you can configure it store outside TempDB by running Microsoft provided SQL script.

TempDB database is re-created after SQL SERVER computer reboot.If you want to maintain session state with every reboot best is to run SQL Script and store session objects outside TempDB database.