Fixing The given key was not present in the dictionary

book

Article ID: 48825

calendar_today

Updated On:

Products

APPLICATION DELIVERY ANALYSIS SUPERAGENT

Issue/Introduction

Description:

ISSUE

Attempting to accesss the SuperAgent web interface results in this error:

Server Error in '/SuperAgent' Application.
________________________________________

The given key was not present in the dictionary.

In addition to this, the SA Collector service failes to start, with this error in SACollectorErrorsDATE.log:

11:15:14 Severity 2 - FetchFeedsByProbe: web service call failed with status 12, url:
http://ipaddress/SuperAgentInternal/SAConfigWS.asmx

DETAILS

These problems are the result of a failed migration during the upgrade (likely caused by an unidentified defect in the code).

The full error texts are as follows. Server Error in '/SuperAgent' Application.
________________________________________

The given key was not present in the dictionary.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information about
the error and where it originated in the code.

Exception Details: System.Collections.Generic.KeyNotFoundException: The given
key was not present in the dictionary.

Source Error:
An unhandled exception was generated during the execution of the current web
request. Information regarding the origin and location of the exception can
be identified using the exception stack trace below.

Stack Trace:
[KeyNotFoundException: The given key was not present in the dictionary.]
System.ThrowHelper.ThrowKeyNotFoundException() +28
System.Collections.Generic.Dictionary`2.get_Item(TKey key) +55
NetQoS.Inspector.Database.ProbeFeeds.FetchByProbe(Nullable`1 probeId, Int32& feedCount) +511
NetQoS.Inspector.Database.ProbeFeeds.FetchByProbe(Nullable`1 probeId) +31
NetQoS.SuperAgent.Web.FeedListEngine.GetListOfFeeds(ProbesRow probes) +144

NetQoS.SuperAgent.Web.CollectorProps.InitializeAndDisplayFeedsGrid(ProbesRowprobes) +40
NetQoS.SuperAgent.Web.CollectorProps.Page_PreRender(Object sender,
EventArgs e) +673
System.Web.UI.Control.OnPreRender(EventArgs e) +2066956
System.Web.UI.Control.PreRenderRecursiveInternal() +77
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Control.PreRenderRecursiveInternal() +161
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1360
________________________________________
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET
Version:2.0.50727.42

********** SACollector **********
11:15:14 Severity 1 - SACollector starting up
11:15:14 Severity 2 - Precision timer frequency is 2,582,239,451,372 ticks per
11:15:14 Severity 2 - FetchFeedsByProbe: web service call failed with
status 12, url: http://ipaddress/SuperAgentInternal/SAConfigWS.asmx
11:15:14 Severity 2 - hr_test failure 0x80004005 Unspecified error at .\SACollector.cpp
11:15:14 Severity 2 - hr_test failure 0x80004005 Unspecified error at .\SACollector.cpp 709
11:15:14 Severity 2 - hr_test failure 0x80004005 Unspecified error at .\SACollector.cpp 834
11:15:14 Severity 2 - hr_test failure 0x80004005 Unspecified error at .\SACollector.cpp 322
11:15:14 Severity 1 - Shutting Down

Solution:

Backup the probes, probe_feeds, and monitored_servers tables, and then truncate these same tables. You will need to reconfigure collection devices and feeds after this, but it should resolve the web page error and service failures.

Environment

Release:
Component: NQSPRA