Print this page
12743 man page spelling mistakes
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/man/man4/tnf_kernel_probes.4.man.txt
+++ new/usr/src/man/man4/tnf_kernel_probes.4.man.txt
1 1 TNF_KERNEL_PROBES(4) File Formats and Configurations TNF_KERNEL_PROBES(4)
2 2
3 3
4 4
5 5 NAME
6 6 tnf_kernel_probes - TNF kernel probes
7 7
8 8 DESCRIPTION
9 9 The set of probes (trace instrumentation points) available in the
10 10 standard kernel. The probes log trace data to a kernel trace buffer in
11 11 Trace Normal Form (TNF). Kernel probes are controlled by prex(1). A
12 12 snapshot of the kernel trace buffer can be made using tnfxtract(1) and
13 13 examined using tnfdump(1).
14 14
15 15
16 16 Each probe has a name and is associated with a set of symbolic keys, or
17 17 categories. These are used to select and control probes from prex(1). A
18 18 probe that is enabled for tracing generates a TNF record, called an
19 19 event record. An event record contains two common members and may
20 20 contain other probe-specific data members.
21 21
22 22 Common Members
23 23 tnf_probe_event tag
24 24 tnf_time_delta time_delta
25 25
26 26
27 27 tag
28 28 Encodes TNF references to two other records:
29 29
30 30 tag
31 31 Describes the layout of the event record.
32 32
33 33
34 34 schedule
35 35 Identifies the writing thread and also
36 36 contains a 64-bit base time in nanoseconds.
37 37
38 38
39 39
40 40 time_delta
41 41 A 32-bit time offset from the base time; the sum of the
42 42 two times is the actual time of the event.
43 43
44 44
45 45 Threads
46 46 thread_create
47 47 tnf_kthread_id tid
48 48 tnf_pid pid
49 49 tnf_symbol start_pc
50 50
51 51
52 52
53 53 Thread creation event.
54 54
55 55 tid
56 56 The thread identifier for the new thread.
57 57
58 58
59 59 pid
60 60 The process identifier for the new thread.
61 61
62 62
63 63 start_pc
64 64 The kernel address of its start routine.
65 65
66 66
67 67 thread_state
68 68 tnf_kthread_id tid
69 69 tnf_microstate state
70 70
71 71
72 72
73 73 Thread microstate transition events.
74 74
75 75 tid
76 76 Optional; if it is absent, the event is for the writing
77 77 thread, otherwise the event is for the specified thread.
78 78
79 79
80 80 state
81 81 Indicates the thread state:
82 82
83 83 o Running in user mode.
84 84
85 85 o Running in system mode.
86 86
87 87 o Asleep waiting for a user-mode lock.
88 88
89 89 o Asleep on a kernel object.
90 90
91 91 o Runnable (waiting for a cpu).
92 92
93 93 o Stopped.
94 94 The values of this member are defined in <sys/msacct.h>. Note
95 95 that to reduce trace output, transitions between the system
96 96 and user microstates that are induced by system calls are not
97 97 traced. This information is implicit in the system call
98 98 entry and exit events.
99 99
100 100
101 101 thread_exit
102 102 Thread termination event for writing thread. This probe has no data
103 103 members other than the common members.
104 104
105 105 Scheduling
106 106
107 107 thread_queue
108 108 tnf_kthread_id tid
109 109 tnf_cpuid cpuid
110 110 tnf_long priority
111 111 tnf_ulong queue_length
112 112
113 113
114 114
115 115 Thread scheduling events. These are triggered when a runnable thread
116 116 is placed on a dispatch queue.
117 117
118 118 cpuid
119 119 Specifies the cpu to which the queue is attached.
120 120
121 121
122 122 priority
123 123 The (global) dispatch priority of the thread.
124 124
125 125
126 126 queue_length
127 127 The current length of the cpu's dispatch queue.
128 128
129 129
130 130 Blocking
131 131 thread_block
132 132 tnf_opaque reason
133 133 tnf_symbols stack
134 134
135 135
136 136
137 137 Thread blockage event. This probe captures a partial stack backtrace
138 138 when the current thread blocks.
139 139
140 140 reason
141 141 The address of the object on which the thread is blocking.
142 142
143 143
144 144 symbols
145 145 References a TNF array of kernel addresses representing the
146 146 PCs on the stack at the time the thread blocks.
147 147
148 148
149 149 System Calls
150 150 syscall_start
151 151 tnf_sysnum sysnum
152 152
153 153
154 154
155 155 System call entry event.
156 156
157 157 sysnum
158 158 The system call number. The writing thread implicitly enters
159 159 the system microstate with this event.
160 160
161 161
162 162 syscall_end
163 163 tnf_long rval1
164 164 tnf_long rval2
165 165 tnf_long errno
166 166
167 167
168 168
169 169 System call exit event.
170 170
171 171 rval1 and rval2
172 172 The two return values of the system call
173 173
174 174
175 175 errno
176 176 The error return.
177 177
178 178
179 179
180 180 The writing thread implicitly enters the user microstate with this
181 181 event.
182 182
183 183 Page Faults
184 184 address_fault
185 185 tnf_opaque address
186 186 tnf_fault_type fault_type
187 187 tnf_seg_access access
188 188
189 189
190 190
191 191 Address-space fault event.
192 192
193 193 address
194 194 Gives the faulting virtual address.
195 195
196 196
197 197 fault_type
198 198 Gives the fault type: invalid page, protection fault,
199 199 software requested locking or unlocking.
200 200
201 201
202 202 access
203 203 Gives the desired access protection: read, write, execute
204 204 or create. The values for these two members are defined
205 205 in <vm/seg_enum.h>.
206 206
207 207
208 208 major_fault
209 209 tnf_opaque vnode
210 210 tnf_offset offset
211 211
212 212
213 213
214 214 Major page fault event. The faulting page is mapped to the file given
215 215 by the vnode member, at the given offset into the file. (The faulting
216 216 virtual address is in the most recent address_fault event for the
217 217 writing thread.)
218 218
219 219 anon_private
220 220 tnf_opaque address
221 221
222 222
223 223
224 224 Copy-on-write page fault event.
225 225
226 226 address
227 227 The virtual address at which the new page is mapped.
228 228
229 229
230 230 anon_zero
231 231 tnf_opaque address
232 232
233 233
234 234
235 235 Zero-fill page fault event.
236 236
237 237 address
238 238 The virtual address at which the new page is mapped.
239 239
240 240
241 241 page_unmap
242 242 tnf_opaque vnode
243 243 tnf_offset offset
244 244
245 245
246 246
247 247 Page unmapping event. This probe marks the unmapping of a file system
248 248 page from the system.
249 249
250 250 vnode and offset
251 251 Identifies the file and offset of the page being
252 252 unmapped.
253 253
254 254
255 255 Pageins and Pageouts
↓ open down ↓ |
255 lines elided |
↑ open up ↑ |
256 256 pagein
257 257 tnf_opaque vnode
258 258 tnf_offset offset
259 259 tnf_size size
260 260
261 261
262 262
263 263 Pagein start event. This event signals the initiation of pagein I/O.
264 264
265 265 vnodeandoffset
266 - Identifyies the file and offset to be paged in.
266 + Identifies the file and offset to be paged in.
267 267
268 268
269 269 size
270 270 Specifies the number of bytes to be paged in.
271 271
272 272
273 273 pageout
274 274 tnf_opaque vnode
275 275 tnf_ulong pages_pageout
276 276 tnf_ulong pages_freed
277 277 tnf_ulong pages_reclaimed
278 278
279 279
280 280
281 281 Pageout completion event. This event signals the completion of pageout
282 282 I/O.
283 283
284 284 vnode
285 285 Identifies the file of the pageout request.
286 286
287 287
288 288 pages_pageout
289 289 The number of pages written out.
290 290
291 291
292 292 pages_freed
293 293 The number of pages freed after being written out.
294 294
295 295
296 296 pages_reclaimed
297 297 The number of pages reclaimed after being written
298 298 out.
299 299
300 300
301 301 Page Daemon (Page Stealer)
302 302 pageout_scan_start
303 303 tnf_ulong pages_free
304 304 tnf_ulong pages_needed
305 305
306 306
307 307
308 308 Page daemon scan start event. This event signals the beginning of one
309 309 iteration of the page daemon.
310 310
311 311 pages_free
312 312 The number of free pages in the system.
313 313
314 314
315 315 pages_needed
316 316 The number of pages desired free.
317 317
318 318
319 319 pageout_scan_end
320 320 tnf_ulong pages_free
321 321 tnf_ulong pages_scanned
322 322
323 323
324 324
325 325 Page daemon scan end event. This event signals the end of one
326 326 iteration of the page daemon.
327 327
328 328 pages_free
329 329 The number of free pages in the system.
330 330
331 331
332 332 pages_scanned
333 333 The number of pages examined by the page daemon.
334 334 (Potentially more pages will be freed when any queued
335 335 pageout requests complete.)
336 336
337 337
338 338 Swapper
339 339 swapout_process
340 340 tnf_pid pid
341 341 tnf_ulong page_count
342 342
343 343
344 344
345 345 Address space swapout event. This event marks the swapping out of a
346 346 process address space.
347 347
348 348 pid
349 349 Identifies the process.
350 350
351 351
352 352 page_count
353 353 Reports the number of pages either freed or queued for
354 354 pageout.
355 355
356 356
357 357 swapout_lwp
358 358 tnf_pid pid
359 359 tnf_lwpid lwpid
360 360 tnf_kthread_id tid
361 361 tnf_ulong page_count
362 362
363 363
364 364
365 365 Light-weight process swapout event. This event marks the swapping out
366 366 of an LWP and its stack.
367 367
368 368 pid
369 369 The LWP's process identifier
370 370
371 371
372 372 lwpid
373 373 The LWP identifier
374 374
375 375
376 376 tid member
377 377 The LWP's kernel thread identifier.
378 378
379 379
380 380 page_count
381 381 The number of pages swapped out.
382 382
383 383
384 384 swapin_lwp
385 385 tnf_pid pid
386 386 tnf_lwpid lwpid
387 387 tnf_kthread_id tid
388 388 tnf_ulong page_count
389 389
390 390
391 391
392 392 Light-weight process swapin event. This event marks the swapping in of
393 393 an LWP and its stack.
394 394
395 395 pid
396 396 The LWP's process identifier.
397 397
398 398
399 399 lwpid
400 400 The LWP identifier.
401 401
402 402
403 403 tid
404 404 The LWP's kernel thread identifier.
405 405
406 406
407 407 page_count
408 408 The number of pages swapped in.
409 409
410 410
411 411 Local I/O
412 412 strategy
413 413 tnf_device device
414 414 tnf_diskaddr block
415 415 tnf_size size
416 416 tnf_opaque buf
417 417 tnf_bioflags flags
418 418
419 419
420 420
421 421 Block I/O strategy event. This event marks a call to the strategy(9E)
422 422 function of a block device driver.
423 423
424 424 device
425 425 Contains the major and minor numbers of the device.
426 426
427 427
428 428 block
429 429 The logical block number to be accessed on the device.
430 430
431 431
432 432 size
433 433 The size of the I/O request.
434 434
435 435
436 436 buf
437 437 The kernel address of the buf(9S) structure associated with
438 438 the transfer.
439 439
440 440
441 441 flags
442 442 The buf(9S) flags associated with the transfer.
443 443
444 444
445 445 biodone
446 446 tnf_device device
447 447 tnf_diskaddr block
448 448 tnf_opaque buf
449 449
450 450
451 451
452 452 Buffered I/O completion event. This event marks calls to the
453 453 biodone(9F) function.
454 454
455 455 device
456 456 Contains the major and minor numbers of the device.
457 457
458 458
459 459 block
460 460 The logical block number accessed on the device.
461 461
462 462
463 463 buf
464 464 The kernel address of the buf(9S) structure associated with
465 465 the transfer.
466 466
↓ open down ↓ |
190 lines elided |
↑ open up ↑ |
467 467
468 468 physio_start
469 469 tnf_device device
470 470 tnf_offset offset
471 471 tnf_size size
472 472 tnf_bioflags rw
473 473
474 474
475 475
476 476 Raw I/O start event. This event marks entry into the physio(9F)
477 - fufnction which performs unbuffered I/O.
477 + function which performs unbuffered I/O.
478 478
479 479 device
480 480 Contains the major and minor numbers of the device of the
481 481 transfer.
482 482
483 483
484 484 offset
485 485 The logical offset on the device for the transfer.
486 486
487 487
488 488 size
489 489 The number of bytes to be transferred.
490 490
↓ open down ↓ |
3 lines elided |
↑ open up ↑ |
491 491
492 492 rw
493 493 The direction of the transfer: read or write (see buf(9S)).
494 494
495 495
496 496 physio_end
497 497 tnf_device device
498 498
499 499
500 500
501 - Raw I/O end event. This event marks exit from the physio(9F)
502 - fufnction.
501 + Raw I/O end event. This event marks exit from the physio(9F) function.
503 502
504 503 device
505 504 The major and minor numbers of the device of the transfer.
506 505
507 506
508 507 USAGE
509 508 Use the prex utility to control kernel probes. The standard prex
510 509 commands to list and manipulate probes are available to you, along with
511 510 commands to set up and manage kernel tracing.
512 511
513 512
514 513 Kernel probes write trace records into a kernel trace buffer. You must
515 514 copy the buffer into a TNF file for post-processing; use the tnfxtract
516 515 utility for this.
517 516
518 517
519 518 You use the tnfdump utility to examine a kernel trace file. This is
520 519 exactly the same as examining a user-level trace file.
521 520
522 521
523 522 The steps you typically follow to take a kernel trace are:
524 523
525 524 1. Become superuser (su).
526 525
527 526 2. Allocate a kernel trace buffer of the desired size (prex).
528 527
529 528 3. Select the probes you want to trace and enable (prex).
530 529
531 530 4. Turn kernel tracing on (prex).
532 531
533 532 5. Run your application.
534 533
535 534 6. Turn kernel tracing off (prex).
536 535
537 536 7. Extract the kernel trace buffer (tnfxtract).
538 537
539 538 8. Disable all probes (prex).
540 539
541 540 9. Deallocate the kernel trace buffer (prex).
542 541
543 542 10. Examine the trace file (tnfdump).
544 543
545 544
↓ open down ↓ |
33 lines elided |
↑ open up ↑ |
546 545 A convenient way to follow these steps is to use two shell windows; run
547 546 an interactive prex session in one, and run your application and
548 547 tnfxtract in the other.
549 548
550 549 SEE ALSO
551 550 prex(1), tnfdump(1), tnfxtract(1), libtnfctl(3TNF), TNF_PROBE(3TNF),
552 551 tracing(3TNF), strategy(9E), biodone(9F), physio(9F), buf(9S)
553 552
554 553
555 554
556 - November 8, 1999 TNF_KERNEL_PROBES(4)
555 + May 16, 2020 TNF_KERNEL_PROBES(4)
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX