title: Memory profiling for a daemon process
body: <p>I have a daemon process on which I want to perform a memory profile. So I took valgrind as a choice and ran it using massif tool, but since the process never dies, massif never returns the output file. Even I try to send a TERM signal to the process, I am not receiving any output from massif.</p>
  
  <p>So now I tried installing a plugin of valgrind in my eclipse and started trying to run the profile on an already created binary of my daemon process, but when I start the profiler, it says 2 kinds of errors:</p>
  
  <ol>
  <li>failing saying not able to load a library. I didn't find any way to set the library path in the profile configuration.</li>
  <li>failing bad permissions to read a memory address.</li>
  </ol>
  
  <p>So I am not even able to run the profiler in eclipse.</p>
  
  <p>I tried gdb, I tried getting the memory info, but that is what "/proc//maps" would give. So of no use.</p>
  
  <p>Finally here is my use case:</p>
  
  <ol>
  <li>I have a daemon process that never quits and I want to perform memory profiling on it.</li>
  <li>I want to get snapshots of no of memory allocations happened, max memory allocations, which instruction is trying to allocate the most number of allocations etc etc.</li>
  <li>Better if I could get a visual interface for the memory profiling so that I can even share it with my manager.</li>
  </ol>
  
  <p>So please suggest me is there any such profiler that helps and any pointers to where to get the documentation etc.</p>
  
  <p>Thanks in Advance!
  Vinay.</p>