Deleting sub-directories (folders) in ASP.NET 2.0 restarts the AppDomain

All the while I thought that the AppDomain only restarts when the
web.config, global.asax, bin folder (or it’s contents) is changed and
if there are considerable number of files have changed (15 is the magic
number as they say but can’t verify).

All the while I was wrong,
by default (that is without tweaks), deleting a folder under your
application will restart the AppDomain (implies but not limited to
clearing all sessions, cache etc).

Took me a considerable time to trace the issue I have more than guesses on what’s messing the application.
http://weblogs.asp.net/owscott/archive/2006/02/21/ASP.NET-v2.0-_2D00_-AppDomain-recycles_2C00_-more-common-than-before.aspx
http://objectsharp.com/cs/blogs/bruce/archive/2004/11/01/992.aspx
http://blogs.msdn.com/toddca/archive/2005/12/01/499144.aspx

And
thanks to Performance Monitor (Start > Run > perfmon or
Adminstrative Tools > Performance) for the hints that there is
something messing with my sessions and cache.

SSL and SQL Server 2005

Getting an "error occured during the pre-login handshake". in SQL Server?

I just spent the last few hours trying to figure out why I can't connect to my local SQL 2005 instance and getting the error above. I was using SQL Management Studio.

I tried tweaking Network/Client Configuration, Protocols using SQL ConfigurationManager, Surface Area Configuration and the error messages changed from one to another but still no luck. Some claim that this issue was solved by changes to protocols but it wasn't my case. [more]

I looked for answers in the net and didn't quite get what was wrong.

But this first link helped (common SQL protocol issues/errors)
http://blogs.msdn.com/sql_protocols/archive/2005/10/22/483684.aspx

And then I ended up with these post and the symptoms matched my issue (especially when I connected using MDAC – Admin > ODBC Sources)
http://blogs.msdn.com/sql_protocols/archive/2006/07/26/678596.aspx

As soon as I saw the 2nd link above, I knew I'm close plus the fact that I've been working on creating and assigning SSL certifcate for my local IIS using SelfSSL (comes with IIS Resource Kit). It's weird though that it was only today that I encountered it, probably something I did before I slept last night.

It took me more time to fix the issue though (even after following the instructions; that is clearing my user certificates via certmgr.msc). When opening the SQL Configuration Manager and checking for the available certificates, two certificates still appear. I just deleted them using certmgr.msc but they're still there. After a few more minutes of headache, I opened mmc.exe, added the "Certificates" snap-in and there I saw that two other certificates that weren't removed (even if it no longer exists in certmgr.msc). I think this has something to do with "local machine versus user certificate personal store". certmgr.msc is the personal store, while you could open the local machine certs by the "Certificates" snap-in in MMC. Not sure but clearing the local certs from the MMC snap-in, then restarted SQL Service did the trick for me.

Also, it's worth noting that when generating a certificate using SSL, it seems to help avoid this issue if you DON'T use the machine name (it is the default) and instead specify the domain or maybe even the localhost (using the CN switch)

I'll revisit this post next time (yeah I know, my thoughts are scattered) but just wanted to post it incase someone comes across it and despite finding the links still got into the issues I encountered. If you have any questions, feel free to contact me.

I thought of restoring a previous image of my system but where's the thrill in that. And besides, did learn a lot from this.

Also, tried to "google" the "error occured during the pre-login handshake" again just now and did return some posts (on SSL issue hints) which I didn't see when I started poking into this. I think keyed in the wrong keywords. So be careful when googling for the right phrase. And when getting weird/vague errors in SQL, visit the 1st link I gave above, or try connecting using different approaches (MDAC, SSMS or ADO.NET).

Also check this out http://support.microsoft.com/kb/900497. If the above doesn't work then try clearing (not deleting) the Certificate registry entry mentioned in the article

Have to get back to work, been stalled long enough.

Tool List

Aside from essentials installations here are some of the application I have on my PC which proved useful to me so you might as well look into.
Will post the links soon.

General

  • TimeSnapper Pro
  • Diskeeper Pro Premier
  • Ad-Aware (Free)
  • Spybot S&D (Free)
  • Windows Defender
  • Zone Alarm (just turned Pro)
  • HiJackThis (Trend Micro)
  • RSSReader
  • TuneUp Utilities 2007
  • PrimoPDF
  • SnagIt 8
  • FastFolders

Dev Tools

  • Reflector
  • DbgView (sysinternals)
  • Process Monitor (sysinternals)
  • Process Explorer (sysinternals)
  • IECookiesView (nirsoft)
  • TcpView (sysinternals)
  • IIS Resource Kit
  • IIS Diagnostics Kit
  • FileZilla 3.0
  • Fiddler2
  • MBSA 2.0.1
  • Virtual PC 2007

Microsoft Second Shot Exams are back

http://www.microsoft.com/learning/mcp/offers/secondshot/default.mspx

Testing Centers in the Philippines:

http://www.microsoft.com/philippines/learning/ (these are learning centers but they are the most common exam centers too)
http://www.register.prometric.com/ClientProgram.asp
(list from Prometric, just follow the links)

Microsoft Learning start page
http://www.microsoft.com/learning/default.mspx

According to the FAQ, “You must take the first exam between September 15,
2007 and January 30, 2008. If you don’t pass, you can retake the same exam at no additional charge before January 31, 2008”.
Also, depending on other available offers (discounts etc), there might be other dates where the exams will cost even less (ask exam centers/providers) so plan ahead if you’re thinking of taking an exam.
For first time takers, prepare your best and don’t be afraid to fail. It might not be that easy on the pocket but know your stuff and passing the exam will follow.
Oh and no cheats or braindumps please…

Welcome to my new Tech Blog

I have my tech blog setup at last (need a little more modifications like themes etc but it's here).

I was thinking of coding the blog features myself but I figured it would require more than I currently have so I'm using BlogEngine.NET instead. It will also be a good way for me to get to know the project better. Looks good so far.

Ran into contact email configuration issues to but thanks to this post I had it working. I don't think I have email included with this hosting so I used my gmail account for "email" and "username" fields and seems to get to my inbox fine so guess it works.

I'll try my best to update this blog as often as I could with stuff I ran into while working with .NET, SQL Server and other cool stuff about the internet. And hope that it will be helpful resource someday to someone and to myself when I forgot how I did things in the past.

Enjoy. I will 🙂