简体   繁体   中英

SQL Server Timeout Accessing ASP.NET Profile Provider

Hmm, strange one: My ASP.NET 2.0 website all of a sudden starts throwing SQL Server timeout errors. Only solution is to reboot SQL Server. IISRESET on web server doesn't fix it.

Error seems to occur when reading (or writing) from ASP.NET user profile.

If I connect to database directly via SQL Server Management Studio, I can read and write to the aspnet_profile table just fine.

When Googling I discovered one suggestion: to make sure there aren't other providers in machine.config and that I've got a CLEAR element in my web.config to clear those out. Sure enough there were. So my first step was to add in CLEARs in my web.config. Did that and still the error. Then I went into machine.config in the .NET 2.0 area and cleared out the SQLexpress entry and the providers (3 of them). Still no dice.

I want to try and solve the root problem without rebooting the database server.

Note that pages that access the database but not the profile work just fine. BTW, there are 2 connection strings - one for the providers (membership, role, profile, and webparts) and the other for the app data access.

Any suggestions????

Thanks, Krip

I believe I've solved the problem. The get and set profile properties stored procedures update the LastActivityDate on the aspnet_users table. This was hanging. Not a good idea to have so many unnecessary udpates on users table. I commented that out and all is fine for the moment.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM