On 2021/03/09 02:24, Bengt Gördén wrote:
On 2021-03-09 01:06, L A Walsh wrote:
manpage for strace maybe needs updating
No, not really. I believe that would only be cosmetic as it's just a an example in the manpage.
I would have thought that maybe -E open might select all the open-type calls, but guess not.
But if it bugs you,
Not really -- just was answering my previous post about strace producing no output when I used -E open and that after finding the problem I was back to investigating my issues. (processing...).
Certain commands needs a higher level of understanding of what they're actually doing. This one needs you to understand system calls and that there is plenty of them. There is over 600 system calls in glibc and 5 that starts with open.
I always start by issuing -c (summary) for strace and then check the individual calls that seems to be appropriate.
---- Yeah, I don't use strace that often, and then only to find out what a command was last doing when it went off into "unexpected behavior"...
Example: strace -c cat /dev/null
But for all that starts with "open", you're supposed to do regexp or comma separated for exact match.
--- I used to know that, but never used it so .... my remembrance evaporated from disuse. ;^) Once I ran 'strace' with no "-E', I saw the problem.
regexp strace -e trace=/open cat /dev/null exact match strace -e trace=open,open_by_handle_at,open_tree,openat,openat2 cat /dev/null
--- Thanks for the reminder! ;-) -linda