From 15230bbb9b1f69def9b0e1b41a097638c0fda734 Mon Sep 17 00:00:00 2001 From: johannst Date: Tue, 28 Apr 2020 09:11:18 +0000 Subject: deploy: fef4d6ff2ad9f48e6dccde0f061453e6a3ac624e --- trace_profile/strace.html | 242 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 242 insertions(+) create mode 100644 trace_profile/strace.html (limited to 'trace_profile/strace.html') diff --git a/trace_profile/strace.html b/trace_profile/strace.html new file mode 100644 index 0000000..909a9f4 --- /dev/null +++ b/trace_profile/strace.html @@ -0,0 +1,242 @@ + + + + + + strace - Notes + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + + + +
+
+

strace(1)

+
strace [opts] [prg]
+  -f .......... follow child processes on fork(2)
+  -p <pid> .... attach to running process
+  -s <size> ... max string size, truncate of longer (default: 32)
+  -e <expr> ... expression for trace filtering
+  -o <file> ... log output into <file>
+  -c .......... dump syscall statitics at the end
+
+
<expr>:
+  trace=syscall[,syscall] .... trace only syscall listed
+  trace=file ................. trace all syscall that take a filename as arg
+  trace=process .............. trace process management related syscalls
+  trace=signal ............... trace signal related syscalls
+  signal ..................... trace signals delivered to the process
+
+

Examples

+

Trace open(2) & socket(2) syscalls for a running process + child processes:

+
strace -f -e trace=open,socket -p <pid>
+
+

Trace signals delivered to a running process:

+
strace -f -e signal -p <pid>
+
+ +
+ + +
+
+ + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.2.3