# Installation

Sherlok uses the standard JVMPI and needs therefore a shared library, which will be attached to the JVM at runtime. The user interface is a telnet command line application which connects to the JVM of the profiled program.

## Parts

- Operating system dependend shared library

## Requirements

- Operating system: Win2000, Solaris, Linux, AIX or HP-UX
- JRE 1.3 or 1.4

## Tasks

- Install the shared library
- Install the file sherlok.properties
- Modify JVM parameter

## Installation of Shared Library

Select the link for your operating system with the right mouse and select "save target as...". In the dialog box choose the directory /usr/sap/sherlok/.

Add the directory /usr/sap/sherlok/ to the environment variable shown in the last column using the syntax of the PATH environment variable.

Win2000 | sherlok.dll | PATH
Solaris | libsherlok.so | LD_LIBRARY_PATH
HP-UX (64Bit) | libsherlok.sl | SHLIB_PATH
AIX (64bit) | libsherlok.so | LIBPATH
Linux | libsherlok.so | LD_LIBRARY_PATH

## Installation of Properties file

Select the link with the right mouse and select "save target as...". In the dialog box choose the directory /usr/sap/sherlok/

default.skp | Default properties for portal namespace
default.customer.skp | Default properties for customer namespace
default.drilldown.skp | Drill down for memory problems
default.performance.skp | Configuration for performance measurement
monitor.leak.skp | Configuration for memory leak detection in portal namespace
monitor.leak.custormer.skp | Configuration for memory leak detection in customer namespace

## Modify JVM Parameters

Use the Java command line parameter -Xrun to attach Sherlok to the JVM. In your J2EE installation open the go script in

- subfolder .../server in a cluster environment or
- subfolder .../alone in a stand alone environment

Replace the environment variable DEBUG_PARAMS in the go script by the following entry. For UNIX systems you have to set quotation marks.

set DEBUG_PARAMS=-Djava.compiler=NONE -Xdebug -Xnoagent -Xrunsherlok:ConfigPath=/usr/sap/sherlok set LD_LIBRARY_PATH=/usr/sap/sherlok