I have a script that runs 7 days a week 24 hours a day monitoring oracle databases.

In years past Oracle client libraries were notoriously leaky. In Oracle 7 it was possible to leak large chunks of memory simply by repeatedly connecting and disconnecting from the database. I've heard third-hand reports of leaks with Oracle 8 libraries, but have no first-hand knowledge.

Try this: To rule out Oracle as the culprit, set up a script that does nothing but connect and disconnect, and note its memory profile over a few hours of running.

Next, set up a script that repeatedly issues the same queries in the same that your production script does, but without storing any results in Perl data structures (this should rule out your code as the source of the leaks). If this doesn't demonstrate a leak, the culprit is your code. If it does show a leak, try some of the advice above (finish your queries, etc.)

Oh, and verifying that you're running the latest Oracle client libraries is usually a good idea.


In reply to Re: any way to control a memory leak by dws
in thread any way to control a memory leak by rdww

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.