As a follow-up to my earlier post about crashing the SQL Server 2005 Database Tuning Advisor, I later discovered that the .NET exception stack trace was logged to the Application event log.

My suspicions were correct: it is a threading bug, and it turns out that the steps are even simpler:

  1. Start the Database Engine Tuning Advisor
  2. Drop down the “Server name” listbox and choose “Browse for more…”
  3. Click the Network Servers tab
  4. Click the Cancel button
  5. Wait a few seconds … until the application crashes…

The background discovery thread tries to access the TreeView control in the browse dialog, which no longer exists since you closed it. Oops. I’m not sure how this one got past QA. I passed the info on to friends in the SQL Server group, and probably ruined their days.

%d bloggers like this: