Skip to content

python wrapper to get some diagnostic information from JVMs running in kubernetes pods

Notifications You must be signed in to change notification settings

vigevenoj/kube_java_diagnostics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

kube_java_diagnostics

Wrapper around the Python Kubernetes client to get some diagnostic information from JVMs running in pods, specifically thread dumps and class histograms.

Prerequisites

  1. A working kubectl configuration
  2. python3

Installation

  1. Clone the repository
  2. pip install -r requirements.txt (in a virtualenv, probably :) )

Usage

Available options:

  • --namespace (required): what namespace the pods are in
  • --label: If the Java application is in pods that have a label, use this to restrict to which pods the script connects
  • --pod: If you want to connect to only a single pod, specify it here
  • --container: If the pod contains multiple containers, specify the name of the container running the Java application
  • --main: Specify the main class running in the JVM

The script will collect thread dumps and a class histogram from each JVM it connects to, and save them to files named based on the namespace and pod name, like namespace_podname_yyyymmdd-HHMM_threaddump.out and namespace_podname_yyyymmdd-HHMM_histogram.txt

About

python wrapper to get some diagnostic information from JVMs running in kubernetes pods

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages