Cuberite Forum
rev 1293 - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Cuberite (https://forum.cuberite.org/forum-4.html)
+--- Forum: Discussion (https://forum.cuberite.org/forum-5.html)
+--- Thread: rev 1293 (/thread-826.html)

Pages: 1 2 3 4 5


rev 1293 - keyboard - 03-22-2013

Hi All,

Has anybody tried the rev 1293? I'm experiencing a "bad_alloc at memory location" error when connecting clients to the MCServer.


RE: rev 1293 - NiLSPACE - 03-22-2013

no it works fine for me.


RE: rev 1293 - keyboard - 03-22-2013

Are you using the floody simulator? I switched the server to noop, and it now loads Smile


RE: rev 1293 - NiLSPACE - 03-22-2013

yes i'm using Floody ;O


RE: rev 1293 - keyboard - 03-22-2013

mmmm, interesting, then it must be my machine hehe.


RE: rev 1293 - ThuGie - 03-22-2013

Perhaps give some info about what os your running :p.
Stuff on windows might not work on linux Wink.


RE: rev 1293 - keyboard - 03-22-2013

I'm running Windows 7, 64 bit. I compiled it with Visual Studio 2012.

I ran a quick check in process explorer, and I found out that MC Server is going up to 1.9gb of memory used before I get the error. Check out the attached image.


RE: rev 1293 - xoft - 03-22-2013

That would be the cause - since MCServer is compiled as a 32-bit process, it runs out of memory at 2 GiB. So what you're getting is an out-of-memory.

Now, the question is, why?

Can you reproduce and then when it hits the debugger, check the cFloodyFluidSimulator::m_TotalBlocks value? You'll probably have to jump through hoops to get it, I suppose something like cRoot::Get()->m_pDefaultWorld->m_WaterSimulator as a watch expression would give you access to it. Normally for freshly generated worlds it can go as high as 200k, but if it's much more, then something's probably wrong.

Also, I think it'd be helpful in this case if you gave us the entire world folder zipped up, and your player's config file ($/MCServer/players/<playername>.json ) so that we can replicate this.


RE: rev 1293 - keyboard - 03-23-2013

Yeah, that's what I figured when I saw that it went to 1.9gb of memory used Sad

I tried disabling just the lava simulator and leaving the water simulator as floody, and the error did not occur. So, it might be something going on with the lava sym.

I attached my world and my json file. Wow, the forum gives a maximum of 1024kb for attachments, so I had to split it in chunks. Just in case, I used 7zip to split it, and then manually added the .zip extension at the end so the forum would let me post it.


RE: rev 1293 - xoft - 03-23-2013

The lava and water simulators use the very same engine (if they are set to the same value, Floody in this case). Disabling one may have alleviated the issue because there are no longer that many blocks to simulate.

I'll try your world in a moment, I've just found a bug in the block update code that I want to fix first (water didn't dry up properly because of it)