tracing of system calls on Linux

Nate Eldredge neldredge at hmc.edu
Tue May 21 20:23:04 UTC 2002


Partha Saha writes:
 > Hi,
 > 
 > I assume that strace works on Linux by using the
 > /proc filesystem.  

Not true.  /proc on linux has no such capability.  strace uses the
ptrace(2) system call.

 > If started by a command line argument
 > such as "-e write" where I indicate interest in only
 > the write system calls, I am wondering whether traps
 > are generated from _all_ system calls and then logging
 > done after filtering over whichever system calls I have expressed
 > interest in,

That's correct.

 > or whether traps are generated only from
 > those system calls I have indicated after the "-e" option.

No, ptrace does not provide this facility.

 > The second method will be obviously more efficient but I
 > am not sure whether the /proc filesystem allows it.
 > 
 > Thanks,
 > 
 > Partha Saha
 > 
 > 
 > _______________________________________________________________
 > 
 > Don't miss the 2002 Sprint PCS Application Developer's Conference
 > August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm
 > 
 > _______________________________________________
 > Strace-devel mailing list
 > Strace-devel at lists.sourceforge.net
 > https://lists.sourceforge.net/lists/listinfo/strace-devel

-- 

Nate Eldredge
neldredge at hmc.edu




More information about the Strace-devel mailing list