This tool will help you with diagnostic, debugging and monitor between processes and the Linux kernel.
For example you can test this tool with ls command:
- to display only a specific system call, use the strace -e option as shown below.
- the result of this will come with all infos about count time, calls, and errors for each system call.
$ strace -e open ls > /dev/null
- save the trace execution to a file:
$ strace -c ls > /dev/null
- display and save the strace for a given process id:
$ strace -o output.txt ls
$ strace -p 1725 -o process_id_trace.txt
You can see more examples on the official webpage.