I am trying to debug a problem on a linux server.
When launched, sudo ls /it takes a few seconds to execute the command. non-sudo ls /works as expected.
I suspect this is due to auditing through auditd, but I'm not sure.
In any case, I tried to run the command using strace: strace sudo ls /and the command worked fine. In other words, it seems like I'm in heisenbug, where using strace to monitor behavior actually changes the behavior.
So, while I am ultimately interested to know why it sudo ls /takes so long, now I’m very interested to know how to use straceto understand this, and to find out if I am using it straceincorrectly and how to use it correctly.
source
share