From ecf33ff44feaccfde06f3c2b55b0a78d69e29545 Mon Sep 17 00:00:00 2001 From: Eugene Teo Date: Thu, 4 Feb 2010 13:42:24 -0500 Subject: new sample: pfiles --- testsuite/systemtap.examples/index.html | 6 +- testsuite/systemtap.examples/index.txt | 17 +- testsuite/systemtap.examples/keyword-index.html | 14 +- testsuite/systemtap.examples/keyword-index.txt | 27 +- testsuite/systemtap.examples/process/pfiles.meta | 6 + testsuite/systemtap.examples/process/pfiles.stp | 606 +++++++++++++++++++++++ 6 files changed, 651 insertions(+), 25 deletions(-) create mode 100644 testsuite/systemtap.examples/process/pfiles.meta create mode 100755 testsuite/systemtap.examples/process/pfiles.stp (limited to 'testsuite/systemtap.examples') diff --git a/testsuite/systemtap.examples/index.html b/testsuite/systemtap.examples/index.html index eaf21135..1c16d37b 100644 --- a/testsuite/systemtap.examples/index.html +++ b/testsuite/systemtap.examples/index.html @@ -91,9 +91,6 @@ keywords: IO
  • io/mbrwatch.stp - Monitor read/write of MBR (boot sector) area of block devices
    keywords: IO MONITORING

    The mbrwatch.stp script reports any attempted reads/writes of the first few sectors of a raw block device.

  • -
  • io/nfs_func_log.stp - Print Log of NFS Functions Used
    -keywords: IO
    -

    The nfs_func_log.stp script logs the uses of NFS functions in the kernel. The output is a trace. Each line contains the time stamp, the process name, and the process number followed by the function name.

  • io/nfs_func_users.stp - Tally the Number of NFS Functions Used by Each Process
    keywords: IO PROFILING

    The nfs_func_users.stp script counts the uses of NFS functions in the kernel on a per process bases. The output is sorted from the process with the greatest number of NFS functions called to the least. The output contains the executable name, the process number, and the total number of NFS functions called by the process.

  • @@ -187,6 +184,9 @@ keywords: SCHEDULER
  • process/pf2.stp - Profile kernel functions
    keywords: PROFILING

    The pf2.stp script sets up time-based sampling. Every five seconds it prints out a sorted list with the top ten kernel functions with samples.

  • +
  • process/pfiles.stp - print process file descriptors
    +keywords: PROCESS FILES
    +

    Run pfiles.stp to produce a human-readable summary of all open file descriptors of a given process. Specify the process-id as -x PID for fastest performance.

  • process/plimit.stp - print resource limits
    keywords: PROCESS

    The script prints a variety of resource limits for a given pid, like /proc/$$/limits on recent kernels.

  • diff --git a/testsuite/systemtap.examples/index.txt b/testsuite/systemtap.examples/index.txt index 9a3637ae..908db615 100644 --- a/testsuite/systemtap.examples/index.txt +++ b/testsuite/systemtap.examples/index.txt @@ -156,15 +156,6 @@ keywords: io monitoring first few sectors of a raw block device. -io/nfs_func_log.stp - Print Log of NFS Functions Used -keywords: io - - The nfs_func_log.stp script logs the uses of NFS functions in the - kernel. The output is a trace. Each line contains the time stamp, - the process name, and the process number followed by the function - name. - - io/nfs_func_users.stp - Tally the Number of NFS Functions Used by Each Process keywords: io profiling @@ -463,6 +454,14 @@ keywords: profiling samples. +process/pfiles.stp - print process file descriptors +keywords: process files + + Run pfiles.stp to produce a human-readable summary of all open file + descriptors of a given process. Specify the process-id as -x PID for + fastest performance. + + process/plimit.stp - print resource limits keywords: process diff --git a/testsuite/systemtap.examples/keyword-index.html b/testsuite/systemtap.examples/keyword-index.html index ef1a801f..56119081 100644 --- a/testsuite/systemtap.examples/keyword-index.html +++ b/testsuite/systemtap.examples/keyword-index.html @@ -39,7 +39,7 @@

    Examples by Keyword

    -

    ALLOCATOR AUTOFS BACKTRACE BUFFER CALLGRAPH CPU DEVICE DISK FILESYSTEM FORMAT FREE FUNCTIONS FUTEX GRAPH HACK INTERRUPT IO LOCKING MEMORY MONITOR MONITORING NETWORK NFS NUMA PER-PROCESS PROCESS PROFILING READ SCHEDULER SCSI SIGNALS SIMPLE SLAB SLEEP SOCKET STATISTICS SYSCALL TCP TIME TRACE TRACEPOINT TRAFFIC TTY USE WAIT4 WRITE

    +

    ALLOCATOR AUTOFS BACKTRACE BUFFER CALLGRAPH CPU DEVICE DISK FILES FILESYSTEM FORMAT FREE FUNCTIONS FUTEX GRAPH HACK INTERRUPT IO LOCKING MEMORY MONITOR MONITORING NETWORK NFS NUMA PER-PROCESS PROCESS PROFILING READ SCHEDULER SCSI SIGNALS SIMPLE SLAB SLEEP SOCKET STATISTICS SYSCALL TCP TIME TRACE TRACEPOINT TRAFFIC TTY USE WAIT4 WRITE

    ALLOCATOR

    +

    FILES

    +

    FILESYSTEM