Ok, another day of messing around with this has produced some rather bizarre results.
I've stripped the code down to a "bare minimum", and am still running into issues:
foreach (sort keys %tickets) { my $ticket = ((split " ",$_)[0]); my %tick_inf; (%tick_inf = ars_GetEntry($rem,$schema,$ticket)) || warn "Could not retrieve $ticket: $ars_errstr"; ++$count; print "$count\n"; next; #all the other stuff from yesterday }
Note that I added the $count lines in there.

The results show that we are still chewing up huge amounts of memory, but at two different times. I ran this with a small subset of entries (about 700). At the start of the foreach loop, the memory usage steadily climbed to about 225 meg, about 100 tickets had been retrieved, then it started to drop, and ran the rest of the time at about 50 meg used.

What REALLY astonished me was at the end of the script. The last lines that I have in the script (immediately following the subroutine calls to the sub that this loop is in) read as:
print "Script ended on " . localtime(time); print "\n";
But for some reason, once I saw the print-out saying that it ended, the memory usage jumped BACK up to 225 meg, and the script took another 2 or 3 minutes to exit. WTF is that? Clearing the buffer or something along those lines?? There is honest to god NOTHING else after those lines above, yet I clearly saw the output before the memory usage jumped back up.

The first portion above is pretty consistent with what I was seeing previously, the second thing to me is really bizarre. -- HELP -- :-)

In reply to Re: Memory usage & hashes of lists of hashes of lists by the_slycer
in thread Memory usage & hashes of lists of hashes of lists by the_slycer

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.