Questions tagged [strace]
strace is a debugging utility for tracing system calls and signals under Linux.
213 questions
3 votes
1 answer
105 views
inverse Heisenbug: iputils clockdiff returns host down, except when straced
I own two systems, host-a and host-b, connected in a lan via a switch; they both have no firewall. When I run clockdiff in each of them I receive the error message that the other host is down. All ...
0 votes
0 answers
41 views
Incomplete strace output for child processes
So I am writing a program that automatically determines the dependencies of an application and writes a FROM scratch dockerfile based on them using strace. I was testing it on a MariaDB, but it failed ...
0 votes
0 answers
66 views
How to trace recvfrom and sendto syscall each time apache2/httpd handle incoming http request?
So, I decided to start learn about system call with strace and want to observe network-related system call on apache2 processes, here's how I attach it: pidof -s apache2 pstree -sTp <pid-from-pidof&...
0 votes
1 answer
243 views
How to better understand and reverse-engineer system calls within processes given a specific example
I am very new to linux and as such would appreciate any pointers with respect to understanding system calls and having the ability, knowledge and tools to reverse-engineer their origin or their ...
1 vote
0 answers
2k views
sync hangs and cannot be killed
OS is Debian 12. I copied some data to a usb drive, then ran the sync command to ensure I could remove it safely. The sync command then appeared to be stuck. After waiting for half an hour, I tried ...
4 votes
1 answer
2k views
Typing in the Terminal on Ubuntu takes seconds until the typed character appears
The problem: typing in the terminal on Ubuntu takes seconds until the typed character appears. I first noticed this after I moved large chunks of data onto another LUKS encrypted HDD which I mounted ...
4 votes
1 answer
487 views
When (and how) are file permission/access decisions made in kernel space?
(I think) I have a relatively good understanding of how Linux permissions work - traditional Unix DAC permissions, and how they're represented, security context in relation to processes (i.e. cred ...
0 votes
1 answer
369 views
How to perform strace on shell without changing your current shell?
I use strace to trace the behavior of a bash process. The purpose is to find out the order bash loads its configuration files. I am running the following command under zsh: strace -e openat bash ...
3 votes
1 answer
1k views
How to parse strace recvfrom syscall?
I strace a curl command: strace -s 2000 -f curl google.com and see 2 DNS queries recvfrom(3, "\302\325\201\200\0\1\0\1\0\0\0\0\6google\3com\0\0\34\0\1\6google\3com\0\0\34\0\1\0\0\0\362\0\20*\0\...
1 vote
1 answer
105 views
log out from slim, or slim restart results in blank screen for several minutes
I am using slim login manager. when I log out from my session, or restart slim from the commandline: service slim restart I get blank console for couple of minutes, before the slim login screen ...
3 votes
1 answer
2k views
Debugging strange EACCES (Permission denied) permission error
I have a symlink to a world-readable file that a c program is being unable to read. redshift is supposed to pick up configuration from $HOME/.config/redshift/redsihft.conf automatically, but it wasn't....
1 vote
1 answer
234 views
How to trace file descriptor duplication?
I am learning to use redirection. the typical operation is like below: command > file 2>&1 Refer to APUE 3.10 and 3.12, I think the critical syscall sequence is like below: open(...
0 votes
1 answer
1k views
How to trace on continuously running process?
So I wanted to know how files are opened by zsh like .xinitrc, .xprofile, .zprofile, and exactly in which order. So I have decided to strace on zsh process with the grep command to see how the open ...
0 votes
1 answer
1k views
How can I get a custom tmux.conf file to work with tmux 3.3a? `-f` flag not working as expected
I have tmux and wanted to set some custom configurations, but I cannot find a default tmux.conf file. tmux -V tmux 3.3a According to the manpage: -f file Specify an alternative ...
0 votes
0 answers
458 views
Process stucked at recvfrom syscall
A process is stucked at recvfrom syscall. > sudo strace -p 4146278 strace: Process 4146278 attached recvfrom(9 ... I looked up under /proc/4146278/fd. fd 9 seems to be a socket. > sudo ls -al /...