Tagsistant

All your files, quickly and easily.
Using Valgrind on FUSE filesystems
Tuesday, 19 August 2008 15:12

Hunting memory leaks, I've faced the problem of using Valgrind on a FUSE filesysem. Since fusermount is a SUIDed executable, Valgrind somehow interfere with filesystem mounting.

Here is a solution I've found searching on the Net:

# cd /usr/bin
# if [[ -e fusermount ]]; then mv fusermount fusermount.real; fi
# touch fusermount
# chown root.fuse fusermount
# chmod ug+x fusermount
# echo '#!/bin/sh' >> fusermount
# echo 'exec /usr/bin/fusermount.real $@' >> fusermount
[ or depending on the path of fusermount ]
# echo 'exec /bin/fusermount $@' >> fusermount

The original resource about that is available here