[dtrace-discuss] DTrace instead of `lsof`?

UNIX admin tripivceta at hotmail.com
Tue Aug 15 07:05:58 PDT 2006


How would I replicate `lsof` functionality with DTrace?

I tried for example

dtrace -n 'syscall::open:entry /execname == $1/ {printf("%s", copyinstr(arg0));}' named

but that does not seem to work, at least not in the way I expect. What I expected to see was a list of open files that $1 has open, but instead I just got how many probes DTrace matched. And no further output.
 
 
This message posted from opensolaris.org


More information about the dtrace-discuss mailing list