Skip to content

monomorphized/counter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

counter

Kernel module that traces KVM VMExit events and correlates exit reason sequences to detect patterns as well as profiling L2 guest behavior. It hooks into KVM tracepoints to capture nested virtualization exits with small overhead

Features

Counter screenshot

Requirements

  • Linux kernel 5.10+ with KVM support
  • Kernel headers for target kernel
  • Debugfs mounted
  • Root for module loading
  • Virtualization support (VT-x/AMD-V)

Build/Install

make
sudo make install

Usage

Load Module

sudo insmod counter.ko

With params:

sudo insmod counter.ko enable_on_load=1 max_correlations=2048 sample_rate=2 correlation_window=12

The correlation engine tracks sequences of VMExit reasons using a sliding window. Each window is hashed with jhash2 and stored in a list. When the same hash appears again the occurrence count and latency statistics are updated. This identifies recurring exit patterns that indicate specific guest behaviors

About

VMExit reason correlation/L2 guest behavior profiling for KVM nested virtualization environments

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors