]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/blob - cddl/contrib/dtracetoolkit/Examples/pidpersec_example.txt
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
[FreeBSD/stable/10.git] / cddl / contrib / dtracetoolkit / Examples / pidpersec_example.txt
1 The following is a demonstration of the pidpersec.d script.
2
3
4 Here the program is run on an idle system,
5
6    # ./pidpersec.d
7    TIME                    LASTPID  PID/s
8    2005 Jun  9 22:15:09       3010      0
9    2005 Jun  9 22:15:10       3010      0
10    2005 Jun  9 22:15:11       3010      0
11    2005 Jun  9 22:15:12       3010      0
12    2005 Jun  9 22:15:13       3010      0
13    ^C
14
15 This shows that there are now new processes being created.
16
17
18
19 Now the script is run on a busy system, that is creating many processes
20 (which happen to be short-lived),
21
22    # ./pidpersec.d
23    TIME                    LASTPID  PID/s
24    2005 Jun  9 22:16:30       3051     13
25    2005 Jun  9 22:16:31       3063     12
26    2005 Jun  9 22:16:32       3073     10
27    2005 Jun  9 22:16:33       3084     11
28    2005 Jun  9 22:16:34       3096     12
29    ^C
30
31 Now we can see that there are over 10 new processes created each second.
32 The value for lastpid confirms the rates printed.
33