Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 10 of 13 total
Thread ElevateDB Error #9999 Out of memory.
Wed, Jul 26 2017 6:53 PMPermanent Link

Steve Gill

Avatar

One of my clients gets this error message occasionally: "ElevateDB Error #9999 Out of memory".

My applications produce their own log files and I found this in a couple of the logs when he reported a problem with my software.

I couldn't find this in the EDB manual so I'm guessing it's being passed through from the OS.  I'm assuming that he has too many applications opening and is out of system resources, but I thought I'd mention it here in case anyone else has come across it.

= Steve
Thu, Jul 27 2017 2:21 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Steve


There can be many reasons for this error - memory fragmentation, not freeing instatiated components/classes, some forms of data corruption (I have experienced it with loading jpgs) continuously extending a string.  It can be a bit of a nightmare to find. You have my sympathy.

Roy Lambert
Thu, Jul 27 2017 10:23 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Steve,

<< One of my clients gets this error message occasionally: "ElevateDB Error #9999 Out of memory".

My applications produce their own log files and I found this in a couple of the logs when he reported a problem with my software.

I couldn't find this in the EDB manual so I'm guessing it's being passed through from the OS.  I'm assuming that he has too many applications opening and is out of system resources, but I thought I'd mention it here in case anyone else has come across it. >>

As Roy says, something is fragmenting or not releasing memory, and that will eventually cause this error.

Are you using the EDB Server or the embedded engine ?  If the latter, then I would try using your application with the memory leak checking in Delphi turned on and see if anything shows up during application shutdown.  Normally, it's pretty easy to find such leaks by just using the application.

Tim Young
Elevate Software
www.elevatesoft.com
Fri, Jul 28 2017 12:40 AMPermanent Link

Steve Gill

Avatar

<< There can be many reasons for this error - memory fragmentation, not freeing instatiated components/classes, some forms of data corruption (I have experienced it with loading jpgs) continuously extending a string.  It can be a bit of a nightmare to find. You have my sympathy. >>

Thanks Roy.  It's no doubt something stupid I've done.

= Steve
Fri, Jul 28 2017 12:45 AMPermanent Link

Steve Gill

Avatar

<< As Roy says, something is fragmenting or not releasing memory, and that will eventually cause this error.

Are you using the EDB Server or the embedded engine ?  If the latter, then I would try using your application with the memory leak checking in Delphi turned on and see if anything shows up during application shutdown.  Normally, it's pretty easy to find such leaks by just using the application.  >>

I'm using the embedded engine in my own server application that runs only as a service.  The server has quite a few additional features to the standard EDB Server.

I tried the memory leaking checking but I'm now trying EurekaLog to see if it can help pinpoint any issues.

= Steve
Fri, Jul 28 2017 3:15 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Steve


There was one recently on the Embarcadero forums - turned out to be in a module which kept on adding to a string and the string was never reset to '' although it should have been. A major part of the problem was that the out of memory error was shown at a different place. Something like that is not going to be spotted as a memory leak because it isn't Frown

Roy Lambert
Fri, Jul 28 2017 11:44 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Steve,

<< Thanks Roy.  It's no doubt something stupid I've done.  >>

Not necessarily.  EDB has had a few memory leaks over the years... Frown

Tim Young
Elevate Software
www.elevatesoft.com
Fri, Jul 28 2017 11:50 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Steve,

<< I tried the memory leaking checking but I'm now trying EurekaLog to see if it can help pinpoint any issues. >>

Please report back anything that you find.  Hopefully, whatever it is turns out to be egregious. Those issues are *way* easier to track down than issues that are just "slightly bad".  Those types of issues can go on for months without exhibiting any symptoms and then BAM !!!, leaving you with little to no information about the original cause.

Personally, what I try to do is to immediately do an "honesty check" on the code and try to put logging around areas of the code that *might* be responsible for such issues.  Code that is particularly complicated, multi-threaded, or explicitly allocates/deallocates memory are all good candidates for logging.  You can also use the tracing code in the EDB Server as an example of how to do high-performance tracing using a separate work thread for persisting the trace messages.  It's in the main.pas unit for the EDB Server project.

Tim Young
Elevate Software
www.elevatesoft.com
Sat, Jul 29 2017 2:57 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Steve


What Tim said plus if you do have a line number at which the out of memory occurs look downstream of that. The most likely series of events is something ALMOST filling up or fragmenting memory then a later event (object creation, sting catenation etc) actually triggering the error even though its not the root cause.

Roy Lambert
Mon, Jul 31 2017 3:47 AMPermanent Link

Steve Gill

Avatar

Hi Tim and Roy,

Thank you for the great advice!

= Steve
Page 1 of 2Next Page »
Jump to Page:  1 2
Image