lkstlogtools -- LKST tools for logfile

executables:
  bin/lkstla
  bin/lkstlogdiv
  scripts/lkst_plot_dist
  scripts/lkst_plot_stat
  scripts/lkst_plot_log
  scripts/lkst_plot_sysinfo
  scripts/lkst_fmt_sysinfo
  scripts/lkst_make_mask
  scripts/mksyscalls.sh

lkstla : lkst log analyzer
lkstla analyze binary logfile outputted by lkstlogd or lkstbuf read -f *.
This tool can analyze specific events as "event sessions" and output following
3 formatted data:
log -- output session starting time and session period time.
statistics -- output number of sessions, average, maximum, and minimum
period time.
distribution -- output numbers of sessions classified by period time.

lkstlogdiv : lkst log divider
lkstlogdiv divids a raw logfile (logged by lkstlogd or lkstbuf) into sorted
logfiles.


Installation
------------

prerequires:

- LKST version 2.2.1 or higher
  lkst-2.2.1.tar.gz can be downloaded from
      http://sourceforge.net/projects/lkst/

- Linux version 2.6.9
  linux-2.6.9.tar.bz2 can be downloaded from
      http://www.kernel.org/


1) Unpackage archives
------------------------------------------------------------
1. cd $(SOMEWHERE_LKST)

2. Untar the LKST archive
    tar -xzf  lkst-2.2.1.tar.gz

3. cd $(SOMEWHERE_KERNEL)

4. Untar Linux kernel source
    tar -xjf  linux-2.6.9.tar.bz2

5. cd $(SOMEWHERE_LKST)

6. Untar this package into LKST's directory.
    tar -xzf  lkstlogtools-1.0.1.tar.gz -C lkst-2.2.1/

1) Apply LKST and lkstlogtools' patch for kernel versions 2.6.9
-----------------------------------------------------------------
1. Login as root

2. Issue a command to apply a series of patches to the kernel source.
     cd $(SOMEWHERE_LKST)/lkst-2.2.1/
     make patch KPRESRC=$(SOMEWHERE_KERNEL)/linux-2.6.9
     or
     ./scripts/enpatch.sh $(SOMEWHERE_KERNEL)/linux-2.6.9
     
     After that, answer following questions.

     Apply preassigned page table patch (if not, apply vmsync patch automatically) (Y)es/(N)o? [Y]
     Apply early boot-time tracing patch(optional) (Y)es/(N)o? [Y]
     Apply extra event set patch(optional) (Y)es/(N)o? [Y]
     Apply ignore hooks placed in inline-functions patch(optional) (Y)es/(N)o? [Y]

     If you'd like fullset of LKST, answer "y" for all questions.

3. Issue a command to apply a series of patches to the kernel source.
     cd $(SOMEWHERE_LKST)/lkst-2.2.1/lkstlogtools-1.0.1
     ./scripts/enpatch-llt.sh $(SOMEWHERE_KERNEL)/linux-2.6.9

4. Issue a command to apply a patch to the LKST
     cd $(SOMEWHERE_LKST)/lkst-2.2.1/
     patch -p1 < ./lkstlogtools-1.0.1/patches/lkstuitls-logformat.patch


2) Build and Install the patched linux kernel
----------------------------------------------
1. Build kernel
    a. Kernel Configuration
       cd $(SOMEWHERE_KERNEL)/linux-2.6.9
       make menuconfig

    b. (i386 only) Under "Processor type and features"
      i. Select "64GB" for "High Memory Support"
      or
      i. Select "y" for "Assign page tables for non-contiguous mapped area on boot"
     ii. Select "n" for "Use register arguments"
    c. Under "Kernel hacking", select the following:
      i. Select "y" for "Kernel debugging".
     ii. Select "y" for "Kernel Hook Support".
    iii. Select "y" for "Magic SysRq key". (optional)
     iv. Select "m" for "Kernel State Tracing (LKST)".
      v. Configure other kernel config settings as needed.
    d. Save and Exit
    e. make modules bzImage

2. Install kernel modules and the kernel
   make modules_install
   make install

3. If you use lilo, run /sbin/lilo to read modified lilo.conf
   or If you use the Fedora Core or the Red Hat distributions,  you may fix
   grub.conf to give the new kernel a root partition as a device file path
   (ex. /dev/hda1 ) instead of a label format (ex. "LABEL=/") .

4. reboot


3) Configure and Build and Install lkstutils and lkstaddons
-----------------------------------------------------------
Please refer lkst-2.2.1/Install .


4) Build this lkstlogtools
---------------------------
!!WARNING!!: After configuring the lkstaddons, build the lkstlogtools.
     cd $(SOMEWHERE_LKST)/lkst-2.2.1/lkstlogtools-1.0.1
     make

then you'll have bin/lkstla and bin/lkstlogdiv.

---
 The development of this program is partly supported by IPA
 (Information-Technology Promotion Agency, Japan).
---
 Copyright (C) HITACHI,LTD. 2004-2005

