Installing memusage on Ubuntu
For some annoying reason, Ubuntu does not package memusage
in their libc.
- Download a version of glibc that’s old enough to match your version of Ubuntu.
- Compile and install into a destination that’s not
/usr/local
, I usedPREFIX=~/glibc
. Weird compiler errors probably means you need to try an older version. - Add
$PREFIX/bin
to your$PATH
. In$PREFIX/bin/libmemusage
you might have to change thememusageso=...
line to wherelibmemusage.so
lives ($PREFIX/lib/libmemusage.so
) for the script to run successfully.
Speaking from experience: keep this thing far, far away from /usr
or
/usr/local
or else you might brick your machine when you ldconfig
and your
entire system links into this glibc.
Maybe the real solution is to use Debian :-).
back up
Email me questions or comments at !