This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: Controlling a systemtap script from userspace
> [...] the question is how to get that user space C++ program to set
> a global in a systemTap script? [...]
Other than hunt's solution, someone will eventually implement
our old bug #1154, which would allow direct expression thusly:
> # turn on logging
> probe ### something from user space ### {isLogging = 1}
> # turn off logging
> probe ### something else from user space #### {isLogging = 0}
global logging
probe procfs("stap/myscript/logging").write {
logging = ($value == "1")
}
...
# echo 1 > /proc/stap/myscript/logging
- FChE