Memory profiling: Difference between revisions

From OpenPetra Wiki
Jump to navigation Jump to search
(Created page with '== Mono == We have had an issue (https://sourceforge.net/apps/mantisbt/openpetraorg/view.php?id=107) where the OpenPetra server crashes after a while, running on Mono, due to gro…')
 
 
(3 intermediate revisions by the same user not shown)
Line 4: Line 4:
See this article: http://www.mono-project.com/Performance_Tips#Using_the_Mono_profiler
See this article: http://www.mono-project.com/Performance_Tips#Using_the_Mono_profiler


Also see this: http://www.mono-project.com/HeapShot
Also see this: http://www.mono-project.com/HeapShot and http://www.mono-project.com/Profile


to get the process id, type  
to get the process id, type  
Line 16: Line 16:
  USER      PID %CPU %MEM    VSZ  RSS TTY      STAT START  TIME COMMAND
  USER      PID %CPU %MEM    VSZ  RSS TTY      STAT START  TIME COMMAND
  me        7220 20.6  4.6  93704 36744 pts/0    Sl+  11:42  0:25 mono --server -
  me        7220 20.6  4.6  93704 36744 pts/0    Sl+  11:42  0:25 mono --server -
Add <code>--profile=default:alloc</code> to the mono call in your openpetraorg-server.sh. then in the long result, look for "Allocation profiler" heading
=== Heap Shot on Ubuntu ===
apt-get install autoconf make libtool subversion gtk-sharp2-gapi
then follow the instructions at http://www.mono-project.com/HeapShot
http://developer.mindtouch.com/User:PeteE/Heap_Shot_Notes has this useful hint, otherwise it is not installed correctly
./autogen.sh --prefix=/usr

Latest revision as of 13:39, 27 February 2010

Mono

We have had an issue (https://sourceforge.net/apps/mantisbt/openpetraorg/view.php?id=107) where the OpenPetra server crashes after a while, running on Mono, due to growing need for memory and running out of memory eventually.

See this article: http://www.mono-project.com/Performance_Tips#Using_the_Mono_profiler

Also see this: http://www.mono-project.com/HeapShot and http://www.mono-project.com/Profile

to get the process id, type

ps -A | grep mono

result:

7220 pts/0    00:00:25 mono

then display the current memory usage:

ps up 7220

result:

USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
me        7220 20.6  4.6  93704 36744 pts/0    Sl+  11:42   0:25 mono --server -

Add --profile=default:alloc to the mono call in your openpetraorg-server.sh. then in the long result, look for "Allocation profiler" heading

Heap Shot on Ubuntu

apt-get install autoconf make libtool subversion gtk-sharp2-gapi

then follow the instructions at http://www.mono-project.com/HeapShot

http://developer.mindtouch.com/User:PeteE/Heap_Shot_Notes has this useful hint, otherwise it is not installed correctly

./autogen.sh --prefix=/usr