Skip to content

eco-digit/rosserts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rosserts

This tool generates load and outputs computer power metrics for this load. It's meant to run on an Intel-based bare metal Linux host or inside a VM.

Usage:
   [flags]

Flags:
      --cpu-info                                 output CPU info before results (default true)
      --duration-between-measures duration       the duration to wait between two measures (default 1s)
  -h, --help                                     help for this command
      --ipsec                                    launch ipsec test to trigger advanced CPU instructions. See stress-ng ipsec-mb flag (default true)
      --load-duration-before-measures duration   duration to wait between load start and measures (default 5s)
      --load-step int                            increment the stress load from 0 to 100 with this value (default 25)
      --maximize                                 launch a stress maximizing stressors values. See stress-ng maximize flag (default true)
      --method string                            the method to use to generate the load. See stress-ng cpu-method flag (default "all")
      --metrics strings                          turbostat columns to read (default [PkgWatt,RAMWatt,PkgTmp])
      --repeat int                               measures are repeated with this value and the measure is the mean of all repetitions (default 10)
      --threads int                              number of threads to use for the load (default to the number of threads on the system)
      --vm                                       launch VM test. See stress-ng vm flag (default true)

Without Docker

Requirements

  • stress-ng command
  • turbostat command
  • golang 1.15
  • go run cmd/main.go
  1. Build the Application: go build -o stressor cmd/main.go

  2. Run the Application: sudo ./stressor [flags]

  3. Directly using go run: sudo go run cmd/main.go [flags]

With Docker

Pass flags to the program as environment variables or command-line arguments:

docker build -t stressor .
docker run -it --privileged stressor [flags]
docker run -it --privileged stressor --threads=4 --repeat=5 --metrics=PkgWatt,RAMWatt

Benchmarks

  • Starts at 10% CPU load and increases by 10% increments up to 100%: sudo go run cmd/main.go --load-step=10 --initial-load=10 --method=all --metrics=PkgWatt,PkgTmp
Example output:
test,threads,load,PkgWatt,PkgTmp
CPUStress,8,10,15.23,45.00
CPUStress,8,20,25.87,50.00
CPUStress,8,30,35.12,55.00
  • CPU Stress Test with Specific Method: sudo go run cmd/main.go --method=matrixprod --load-step=20 --threads=8
  • High Repetition with Custom Metrics --repeat=20 --metrics=PkgWatt,CorWatt,GFXWatt --duration-between-measures=500ms
  • VM Stress Test with Maximize Option --vm --maximize --load-step=50

Run as Binary on VM

./amd-stressor --threads 4 --load-step 25 --repeat 3  --duration-between-measures 10s --load-duration-before-measures 10s
# --duration-between-measures must be in type duration
# --load-duration-before-measures must be in type duration

About

Containerized stress-ng combined with turbostat for reporting.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors