Someone asked me about having a DTrace script that displays
"ps axwww"-like info each time a process is executed.

Well, I'm actually more of a fan of "pstree"-like layout, so I
wrote a DTrace script that produces output similar to
sysutils/pstree each/everytime a process is executed.

Sample output of attached "watch_execve.d":

2014 Dec  5 13:31:30 bash[40851]: ls -A
 -+= 00809 0.0 /usr/sbin/sshd
  \-+= 40829 0.0 sshd: support@pts/0
    \-+= 40851 0.0 -bash
      \-+= 27188 0.0 ls -A

If you don't want the pstree style info, you can simply run:

watch_execve.d | grep -v '^[[:space:]]'
-- 
Cheers,
Devin

Attachment: watch_execve.d
Description: Binary data

_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-dtrace
To unsubscribe, send any mail to "[email protected]"

Reply via email to