Questions tagged [systemtap]

Systemtap is tool to probe or trace a running linux system, supporting visibility into both kernel- (its initial focus) and user-space. It uses dynamically loaded probes to gather performance and tracing data about the whole system or just selected processes.

142 questions
2
votes
1 answer

Tracing mysqld Using SystemTap

I wanna use systemtap to trace MySQL. The problem is, after MySQL is configured and built and I start the server, I can't get the markers info that are present in the server: [root@localhost]$ stap -l…
orain
  • 107
  • 6
2
votes
5 answers

How to use the stap -L option?

I am following the SystemTap tutorial and I am trying to do exercise 1 from section 2.3 - "Tracing. Exercises". The -L option seems to never work. I got this script: probe kernel.function("*nit*"){} I type in a terminal: $ stap -L PROBE t.stp and…
user1391821
  • 51
  • 1
  • 5
1
vote
0 answers

Systemtap Ubuntu 22.04.2 compile error: static declaration of ‘proc_set_user’ follows non-static declaration

I have installed systemtap following their Ubuntu tutorial. I took my kernel debug symbols following Ubuntu's wiki tutorial. Since I have SecureBoot enabled, I am "using" a compile server (hosted on my machine, same as the one on which I plan on…
WKstraw
  • 67
  • 1
  • 13
1
vote
0 answers

Running SystemTap user-space probes inside a container

I am learning SystemTap and I have created a simple C program to grasp the basics. When I run the program and a probe in the hosting system, the probe works flawlessly, but when I copy the exact same process in a container I run into some problems…
cepka
  • 11
  • 1
1
vote
1 answer

SystemTap semantic error when trying to run dvorak-qwerty script

I found this repo with a systemtap script for letting me use QWERTY ctrl-shortcuts on my dvorak layout. Unfortunately, I can't get it to work, but I don't think it has to do with the script itself. I'm running Pop OS and I think that it's because…
1
vote
1 answer

Systemtap with Python

Is there a way to probe python3 user space functions with Systemtap on Ubuntu? I'm thinking about doing something like this based on the Systemtap documentation probe process("/usr/lib/python3").function("main") { some handlers } When I run…
Thompson Liu
  • 135
  • 1
  • 6
1
vote
0 answers

semantic error: unable to find local 'set32'

when i try to run my Docker image to translate .stp file to .ko file, a error appear semantic error: unable to find local 'set32', [man error::dwarf] dieoffset 0xbd5c37 in kernel, near pc 0xc1062e20 in __se_sys_sigpending kernel/signal.c…
manhkhoa168
  • 151
  • 1
  • 4
  • 8
1
vote
1 answer

glib installation :32bit Glib library installation on x86_64bit ( 64bit ) machine

I have downloaded glib 2.56 sources from here: https://download.gnome.org/sources/glib/2.56/ And then i am trying to build & install 32-bit glib library on 64-bit x86_64 platform using following commands:- ../configure…
santosh
  • 421
  • 1
  • 6
  • 14
1
vote
0 answers

Automatically start stracing process upon invocation

The intention of below SystemTap script is to start straceing whenever a process with a given filename is started. It is called with the following command: stap -g -v './sstrace.stp' "$PATTERN" Where PATTERN can for example be…
jippie
  • 937
  • 5
  • 15
  • 33
1
vote
0 answers

Can I get the Current Working Directory in SystemTap under RHEL6

I have the following SystemTap program: #!/usr/bin/stap function proc:string() { return sprintf("[%s] %s(%s)::%s() (pid %d, uid %d, cwd %s)", execname(), cmdline_arg(0), cmdline_args(1,-1,", "), caller(), pid(), uid(), …
John Hascall
  • 9,176
  • 6
  • 48
  • 72
1
vote
1 answer

Systemtap simple userspace example (function tracing, Ubuntu)?

(I've spent quite some time getting this to work, so I thought I'd document it - first, to put it formally as a question): Is there a simple example of systemtap probing/tracing functions in a user-space application, preferably in C++? My system is…
sdaau
  • 36,975
  • 46
  • 198
  • 278
1
vote
0 answers

Linux; How to debug spin_lock source

tl;dr There are various spin locks and mutex locks in the Kernel source file `net/packet/af_packet.c, I can read the source and see which function use locks and what order they are called in, but I can't tell if the locks ever spin or for how long,…
jwbensley
  • 10,534
  • 19
  • 75
  • 93
1
vote
1 answer

How can I use systemtap(stap) in the centos container in docker for mac

When I use stap, it tell me this error as the image,how can i fix it.
1
vote
0 answers

systemtap Child process exited with status

I am using "systemtap/stap" to trace "perf" command, and I met some problems, need your help. Case 1: stap para-callgraph.stp 'process("/usr/bin/perf").function("*")' -c 'perf record -e net:net_dev_xmit usleep 1' It works fine at first. After a few…
arp
  • 11
  • 2
1
vote
0 answers

systemtap accessing global user space target variable

Accessing global kernel variable is supported by this method- “@var("varname@src/file.c")”. When this is used on user space probe, system tap still try to find in kernel space - semantic error: unable to find global 'malloc_cnt' in kernel, in…
dhanasubbu
  • 13
  • 4