Re: [SYSTEM-LINUX] Finding Memory Leaks : Help please.

From: Justin Adler (spam@WORLD-DOMINATION.COM.AU)
Date: 01/31/02


Thank you kindly for the quick responses already.



>> Make sure you're using bpl20 and not a CVS release.

Ah. I was only using the latest bpl20 (and not the cvs) for testing to see
if by chance it would have had some leaks.  It didn't it seem (using
MemProf). :)

>> See sysdep.h in bpl20.

   Checks for MALLOC .. Wow. Kewl. A huge descriptive Comment. Thank you
guys. Lovely effort.

#define CIRCLE_GNU_LIBC_MEMORY_TRACK    0       /* 0 = off, 1 = on */

Should i turn this on for checking? or/and do the two SHELL commands?




>> Run ElectricFence. (Makefile: "LIBS = -lefence")

Hmmm .. rings a bell ... yeah . i think i tried this before in the past and
had some troubles ... lets see what happens when i do it this time...

[pure@echobase visions]$ ./bin/visions

  Electric Fence 2.2.0 Copyright (C) 1987-1999 Bruce Perens
<bruce@perens.com>
Fri Feb  1 16:50:00 :: Using lib as data directory.
Fri Feb  1 16:50:00 :: Running game on port 1200.  Client running on port
1201
Fri Feb  1 16:50:00 :: Finding player limit.
Fri Feb  1 16:50:00 :: Setting Players & Client limit to 300 using rlimit.
Fri Feb  1 16:50:00 :: Opening mother connection.
Fri Feb  1 16:50:00 :: Opening client connection.
Fri Feb  1 16:50:00 :: Boot db -- BEGIN.
Fri Feb  1 16:50:00 :: Checking to see if we have enough free disk space.
Fri Feb  1 16:50:01 :: Resetting the game time:
Fri Feb  1 16:50:01 ::    Current Gametime: 11H 10D 5M 359Y.
Fri Feb  1 16:50:01 :: Loading state from disk.
Fri Feb  1 16:50:01 :: Initializing mob spells.
Fri Feb  1 16:50:01 :: Reading corpse index.
Fri Feb  1 16:50:01 :: Reading news, credits, help, bground, info & motds.
Fri Feb  1 16:50:01 :: Loading triggers and generating index.
Fri Feb  1 16:50:01 :: 479 records counted.
Fri Feb  1 16:50:08 :: Loading zone table.
Fri Feb  1 16:50:09 :: Loading rooms.

ElectricFence Exiting: mmap() failed: Cannot allocate memory
[pure@echobase visions]$

--damn--
checking my stats, i have 15253 rooms, 3406/2572 obj/proto's and 4988/1960
mob/proto's


>> make your binary, and run it through gdb.

Same thing happens above when i run it in gdb.


>> However, since efence uses a lot of memory you might want to either run
the mud in mini mode (-m), or use a select small world (edit the indexes in
the world file dirs).

Looks like i'm going to have to do that :(


Once again, wish me luck. and thank you for the help so far.
Any questions i will post here as usual ;)

-Justin-

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   | Newbie List:  http://groups.yahoo.com/group/circle-newbies/   |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 06/25/03 PDT