Skip to content
No description, website, or topics provided.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
Makefile
README.md
probes.d
pystap.py
pytap.c
test.py

README.md

Python binding for systemtap

Build

Only for Centos or other redhat alternatives.

sudo yum install systemtap systemtap-devel systemtap-sdt-devel
make

Usage

This library provide the following probe:

provider pystap {
  probe entry(char *, char *);
};

An easy decorator is implemented:

from pystap import dtrace_deco

@dtrace_deco
def its_a_test(a_para, that_para=None):
    print a_para, that_para

Example:

Usage is shown in test.py, execute bash command like following:

sudo stap  -e 'probe process.library("/home/vagrant/github/python-systemtap/libpystap.so").mark("entry"){printf("%s - %s", user_string($arg1), user_string($arg2))}'  -c "python test.py"

Note: You should manually give the location of libpystap.so to stap.

You can’t perform that action at this time.