Web Toys

Discussion of all kinds of web technologies

About the author

Bret Patterson.
E-mail me Send mail

Recent comments

Authors

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008

Configure Websphere and DB2 to issue ARM calls (ITCAM for Transactions 7.1 update)

General Requirements

   

  1. DB2 Distributed Version 8.2 (or 8.1 FP11)
    1. Only non-zos DB2 8.2+ supports ARM, and it supports ARM v4
  2. Websphere Application Server 5.1 or higher
    1. Only Websphere can pass correlators to DB2, and DB2 will not issue ARM calls unless a correlator is received for the connection.

Step 1: ITCAM for Transactions 7.1- Install the Transaction Collector Agent

    The Transaction Collector agent is the agent that supports monitoring ARM instrumented applications. Installing it automatically installs support for all ARM instrumented applications (TU is it's prefix as you will see in paths below). This agent replaces the previous 6.2 Client Response Time agent for monitoring ARM applications (though similar steps can be used to configure the CRT agent to monitor ARM also, if you want the CRT workspaces instead or in addition to the Transaction Collector Workspaces).

Step 2: Configure Websphere

 ConfigureRequestMetrics

  1. In the picture above you need to do the following:

    1. Check the box labeled "Prepare Servers for Request metrics collection"
    2. Select "All" Radio button under "Components to be instrumented".
    3. Set the Trace Level
      1. HOPS - Preferred Level
        1. Generates instrumentation information on process boundaries only (for example, at the entry and exit points for the Web container).
        2. Generates instrumentation information on process boundaries only (for example, a servlet request coming from a browser or a Web server and a JDBC request going to a database).
      2. Performance_Debug
        1. Generates one additional level of instrumentation data, whereas debug generates detailed instrumentation data.
        2. Generates the data at Hops level and the first level of the intra-process servlet and Enterprise JavaBeans (EJB) call (for example, when an inbound servlet forwards to a servlet and an inbound EJB calls another EJB). Other intra-process calls like naming and service integration bus (SIB) are not enabled at this level
      3. Debug
        1. Provides detailed instrumentation data, including response times for all intra-process servlet and Enterprise JavaBeans (EJB) calls.
        2. Provides detailed instrumentation data, including response times for all intra-process calls.  Note: Requests to servlet filters will only be instrumented at this level.
    4. Check the box under "Request Metrics Destination" labeled "Application Response Measurement (ARM) agent".
    5. Select Agent Type ARM40.
    6. type in "com.ibm.tivoli.transperf.arm4.transaction.Arm40TransactionFactory" in the edit box labeled "ARM transaction factory implementation class name".
  2. Set a custom property (Application Servers->server1->ProcessDefinition->Java Virtual Machine -> Custom Properties) of ws.ext.dirs equal to the values below ( which will include the armjni4.jar file) – Key is to have ws.ext.dirs point to where the armjni4.jar file is located at.
  3. You also have to set your LIBRARY PATH before starting WebSphere to point to the ITM framework libraries, the ARM libraries, and the TTAPI libraries as noted below.

ITCAM for Transactions 7.1 only

    1. Setup websphere to include the armjni4.jar file in it's library path. $ITMHOME defaults to c:\ibm\itm for windows and /opt/IBM/ITM/ for unix.
      1. Windows - set ws.ext.dirs $ITMHOME\tmaitm6\tusupport
      2. Linux - $ITMHOME/li6263/tu/tusupport
      3. AIX - $ITMHOME/aix533/tu/tusupport/
      4. HPUX - $ITMHOME/hp11/tu/tusupport/
      5. Solaris - $ITMHOME/sol293/tu/tusupport/
    2. Unix only, windows does this during installation: Set CANDLE_HOME to the ITM base installation directory. This is normally /opt/IBM/ITM/.
    3. Set your LD_LIBRARY_PATH  to include the ARM libraries (before running ./startServer.sh on unix to start Websphere)
      1. Windows - You can skip this step since ITM automatically includes c:\ibm\itm\tmaitm6\ in your system path. You might need to reboot for it to take effect if you haven't rebooted since you first installed ITM framework.
      2. Linux    - Set your LD_LIBRARY_PATH=  $ITMHOME/li6263/tu/tusupport:$ITMHOME/li6263/tu/lib/:$ITMHOME/tmaitm6/lib/li6263/
      3. AIX      - Set your LIBPATH=  $ITMHOME/tmaitm6/aix533/lib/
      4. HPUX    - Set your SHLIB_PATH= $ITMHOME/hp11/tu/tusupport/:$ITMHOME/hp11/tu/lib/:$ITMHOME/tmaitm6/hp11/lib/
      5. Solaris  - Set your LD_LIBRARY_PATH= $ITMHOME/sol293/tu/tusupport/:$ITMHOME/sol293/tu/lib/:$ITMHOME/tmaitm6/sol283/lib/

 

ITCAM for RT 6.2

    1. Setup websphere to include the armjni4.jar file in it's library path. $ITMHOME defaults to c:\ibm\itm for windows and /opt/IBM/ITM/ for unix.
      1. Windows - set ws.ext.dirs $ITMHOME\tmaitm6\t4\lib
      2. Linux - $ITMHOME/li6243/kt4/lib/
      3. AIX - $ITMHOME/aix51/kt4/lib/
      4. HPUX - $ITMHOME/ hpx1111/kt4/lib/
      5. Solaris - $ITMHOME/ sol283/kt4/lib/
    2. Set your LD_LIBRARY_PATH  to include the ARM libraries (before runing ./startServer.sh on unix)
      1. Windows - You can skip this step since ITM automatically includes c:\ibm\itm\tmaitm6\ in your system path. You might need to reboot for it to take effect if you haven't rebooted since you first installed ITM framework.
      2. Linux    - Set your LD_LIBRARY_PATH=  $ITMHOME/li6243/kt4/lib/:$ITMHOME/tmaitm6/li6243/lib/
      3. AIX      - Set your LIBPATH=  $ITMHOME/aix51/kt4/lib/:$ITMHOME/tmaitm6/aix51/lib/
      4. HPUX    - Set your SHLIB_PATH= $ITMHOME/hpx1111/kt4/lib/:$ITMHOME/tmaitm6/hpx1111/lib
      5. Solaris  - Set your LD_LIBRARY_PATH= $ITMHOME/sol283/kt4/lib/:$ITMHOME/tmaitm6/sol283/lib/

ITCAM for RTT 5.3, 6.0, 6.1 only 

  1. Setup websphere to include the armjni4.jar file in it's library path. $MAHOME defaults to c:\Program files\IBM\Tivoli\MA for windows and /opt/IBM/tivoli/MA for unix.
    1. ws.ext.dirs=$MAHOME\lib
  2. Set your LD_LIBRARY_PATH  to include the ARM libraries
    1. Windows – set your PATH to include $MAHOME\bin\w32-ix86\SYSTEM32\
    2. Linux x86- set LD_LIBRARY_PATH to $MAHOME/bin/linux-ix86/USRLIB/
    3. Linux PPC - set LD_LIBRARY_PATH to $MAHOME/bin/linux-ppc/USRLIB/
    4. Linux s390 - set LD_LIBRARY_PATH to $MAHOME/bin/linux-s390/USRLIB/
    5. AIX - set LIBPATH to $MAHOME/bin/aix4-r1/USRLIB/
    6. HPUX - set SHLIB_PATH to $MAHOME/bin/hpux10/USRLIB/
    7. OS/400 - set LIBPATH to $MAHOME/bin/os400/USRLIB/
    8. Solaris2 - set LD_LIBRARY_PATH to $MAHOME/bin/solaris2/USRLIB/

 

Required for All Versions

  1. Configure request metrics
    1. Detail Level you want (Monitoring and Tuning -> Request Metrics)
      The detail level you want:
      1. HOPS – Entry and exit only. Lowest overhead and only gives overall transaction performance.
      2. Performance_DEBUG – Medium overhead and higher detail. Includes Session Beans etc.
      3. DEBUG – Highest overhead and the most detail. Gives Entity bean get/set timings
    2. Set the Request metrics destination to ARM agent
    3. Set the agent type to ARM4
    4. Set the ARM factory to com.ibm.tivoli.transperf.arm4.transaction.Arm40TransactionFactory
  2. To enable correlator passing to DB2 (required for DB2 to issue ARM calls) do the following
    define this custom JVM property: com.ibm.websphere.pmi.reqmetrics.PassCorrelatorToDB to true;
    To set custom properties, you can either specify the command as a -D option to the Java™ command, or connect to the administrative console and navigate to the Java virtual machine custom properties panel:
    Application server Servers > Application Servers > server1, and then, under Server Infrastructure, click Java and Process Management > Process Definition > Java Virtual Machine > Custom Properties
    Custom Properties Documentation

  3. Restart websphere.
  4. Websphere should now be issuing ARM calls when you navigate through it's servlets. Additionally it should be passing correlators to DB2.

   

Step 3: Configure IHS

Setting up IHS to issue ARM calls is pretty easy, after configuring Websphere all you need to do is regenerate and and redeploy your IHS plugin configuration and it will be configured to issue ARM calls.

 

Step 4: Configure DB2 for ARM support

    DB2 register with ARM if it finds a libarm4.dll (.a/.so) in it's LIBPATH. In order to issue actual start/stop calls for transactions it requires a correlator be passed in with the JDBC connection, which we configured above inside of WAS. To configure the DB2 LIBPATH issue the following command from within the DB2 environment:

db2set DB2LIBPATH=<libarm4.dll directory location>

Where <libarm4.dll directory location> is equal to one of the paths below (

  1. ITCAM for Transactions 7.1 – $ITMHOME defaults to c:\ibm\itm for windows and /opt/IBM/ITM/ for unix.
    1. Windows - You can skip this step since ITM automatically includes c:\ibm\itm\tmaitm6\ in your system path. You might need to reboot for it to take effect if you haven't rebooted since you first installed ITM framework.
    2. Linux    - $ITMHOME/li6263/tu/tusupport:$ITMHOME/li6263/tu/lib/:$ITMHOME/tmaitm6/lib/li6263/
    3. AIX      - $ITMHOME/tmaitm6/aix533/lib/
    4. HPUX    - $ITMHOME/hp11/tu/tusupport/:$ITMHOME/hp11/tu/lib/:$ITMHOME/tmaitm6/hp11/lib/
    5. Solaris  - $ITMHOME/sol293/tu/tusupport/:$ITMHOME/sol293/tu/lib/:$ITMHOME/tmaitm6/sol293/lib/
  2. ITCAM for RT 6.2  – $ITMHOME defaults to c:\ibm\itm for windows and /opt/IBM/ITM/ for unix.
    1. Windows - $ITMHOME\tmaitm6\
    2. Linux - $ITMHOME/li6243/t4/lib/:$ITMHOME/tmaitm6/li6243/lib/
    3. AIX - $ITMHOME/aix51/t4/lib/:$ITMHOME/tmaitm6/aix51/lib/
    4. HPUX - $ITMHOME/ hpx1111/t4/lib/:$ITMHOME/tmaitm6/hpx1111/lib/
    5. Solaris - $ITMHOME/sol283/t4/lib/:$ITMHOME/tmaitm6/sol283/lib/
  3. ITCAM for RTT 5.3, 6.0, 6.1 - $MAHOME defaults to c:\Program files\IBM\Tivoli\MA for windows and /opt/IBM/tivoli/MA for unix.
    1. Windows - $MAHOME\bin\w32-ix86\SYSTEM32\ AND $MAHOME\lib
    2. Linux x86- $MAHOME\bin\linux-ix86\USRLIB\ AND $MAHOME\lib
    3. Linux PPC - $MAHOME/bin/linux-ppc/USRLIB
    4. Linux s390 - $MAHOME/bin/linux-s390/USRLIB
    5. AIX - $MAHOME/bin/aix4-r1/USRLIB/
    6. HPUX - $MAHOME/bin/hpux10/USRLIB/
    7. OS/400 - $MAHOME/bin/os400/USRLIB
    8. Solaris - $MAHOME/bin/solaris2/USRLIB/

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Posted by bpatters on Tuesday, November 25, 2008 3:01 PM
Permalink | Comments (0) | Post RSSRSS comment feed

Working with Image Metadata in .NET 3.0 Part I

Working with image metadata has always been pretty painful. There are several standards out there, with alot of overlap and data conversion to/from the meta data to consumable values is usually required. There have been numerous blogs and code samples for working with metadata in .NET 2.0, so I'm only going to focus on using the latest .NET 3.0.

In .NET 3.0 accessing basic image metadata is very simple.

First get the System.Windows.Media.Imaging.BitmapSource:

   1: public static BitmapSource GetBitmapSource(string filename)
   2: {
   3:     BitmapSource rv = null;
   4:     BitmapDecoder decoder;
   5:     if (File.Exists(filename))
   6:     {
   7:         using (FileStream fs = new FileStream(filename, FileMode.Open, FileAccess.Read, FileShare.Read))
   8:         {
   9:             decoder = BitmapDecoder.Create(fs, BitmapCreateOptions.None, BitmapCacheOption.OnLoad);
  10:  
  11:             if (decoder != null)
  12:             {
  13:                 rv = decoder.Frames[0];
  14:             }
  15:  
  16:             fs.Close();
  17:         }
  18:     }
  19:  
  20: }

Next you can pull out all of the metadata into a Dictionary<string,string> using something simple like:

   1: public const string METADATA_TITLE = "Title";
   2: public const string METADATA_SUBJECT = "Subject";
   3: public const string METADATA_RATING = "Rating";
   4: public const string METADATA_LOCATION = "Location";
   5: public const string METADATA_KEYWORDS = "Keywords";
   6: public const string METADATA_FORMAT = "Format";
   7: public const string METADATA_DATETAKEN = "DateTaken";
   8: public const string METADATA_COPYRIGHT = "Copyright";
   9: public const string METADATA_COMMENT = "Comment";
  10: public const string METADATA_CAMERAMODEL = "CameraModel";
  11: public const string METADATA_CAMERAMANUFACTURER = "CameraManufacturer";
  12: public const string METADATA_AUTHOR = "Author";
  13: public const string METADATA_APPLICATIONNAME = "ApplicationName";
  14: public static void GetImageMetadata(Dictionary<string, string> result, BitmapSource bs)
  15: {
  16:  
  17:     if (bs != null)
  18:     {
  19:  
  20:         BitmapMetadata meta = bs.Metadata as BitmapMetadata;
  21:         if (meta.Title != null)
  22:         {
  23:             result.Add(METADATA_TITLE, meta.Title);
  24:         }
  25:         if (meta.Subject != null)
  26:         {
  27:             result.Add(METADATA_SUBJECT, meta.Subject);
  28:         }
  29:  
  30:         result.Add(METADATA_RATING, meta.Rating.ToString());
  31:         if (meta.Location != null)
  32:         {
  33:             result.Add(METADATA_LOCATION, meta.Location);
  34:         }
  35:         if (meta.Format != null)
  36:         {
  37:             result.Add(METADATA_FORMAT, meta.Format);
  38:         }
  39:         if (meta.DateTaken != null)
  40:         {
  41:             result.Add(METADATA_DATETAKEN, meta.DateTaken);
  42:         }
  43:         if (meta.Copyright != null)
  44:         {
  45:             result.Add(METADATA_COPYRIGHT, meta.Copyright);
  46:         }
  47:         if (meta.Comment != null)
  48:         {
  49:             result.Add(METADATA_COMMENT, meta.Comment);
  50:         }
  51:         if (meta.CameraModel != null)
  52:         {
  53:             result.Add(METADATA_CAMERAMODEL, meta.CameraModel);
  54:         }
  55:         if (meta.CameraManufacturer != null)
  56:         {
  57:             result.Add(METADATA_CAMERAMANUFACTURER, meta.CameraManufacturer);
  58:         }
  59:         StringBuilder keywords = new StringBuilder();
  60:         if (meta.Keywords != null)
  61:         {
  62:             foreach (string s in meta.Keywords)
  63:             {
  64:                 keywords.Append(s).Append(" ");
  65:             }
  66:             result.Add(METADATA_KEYWORDS, keywords.ToString().Trim());
  67:         }
  68:         if (meta.ApplicationName != null)
  69:         {
  70:             result.Add(METADATA_APPLICATIONNAME, meta.ApplicationName);
  71:         }
  72:         if (meta.Author != null)
  73:         {
  74:             StringBuilder authors = new StringBuilder();
  75:             foreach (string s in meta.Author)
  76:             {
  77:                 authors.Append(s).Append(",");
  78:             }
  79:             result.Add(METADATA_AUTHOR, authors.ToString().TrimEnd(new char[] { ',' }));
  80:         }
  81:  
  82:     }
  83: }

As you can see in the code .NET 3.0 provides some really useful convenience methods for accessing image metadata. You will also notice that the Keywords and Author properties are collections and can have multiple values. More on that later.

 

The above is fine if those are the only metadata fields you wish to access. If you want to access all of the metadata fields you need to use the new Query interface:

   1: BitmapMetadata meta = bs.Metadata;
   2: // to obtain the camera manufacturer
   3: // check if the data is present, otherwise you will get an exception in GetQuery
   4: if (bs.ContainsQuery("/xmp/tiff:make")) {
   5:     string CameraManufacturer = (string)bs.GetQuery("/xmp/tiff:make");
   6: }
   7: // or you can get the exif Camera Manufacturer
   8: if (bs.ContainsQuery("/app1/ifd/{ushort=271}")) {
   9:     string CameraManufacturer = (string)bs.GetQuery("/app1/ifd/{ushort=271}");
  10: }



Pretty nice. However those query syntaxes really leave alot to be desired. You can also use the following syntax to perform BOTH of the above in a priority order, with the first one called and if not data exists then it calls the second one:

   1: if (meta.ContainsQuery("System.Photo.CameraManufacturer")) {
   2:     string CameraManufacturer = (string)meta.GetQuery("System.Photo.CameraManufacturer");
   3: }


You can find all of the "System" query documentation at the following URL: http://msdn2.microsoft.com/en-us/library/bb643802.aspx
*NOTE: I recently opened a defect against microsoft for these fields, it appears this works for everything except those of type RATIONAL.

The documentation is for C/C++ code, however you can translate it into equivalent c# pretty easily.

One little quirk is that the code doesn't necessarily return very easy to work with data types. A good example of this is the System.Photo.DateTaken query returns a FILETIME object. You can convert this to a datetime object using:

 

   1: System.Runtime.InteropServices.ComTypes.FILETIME ft = (System.Runtime.InteropServices.ComTypes.FILETIME)_Value; 
   2:  
   3: DateTime time; 
   4:  
   5: long ticks = 0; 
   6:  
   7:  
   8:  
   9: ticks = ((long)ft.dwHighDateTime) << 32; 
  10:  
  11: += ft.dwLowDateTime; 
  12:  
  13: time = DateTime.FromFileTimeUtc(ticks); 

.NET 3.0 also allows you to modify these values using SetQuery, this will be the topic of Part II.

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Posted by bpatters on Thursday, December 06, 2007 8:45 AM
Permalink | Comments (2) | Post RSSRSS comment feed

ITCAM for RT 6.2 and ARM instrumentation debugging.

Turning on tracing for the ITCAM ARM DLL is now easier than ever.

Client Application Tracker Agent

Goto the $ITMHOME/tmaitm6/arm/log/cat directory do one of the following:

  1. Create a file named debug_all.txt - This turns on DLL level tracing for all processes.
  2. Create a file named debug_<pid>.txt – This turns on DLL level tracing only for the specified process.

This turns on debugging until you delete the file, and then the tracing turns off.

Robotic Agent

Goto the $ITMHOME/tmaitm6/arm/log/kt6 directory do one of the following:

  1. Create a file named debug_all.txt - This turns on DLL level tracing for all processes.
  2. Create a file named debug_<pid>.txt – This turns on DLL level tracing only for the specified process.

This turns on debugging until you delete the file, and then the tracing turns off. Be aware that this will incur significant overhead and only leave it on as long as you need it.

General Notes

If both agents are on the same machine, then you will use the CAT instructions for all ARM applications except our robotic agents.

All logging will goto (ensure the directories exist before you turn logging on, or you won't get any logging).

Windows:

C:\program files\ibm\tivoli\common\bwm\logs\trace-armdebug.log

Unix:

/opt/ibm/tivoli/common/bwm/logs/trace-armdebug.log

 

Important things to keep in Mind

  • Also keep in mind that the files sizes are not limited and do not rollover, so you will need to turn off tracing and delete the files when you are done.
  • Tracing every ARM call will incur significant overhead and you should only leave it on as long as you need it.

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Categories: ARM
Posted by bpatters on Wednesday, October 24, 2007 4:57 PM
Permalink | Comments (0) | Post RSSRSS comment feed

Configuring DB2 and Websphere to Issue ARM calls to ITCAM

Probably the most common question I get asked is "How do I configure Websphere and/or DB2 to issue ARM calls?". Below is the answer, enjoy!

   

General Requirements

   

  1. DB2 Distributed Version 8.2 (or 8.1 FP11)
    1. Only non-zos DB2 8.2+ supports ARM, and it supports ARM v4
  2. Websphere Application Server 5.1 or higher
    1. Only Sebsphere can pass correlators to DB2, and DB2 will not issue ARM calls unless a correlator is received for the connection.

Step 1: (RT 6.2 only )Install the Client Application Monitoring Agent

    The CAT agent is the agent that supports Generic ARM instrumentation. Installing it automatically installs support for all ARM instrumented applications (t4 is it's prefix as you will see in paths below).

Step 2: Configure Websphere

  1. Set a custom property (Application Servers->server1->ProcessDefinition->Java Virtual Machine -> Custom Properties) of ws.ext.dirs equal to the values below ( which will include the armjni4.jar, armjni4.dll and libarm4.dll files. ) – Key is to have ws.ext.dirs point to where the armjni4.jar file is located at.

ITCAM for RT 6.2 and above only 

    1. Setup websphere to include the armjni4.jar file in it's library path. $ITMHOME defaults to c:\ibm\itm for windows and /opt/IBM/ITM/ for unix.
      1. Windows - set ws.ext.dirs $ITMHOME\tmaitm6\t4\lib
      2. Linux - $ITMHOME/li6243/kt4/lib/
      3. AIX - $ITMHOME/aix51/kt4/lib/
      4. HPUX - $ITMHOME/ hpx1111/kt4/lib/
      5. Solaris - $ITMHOME/ sol283/kt4/lib/
    2. Set your LD_LIBRARY_PATH  to include the ARM libraries (before runing ./startServer.sh on unix)
      1. Windows - You can skip this step since ITM automatically includes c:\ibm\itm\tmaitm6\ in your system path. You might need to reboot for it to take effect if you haven't rebooted since you first installed ITM framework.
      2. Linux    - Set your LD_LIBRARY_PATH=  $ITMHOME/li6243/kt4/lib/
      3. AIX      - Set your LIBPATH=  $ITMHOME/aix51/kt4/lib/
      4. HPUX    - Set your SHLIB_PATH= $ITMHOME/hpx1111/kt4/lib/
      5. Solaris  - Set your LD_LIBRARY_PATH= $ITMHOME/sol283/kt4/lib/

 

ITCAM for RTT 5.3, 6.0, 6.1 only 

  1. Setup websphere to include the armjni4.jar file in it's library path. $MAHOME defaults to c:\Program files\IBM\Tivoli\MA for windows and /opt/IBM/tivoli/MA for unix.
    1. ws.ext.dirs=$MAHOME\lib
  2. Set your LD_LIBRARY_PATH  to include the ARM libraries
    1. Windows – set your PATH to include $MAHOME\bin\w32-ix86\SYSTEM32\
    2. Linux x86- set LD_LIBRARY_PATH to $MAHOME/bin/linux-ix86/USRLIB/
    3. Linux PPC - set LD_LIBRARY_PATH to $MAHOME/bin/linux-ppc/USRLIB/
    4. Linux s390 - set LD_LIBRARY_PATH to $MAHOME/bin/linux-s390/USRLIB/
    5. AIX - set LIBPATH to $MAHOME/bin/aix4-r1/USRLIB/
    6. HPUX - set SHLIB_PATH to $MAHOME/bin/hpux10/USRLIB/
    7. OS/400 - set LIBPATH to $MAHOME/bin/os400/USRLIB/
    8. Solaris2 - set LD_LIBRARY_PATH to $MAHOME/bin/solaris2/USRLIB/

 

Required for All Versions

  1. Configure request metrics
    1. Detail Level you want (Monitoring and Tuning -> Request Metrics)
      The detail level you want:
      1. HOPS – Entry and exit only. Lowest overhead and only gives overall transaction performance.
      2. Performance_DEBUG – Medium overhead and higher detail. Includes Session Beans etc.
      3. DEBUG – Highest overhead and the most detail. Gives Entity bean get/set timings
    2. Set the Request metrics destination to ARM agent
    3. Set the agent type to ARM4
    4. Set the ARM factory to com.ibm.tivoli.transperf.arm4.transaction.Arm40TransactionFactory
  2. To enable correlator passing to DB2 (required for DB2 to issue ARM calls) do the following
    define this custom JVM property: com.ibm.websphere.pmi.reqmetrics.PassCorrelatorToDB to true;
    To set custom properties, you can either specify the command as a -D option to the Java™ command, or connect to the administrative console and navigate to the Java virtual machine custom properties panel:
    Application server Servers > Application Servers > server1, and then, under Server Infrastructure, click Java and Process Management > Process Definition > Java Virtual Machine > Custom Properties
    Custom Properties Documentation

  3. Restart websphere.
  4. Websphere should now be issuing ARM calls when you navigate through it's servlets. Additionally it should be passing correlators to DB2.

   

Step 3: Configure DB2 for ARM support

    DB2 register with ARM if it finds a libarm4.dll (.a/.so) in it's LIBPATH. In order to issue actual start/stop calls for transactions it requires a correlator be passed in with the JDBC connection, which we configured above inside of WAS. To configure the DB2 LIBPATH issue the following command from within the DB2 environment:

db2set DB2LIBPATH=<libarm4.dll directory location>

Where <libarm4.dll directory location> is equal to one of the paths below:

  1. ITCAM for RT 6.2 and above – $ITMHOME defaults to c:\ibm\itm for windows and /opt/IBM/ITM/ for unix.
    1. Windows - $ITMHOME\tmaitm6\
    2. Linux - $ITMHOME/li6243/t4/lib/
    3. AIX - $ITMHOME/aix51/t4/lib/
    4. HPUX - $ITMHOME/ hpx1111/t4/lib/
    5. Solaris - $ITMHOME/sol283/t4/lib/
  2. ITCAM for RTT 5.3, 6.0, 6.1 - $MAHOME defaults to c:\Program files\IBM\Tivoli\MA for windows and /opt/IBM/tivoli/MA for unix.
    1. Windows - $MAHOME\bin\w32-ix86\SYSTEM32\ AND $MAHOME\lib
    2. Linux x86- $MAHOME\bin\linux-ix86\USRLIB\ AND $MAHOME\lib
    3. Linux PPC - $MAHOME/bin/linux-ppc/USRLIB