Tools Home
 

Linux Dynamic Package -- GA 4.0
(for kernels supporting "Profiling support")

 

This version of Performance Inspector is designed to work without the need to patch the kernel source code. Instead it builds a kernel module compiled against the currently running kernel. This module takes advantage of the same system hooks used by OProfile. We are able to register with these hooks to get notified on timer ticks and on task exits. Tprof uses these hooks along with our previous technology. For Dispatch hooks and ITrace we use kprobes (ppc64) or run-time kernel patching (x86, x86_64).

This package has been tested with SLES 9 and 10, RHEL 4 and 5,
on x86, x86_64, ppc64, and s390 systems. Latest supported kernel version is 2.6.18.
Note that we did not test all possible OS/arch combinations, please let us know if something is not working on your system.


INSTALLATION STEPS WITHOUT KERNEL REBUILD
(2.6 Linux kernels on x86, x86_64, s390, and 2.6 kernels with kprobes support on PPC64)

You can download and install Performance Inspector Tools for Linux as the source tarball
or rpm packages. Precompiled rpm packages are currently available only for x86, x86_64, and PPC64 systems.

To use the tools you also need to set up the environment.


Installation using tarball

  1. Make sure you have a softlink (or directory) to /usr/src/linux that matches your kernel. Source notes.

  2. Make sure you have a libbfd.so. Libbfd notes
  3. Download the complete source tarball Dpiperf.dynamic.4.0.tar.gz from the project web page or this link.
    Note that if you are using Internet Explorer and the tarball extension is .tar.tar after download,
    you just need to rename it to be tar.gz.
  4. Untar package:


  5. tar -xzf Dpiperf.dynamic.4.0.tar.gz
    cd Dpiperf
     
  6. From Dpiperf directory, run

    ./tinstall.appl

    This will build and install user space tools. You will be asked for JDK directory if not in the path.
  7. Change to root (su) and from Dpiperf directory run

    ./tinstall.drv

    This will build, install, and load the kernel driver.


Installation using rpm packages

You need two rpm files: for the user-space applications and for the kernel module.
The user-space applications are precompiled and the kernel module is automatically built after rpm installation.

  1. Make sure you have a softlink (or directory) to /usr/src/linux that matches your kernel. Source notes.

  2. Make sure you have a libbfd.so. Libbfd notes
  3. Download the rpm version for user-space applications from the project web page or the appropriate link:
    For x86: dpiperf_appl-4.0-5.i586.rpm

  4. For x86_64: dpiperf_appl-4.0-5.x86_64.rpm
    For PPC64: dpiperf_appl-4.0-5.ppc64.rpm
  5. Install the rpm package for the user-space applications:

    rpm -ivh --prefix tools_dir dpiperf_appl-4.0-5.arch.rpm

    tools_dir is the directory where you want the tools to be installed; if --prefix is ommited,
    the default directory is /opt directory.
    arch is the architecture for which you downloaded the rpm.
    Note: If binutil version on your system does not match the one that was on the system where the rpm package was built,
    the post-install rpm script will build liba2n and post on your system.
  6. Download the kernel module rpm: dpiperf_drv-4.0-5.noarch.rpm
  7. Install the rpm package for the kernel module:

    rpm -ivh --prefix tools_dir dpiperf_drv-4.0-5.noarch.rpm

    tools_dir is the directory where you want the driver source code to be installed; if --prefix is ommited,
    the default directory is /opt directory.
    The post-install rpm script will build and install the kernel module.
    Rpm packages may be removed using rpm -e package_name.
    You may need to remove a previous package before installing a new one.


Setting up the environment

In each terminal window for which you want tools access, "source" the script that sets up your environment and ensures the kernel module is loaded
(note the dot, blank in front of the setrunenv command).

cd tools_dir/Dpiperf/bin
. ./setrunenv

You are now ready to use the tools.


Source Notes:
On many Linux systems running 2.6 kernels, it is not necessary to explicitly install the kernel source. Enough of the source is automatically included in /lib/modules/$(uname -r) to build an external module. However, some distributions still separate the source, by making /lib/modules/$(uname -r)/source a symbolic link to /usr/src/linux. SLES9 is an example. If you are running such a distribution, make sure that kernel-source-2.6.x is installed (where x matches your version number). You can test if it is installed by executing "rpm -q kernel-source".
On RHEL4, make sure that kernel-devel-2.6.x.EL or kernel-smp-devel-2.6.x.EL is installed, depending on your system.
On RHEL5, you need to install binutil-devel.

Libbfd notes:
Make sure you have a libbfd.so (a component of binutils).
On some machines, one may need to fetch gnu binutils and install the libbfd.
Note: we use libbfd.so during the post processing phase of tracing to get module information.

JDKDIR notes:
Example 1:
    export PATH=${JAVAHOME}/bin:${JAVAHOME}/jre/bin:$PATH
            where JAVAHOME is the directory where you installed java
            There should be an include directory: ${JAVAHOME}/include
Example 2:
    export PATH=/opt/j9/bin:/opt/j9/jre:$PATH
 


INSTALLATION STEPS WITH A KERNEL REBUILD

If you need to enable kprobes on a 2.6 kernel, you will need to build a kernel with the required support. This package is not tested on 2.4 kernels. After booting with the new kernel, you should follow the steps above: INSTALLATION STEPS WITHOUT KERNEL REBUILD to install the tools.

     


NOTE: DO NOT RUN ITRACE WITHOUT A BACKUP,
Since ITrace can hang your system. In the current package on x86 and x86_64 systems, ITrace run-time patches stay in the kernel until the computer is rebooted, so do not manually unload the driver after collecting an ITrace. On PPC64, ITrace support can be safely removed by unloading the driver.


Known Problems


Please contact Frank Levine (levinef@us.ibm.com) with problems and/or comments

    Tools Home