com.bigdata.counters.linux
Class StatisticsCollectorForLinux

java.lang.Object
  extended by com.bigdata.counters.AbstractStatisticsCollector
      extended by com.bigdata.counters.linux.StatisticsCollectorForLinux
All Implemented Interfaces:
IStatisticsCollector

public class StatisticsCollectorForLinux
extends AbstractStatisticsCollector

Collection of host performance data using vmstat and sysstat suite.

Version:
$Id: StatisticsCollectorForLinux.java 2265 2009-10-26 12:51:06Z thompsonbry $
Author:
Bryan Thompson
See Also:
http://pagesperso-orange.fr/sebastien.godard/

Nested Class Summary
 
Nested classes/interfaces inherited from class com.bigdata.counters.AbstractStatisticsCollector
AbstractStatisticsCollector.Options
 
Field Summary
protected static KernelVersion kernelVersion
          The Linux KernelVersion.
protected static int pid
          The process identifier for this process (the JVM).
protected  PIDStatCollector pidstat
          reports on process performance counters (CPU, MEM, IO).
protected  String processName
          The name of the process (or more typically its service UUID) whose per-process performance counters are to be collected.
protected  SarCpuUtilizationCollector sar1
          Reports on the host CPU utilization (these data are also available using vmstat).
protected  VMStatCollector vmstat
          Reports on the host page faults, swap space and can report CPU utilization.
 
Fields inherited from class com.bigdata.counters.AbstractStatisticsCollector
fullyQualifiedHostName, hostPathPrefix, interval, log, ps
 
Constructor Summary
StatisticsCollectorForLinux(int interval, String processName)
           
 
Method Summary
 CounterSet getCounters()
          Return the counter hierarchy.
 void start()
          Start collecting host performance data -- must be extended by the concrete subclass.
 void stop()
          Stop collecting host performance data -- must be extended by the concrete subclass.
 
Methods inherited from class com.bigdata.counters.AbstractStatisticsCollector
addBasicServiceOrClientCounters, addGarbageCollectorMXBeanCounters, addServiceProperties, getInterval, installShutdownHook, kb2b, main, newInstance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

pid

protected static int pid
The process identifier for this process (the JVM).


kernelVersion

protected static KernelVersion kernelVersion
The Linux KernelVersion.


processName

protected final String processName
The name of the process (or more typically its service UUID) whose per-process performance counters are to be collected.


sar1

protected SarCpuUtilizationCollector sar1
Reports on the host CPU utilization (these data are also available using vmstat).


vmstat

protected VMStatCollector vmstat
Reports on the host page faults, swap space and can report CPU utilization.


pidstat

protected PIDStatCollector pidstat
reports on process performance counters (CPU, MEM, IO).

Constructor Detail

StatisticsCollectorForLinux

public StatisticsCollectorForLinux(int interval,
                                   String processName)
Parameters:
interval - The interval at which the performance counters will be collected in seconds.
processName - The name of the process (or more typically its service UUID) whose per-process performance counters are to be collected.
Method Detail

start

public void start()
Description copied from class: AbstractStatisticsCollector
Start collecting host performance data -- must be extended by the concrete subclass.

Specified by:
start in interface IStatisticsCollector
Overrides:
start in class AbstractStatisticsCollector

stop

public void stop()
Description copied from class: AbstractStatisticsCollector
Stop collecting host performance data -- must be extended by the concrete subclass.

Specified by:
stop in interface IStatisticsCollector
Overrides:
stop in class AbstractStatisticsCollector

getCounters

public CounterSet getCounters()
Description copied from class: AbstractStatisticsCollector
Return the counter hierarchy. The returned hierarchy only includes those counters whose values are available from the JVM. This collection is normally augmented with platform specific performance counters collected using an AbstractProcessCollector.

Note: Subclasses MUST extend this method to initialize their own counters.

Specified by:
getCounters in interface IStatisticsCollector
Overrides:
getCounters in class AbstractStatisticsCollector


Copyright © 2006-2009 SYSTAP, LLC. All Rights Reserved.