Dhanaraj M

Wednesday Aug 29, 2007

Memory leak problem- An interesting solution

I came across a memory leak problem. It is interesting that Solaris 10 provides a very good mechanism with the help of libumem.so library and mdb debugger to solve this problem. The following steps help to identify memory leaks.

  • $export LD_PRELOAD=libumem.so
  • $export UMEM_DEBUG=default
  • $ mdb  ./myTest
  • > ::sysbp _exit
  • > ::run
  • > ::findleaks

If you find the following error message

  • "mdb: invalid command '::findleaks': unknown dcmd name"

then the workaround is

  • >::load libumem.so

Comments:

Post a Comment:
  • HTML Syntax: NOT allowed

Calendar

Feeds

Search

Links

Navigation

Referrers