There can be no Triumph without Loss,No Victory without Suffering,No Freedom without Sacrifice.
All you have to decide is what to do with the time that is given to you.
Get busy Living, or Get busy Dying?
  首页 | 留言给我 | 订阅 Rss | CLI | 黄白之恋 Posts:158   Hits: 5271726    Comments: 173    
<<  <  2024 - 07  >  >>
 About Me
 Name: ZhangSichu
 Sex: Male
 Age: 32
  ·C++/C(5)  RSS
  ·软件工程(1)  RSS
  ·杂事/随感(26)  RSS
  ·.Net/Java(30)  RSS
  ·面向对象程序设计(5)  RSS
  ·汇编/破解(0)  RSS
  ·平面设计(3)  RSS
  ·SQL(5)  RSS
  ·COM/COM+(2)  RSS
  ·Web开发(81)  RSS
 My Friends
Back Forward Refresh Home 2024年7月23日 星期二 RSS CLI Mine Sweeper. In Javascript.

  SQL Server 存储Asp.Net 的Session
字体大小 [ ]

前几天需要将现有Asp.Net程序的Session存入SqlServer 同事整理了配置Sql的过程。

1. Run the slq script on the sql server
It will create a database named "ASPState"
We should config the permission for process in this database.

2. Modify the web.config
<sessionState mode="SQLServer" sqlConnectionString="data source=servername;user id=uid;password=pwd" cookieless="false"
timeout="30" stateNetworkTimeout="20"/>

stateNetworkTimeout configuration setting is used to define the time, in seconds, that the ASP.NET Web
application will wait for the state server to respond to network requests.
By default, this time is 10 seconds.

3. If we using two IIS server or more, we need setup the same machine key in the web.config on those IIS
<machineKey validation="SHA1" validationKey="
23BEE42193729BD48595EBAFE2C2E765BE77E006330BC3B1392D7C73F" />
  Posted @ 9/1/2006 1:01:37 AM | Hits (27036) | Comment (0

  Post Comment
标题 *
作者 *
密码 记住我
评论 *

Stable in Firefox 1.5 2.0Stable in IE6 IE7Stable in MozillaStable in Netscape V0.1.7507
Powered By ZhangSichu
Copyright © ZhangSichu
Download source code. Download source code