Partilhar via


Hashtable insert failed. Load factor too high

I just got involved in a case where a customer of mine was hitting the following exception on .Net Framework 2.0.

Exception information:

    Exception type: InvalidOperationException

    Exception message: Hashtable insert failed. Load factor too high.

   

The callstack for the faulting thread is:

System.Collections.Hashtable.set_Item()
System.Runtime.Serialization.SerializationEventsCache.GetSerializationEventsForType()
System.Runtime.Serialization.ObjectManager.RaiseOnDeserializingEvent()
System.Runtime.Serialization.Formatters.Binary.ObjectReader.ParseObject()
System.Runtime.Serialization.Formatters.Binary.ObjectReader.Parse()
System.Runtime.Serialization.Formatters.Binary.__BinaryParser.ReadObjectWithMapTyped()
System.Runtime.Serialization.Formatters.Binary.__BinaryParser.ReadObjectWithMapTyped()
System.Runtime.Serialization.Formatters.Binary.__BinaryParser.Run()
System.Runtime.Serialization.Formatters.Binary.ObjectReader.Deserialize()
System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize()

<<snip>>

Searching around on the Internet I found others too that were hitting this issue. This appears similar to 831730 which is a 1.1 fix, however that fix was checked into the RTM build of 2.0 so we have another issue here. The good news is we have a fix for this issue however we DO NOT have a KB article for it just yet (I am working to correct that now). We have a race condition that is causing this issue and the fix will correct it. The hotfix package is 927579. Yea this KB article and hotfix package does not look like a fix for the above issue however what we need to understand here is that fixes are checked into our source control in a cumulative manner. So as long as the fix is checked in and you get a binary that was built that includes that source after this check-in date you inherit the fix.

So if you are hitting this issue, which seems to be most prevalent in ASP.Net environments, you should call into Microsoft Support and request the hotfix for 927579.

Comments

  • Anonymous
    February 26, 2007
    Todd - I'm seeing this condition on Win2k3 SP1 when running a web service application under v1.1 of the Framework.  We have mixed 1.1 and 2.0 applications running in a hosted environment. All of my research shows that this should have been resolved, but apparently it has not.  After an iisreset /restart the problem has gone away, but I'm afraid it will come back.   You can email me: chuck at edgemediadesign dot com if you have questions about our situation.

  • Anonymous
    June 19, 2007
    I recently deployed an application to a production web farm for a client and everything has been relatively