Mono
From OpenSim
Add Mono-related sections here.
Adam's Rebuttal to the Below
The following comments from Miguel are testing an idle region. Idle regions do not suffer as many leaks under Mono, since there is almost zero allocation occuring in an idle region (infact barely anything occurs before). The bug clearly appears to be related to the constant allocation and deallocation of memory; which does not occur until you have users actively participating in the regions.
Idle regions can go for months without needing to be restarted. However.
In a busy or active region - you can clearly see the increase in memory usage on Mono, whereas this does not occur under .NET (or does at a significantly reduced rate). The following chart is from Wright Plaza on OSGrid taken at time of writing - you can clearly see a regular increase in memory usage over time. This occurs daily until the region is restarted. Hosting regions on .NET produces a memory usage curve that is very significantly flatter. (It takes up to 10x longer to reach the same positions.)
Miguel was pointed to this after his initial round of tests, but has not re-run the tests with a non-idle region. OSGrid is currently in the process of running some tests with some control regions to provide evidence of the fundemental disconnect between Mono and .NET in terms of memory usage in OpenSimulator.
It remains my firm belief that if you are professionally hosting OpenSimulator regions on Mono, you should allocate double-or-more the amount of physical RAM as allocated a Windows/.NET machine.
Mono Memory Myths
Experience with Mono in Opensim has led to the widespread belief that Mono on Linux is an extreme memory hog compared to .NET on MS Windows. This belief has been countered by the creator of Mono, Miguel de Icaza, after he performed direct tests on 14th June 2009 in Vista 32, Linux 32, and Linux 64. His results and advice were posted on pastebin, and are repeated here since that site is not intended for persistent publication:
A third follow up. With the help from the guys on #opensim on irc.freenode.org I got myself a sample virtual world from: http://opensimworlds.com/index.php?part=worlds I used "Nu Athens" a free download and loaded it up on 3 configurations: Vista, running 32 bit OpenSimulator Linux, running 64 bit OpenSimulator Linux, running 32 bit OpenSimulator And then I loaded all the four files provided in the zip file using the command: load oar FILE.tar.gz The results are as follows: Vista/32: 115 megs + 5 meg helper process (OpenSim.vhost.exe) Mono/32: 92 megs, after a few minutes of inactivity, it goes down to 87 megs. Mono/64: 122 megs, after a few minutes of inactivity, it goes down to 89 megs. The garbage collector is responsible for the difference in memory usage between the load finished and waiting (I ran into this problem because I came to measure again after a few seconds and the size had been reduced). The Vista system remains at 120 megs total for the same world. So Mono on Linux on both 32 and 64 bit configurations is consuming less memory than Vista, some 40 megs out of 120, or one third less memory. Perhaps the difference is in the version of Mono that we are running. I am running with Mono 2.4, and the OpenSimulator documentation implies that OpenSimulator can work with systems like Mono 1.2.6 which is primitive by our standards (that was released more than two years ago). In Mono 2.0, Mono 2.2 and Mono 2.4 we introduced many memory reduction features. From using precise collection for the HEAP, to reducing the size of generics-heavy code to reduction in code size generated and runtime metadata tables. I would appreciate if you could post a correction to your data in the main article, as it seems to have spread and this could negatively impact the perception of the Mono's community work towards making a great .NET implementation for Unix. Miguel
