On 9/12/2019 5:45 AM, Pallavi Shinde wrote:
We ran valgrind on ndmp by inserting the valgrind command within /etc/init.d/ndmpd, the script that
starts ndmpd.
valgrind did indeed run on ndmpd and we did get a memory check report, but it didn't keep itself
attached to ndmpd. valgrind dumps the memory check log and exits. The exit status is '1'. Don't know
how to 'keep valgrind attached' to ndmpd.
Would there be any guidance on how to keep valgrind attached to ndmp?
What do you mean by "keep itself attached"?
From what you say, it sounds as if ndmpd ran and finished, so naturally
valgrind finished. Everything went as you asked.
Do you mean that you want all runs of ndmpd to be done under valgrind,
including future ones, not just the one kicked off in the init.d script?
If so, then one way I can think of to do it is:
- rename ndmpd, to, say, ndmpd.bin (for binary)
- write a script called ndmpd that does: valgrind ndmpd.bin $*
- make sure the script is executable, on the path, etc.
Then when ndmpd is launched, you'll launch valgrind on the original ndmpd
program. This is not so much a "valgrind thing" as a "how to do something on
linux" thing ...
Maybe somebody can think of even nicer ways to do this.
Regards - Eliot Moss
_______________________________________________
Valgrind-users mailing list
Valgrind-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/valgrind-users