Compile Pike with --with-valgrind if you want to run valgrind on it.
/ Martin Nilsson (DivX Networks)
Previous text:
2004-09-26 22:55: Subject: memory leak in oracle module
[i moved this discussion to the developers' forum as i think it is more suitable for my problem.]
thanks to martin and marcus for your hints for debugging. unfortunately it did not bring any results.
what i did so far:
- i discovered a memory-leak when i use roxen 4+ or chilimoon running
with pike 7.4.*, 7.6.* (i have tested many different releases and fresh from cvs). this happens with a website connecting to an oracle db. memory demand grew to several hundred MBs within an hour or two of rather heavy requests.
this has been reproduced on three different hosts (all running linux).
roxen / debug information / Pike memory usage information shows more
or less constant memory demand (total: 12000 kB).
- the same website on roxen Pike v7.2 release 543 shows no memory leaks
(constant memory demand ~38 MB). i used the same oracle libraries so i guess they are not leaking.
- compiling pike 7.6 with-dmalloc and running roxen with: twice i
managed to run and exit roxen cleanly but i got no memory leaks reported (last message was "counting bytes")
- running hilfe with pike 7.6 with-dmalloc and doing some queries on
oracle did also not report any memory leaks after exiting normally.
- tried to run roxen or pike with valgrind but it failed. # valgrind --leak-check=yes --trace-children=yes --tool=memcheck
(see error messages below)
i have never used valgrind before and could not find any hints with google. anybody else knows how to use valgrind with pike?
any further advice?
/michael
=====8<=====8<=====8<=====8<===== pike error messages when running with valgrind:
/usr/local/pike/7.6.25/lib/master.pike:396: Failed to index module 'Files' with 'Stat' (module doesn't exist?) /usr/local/pike/7.6.25/lib/master.pike:1322: Failed to index module 'Files' with 'Stat' (module doesn't exist?) /usr/local/pike/7.6.25/lib/master.pike:2212: Failed to index module 'Files' with 'Stat' (module doesn't exist?) /usr/local/pike/7.6.25/lib/master.pike:2225: Cannot inherit program which is not fully compiled yet. /usr/local/pike/7.6.25/lib/master.pike:2230: Cannot inherit program which is not fully compiled yet. /usr/local/pike/7.6.25/lib/master.pike:3863: Failed to index module 'Builtin' with 'array_iterator' (module doesn't exist?) /usr/local/pike/7.6.25/lib/master.pike:4231: Cannot inherit program which is not fully compiled yet. /usr/local/pike/7.6.25/lib/master.pike:4238: No inherit or surrounding class Encoder. /usr/local/pike/7.6.25/lib/master.pike:4243: Cannot inherit program which is not fully compiled yet.
/ Michael J. Stenitzer