This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

stap and staprun use cases


With the changes we are working on to split users into two groups, it is
a good time to consider how those two groups will use stap and staprun.
With this in mind, we can make the necessary tweaks to the user
interface.

1. stapdev

1A. Compile and Run a script.  Same as now.
>stap script

1B. Just compile a script.  When doing this it will always be desirable
to give it a meaningful name.

Now.
> stap -p4 -km name
> cp /tmp/stapXXXX/name.ko [destination]
> rm -rf /tmp/stapXXX

Proposed.
> stap -m name
name.ko is put in the current directory. Module is lot loaded.

1C. Compile and install a script so stapusr users may use it.
Now.
> stap -p4 -km name
> cp /tmp/stapXXXX/name.ko /lib/modules/`uname -r`/systemtap
> rm -rf /tmp/stapXXX

Proposed. add "-i" option for install. Change "-m" to put module in
current directory and not load it.
> stap -im name

1D. Load and run a module.
>From /lib/modules/`uname -r`/systemtap:
> staprun module[.ko]

>From anywhere:
> staprun /path/to/module[.ko]

2. stapusr

2A. Compile and Run a script.  Not allowed.
Proposed:
stap should reject attempts to compile script unless
"-m" or "-pX" where X < 5. This is optional. staprun
will not load the script

2B. Just compile a script. Same as 1B. All (not just stapusr) users may
compile scripts. Justification: Allows users to check that scripts
compile. Allows them to then use su or sudo and install the module in
the case where they are not, for some reason, in stapdev.

2C. Compile and install a script so stapusr users may use it.
Proposed: Not allowed. stapdev and root users only.

2D. Load and run a module.
>From /lib/modules/`uname -r`/systemtap:
> staprun module[.ko]

>From anywhere: Not allowed.
> staprun /path/to/module[.ko]
If /path/to != "/lib/modules/`uname -r`/systemtap"
then print error message.





Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]