Re: Mono memory problems!

"Alan McGovern" <[email protected]> Wed, 18 Jul 2007 10:50:20 -0400
Newsgroups gmane.comp.gnome.mono.devel,gmane.comp.gnome.mono.garbage-collection
Message-ID <[email protected]>
--===============0350621675==
Content-Type: multipart/alternative; 
	boundary="----=_Part_68996_7872991.1184770220560"

------=_Part_68996_7872991.1184770220560
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Well, after 12 hours at a consistent 25kB/sec, you'd expect to have over 1
gig of memory allocated. As you don't, i think what you're seeing is just
'normal usage' for the non-compacting GC that mono uses. I have a similar
app which uses sockets extensively (50-150 simultaneous connections)  and i
can assure you that memory usage doesn't get unbearably large. It'd be
interesting to see the logs but i don't think there's much to be worried
about.

Alan.

On 7/18/07, David Wolinsky <[email protected]> wrote:
>
> Initially 45 MB, 12 hours later 147 MB
>
> Another developer has the heap-shot logs, I'll post those as soon as
> possible.
>
> David
>
> Alan McGovern wrote:
> > Could you post up the detailed stats from heapshot? After the 12 hour
> > run, how much memory are you using? Are we talking in the gigabyte
> > range, or megabyte range?
> >
> > Alan.
> >
> > On 7/18/07, *David Wolinsky* <[email protected]
> > <mailto:[email protected]>> wrote:
> >
> >     My lab works on a peer-to-peer network overlay and we've noticed
> >     recently significant memory issues.  Some background...
> >
> >     This application is constantly creating new objects and shortly
> >     thereafter deleting (removing reference to) them
> >     Using a sample run with 150 threads running...
> >     Mono on Linux has a growth rate of ~25 KB per second with a base
> >     of 50MB
> >     (y = 25K *x + 50M)
> >     .NET on Windows stabilizes at 35 MB
> >
> >     We ran heap-shot with Linux and found that in a 12 hour period it
> >     reported this...
> >     start:
> >     objects: 58,823
> >     heap memory: 6,838,426 bytes
> >
> >     end:
> >     objects: 59,925
> >     heap memory: 6,862,336
> >
> >     We have run mono with GC_MAXIMUM_HEAP_SIZE and the memory size
> >     (RES) got
> >     significantly bigger than it.
> >
> >     I have searched for the Compacting GC with no luck, we would
> >     really like
> >     to see if it would help our problem.
> >
> >     The only operating system resources we're using are Sockets, but
> >     we use
> >     them VERY heavily!
> >
> >     If anyone has any suggestions, we'd be open to test out anything
> >     at this
> >     point!
> >
> >     We are leaning towards an issue in unmanaged memory and possibly a
> bug
> >     in mono.
> >
> >     Best regards,
> >     David
> >
> >
> >     ps, I fwded this to gc and devel list because gc list looks quite
> >     dead.... sorry for the duplication
> >     _______________________________________________
> >     Mono-devel-list mailing list
> >     [email protected]
> >     <mailto:[email protected]>
> >     http://lists.ximian.com/mailman/listinfo/mono-devel-list
> >
> >
>
>

------=_Part_68996_7872991.1184770220560
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Well, after 12 hours at a consistent 25kB/sec, you&#39;d expect to have over 1 gig of memory allocated. As you don&#39;t, i think what you&#39;re seeing is just &#39;normal usage&#39; for the non-compacting GC that mono uses. I have a similar app which uses sockets extensively (50-150 simultaneous connections)&nbsp; and i can assure you that memory usage doesn&#39;t get unbearably large. It&#39;d be interesting to see the logs but i don&#39;t think there&#39;s much to be worried about.
<br><br>Alan.<br><br><div><span class="gmail_quote">On 7/18/07, <b class="gmail_sendername">David Wolinsky</b> &lt;<a href="mailto:[email protected]">[email protected]</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Initially 45 MB, 12 hours later 147 MB<br><br>Another developer has the heap-shot logs, I&#39;ll post those as soon as<br>possible.<br><br>David<br><br>Alan McGovern wrote:<br>&gt; Could you post up the detailed stats from heapshot? After the 12 hour
<br>&gt; run, how much memory are you using? Are we talking in the gigabyte<br>&gt; range, or megabyte range?<br>&gt;<br>&gt; Alan.<br>&gt;<br>&gt; On 7/18/07, *David Wolinsky* &lt;<a href="mailto:[email protected]">[email protected]
</a><br>&gt; &lt;mailto:<a href="mailto:[email protected]">[email protected]</a>&gt;&gt; wrote:<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; My lab works on a peer-to-peer network overlay and we&#39;ve noticed<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; recently significant memory issues.&nbsp;&nbsp;Some background...
<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; This application is constantly creating new objects and shortly<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; thereafter deleting (removing reference to) them<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Using a sample run with 150 threads running...<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Mono on Linux has a growth rate of ~25 KB per second with a base
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; of 50MB<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; (y = 25K *x + 50M)<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; .NET on Windows stabilizes at 35 MB<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; We ran heap-shot with Linux and found that in a 12 hour period it<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; reported this...<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; start:
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; objects: 58,823<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; heap memory: 6,838,426 bytes<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; end:<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; objects: 59,925<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; heap memory: 6,862,336<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; We have run mono with GC_MAXIMUM_HEAP_SIZE and the memory size
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; (RES) got<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; significantly bigger than it.<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; I have searched for the Compacting GC with no luck, we would<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; really like<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; to see if it would help our problem.<br>
&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; The only operating system resources we&#39;re using are Sockets, but<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; we use<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; them VERY heavily!<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; If anyone has any suggestions, we&#39;d be open to test out anything
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; at this<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; point!<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; We are leaning towards an issue in unmanaged memory and possibly a bug<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; in mono.<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Best regards,<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; David<br>&gt;<br>&gt;<br>
&gt;&nbsp;&nbsp;&nbsp;&nbsp; ps, I fwded this to gc and devel list because gc list looks quite<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; dead.... sorry for the duplication<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; _______________________________________________<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Mono-devel-list mailing list
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; <a href="mailto:[email protected]">[email protected]</a><br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;mailto:<a href="mailto:[email protected]">[email protected]</a>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
<a href="http://lists.ximian.com/mailman/listinfo/mono-devel-list">http://lists.ximian.com/mailman/listinfo/mono-devel-list</a><br>&gt;<br>&gt;<br><br></blockquote></div><br>

------=_Part_68996_7872991.1184770220560--

--===============0350621675==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Mono-devel-list mailing list
[email protected]
http://lists.ximian.com/mailman/listinfo/mono-devel-list

--===============0350621675==--