gpu

module
v0.0.0-...-ebbd4fe Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 26, 2019 License: MIT

README

GPU card metrics for monitoring.

We do not parse values in int or float* type and keep them original, end-user should take care type by itself. For example, Open-falcon will parses all values into JSON float64 finally.

Tags

KEY TYPE VALUE NOTES
gpuid string 0~n Intel GPU card is hard-coded 0
vendor string "intel" "nvidia"

Metrics

Intel GPU Card Metrics

KEY TYPE VALUE NOTES
renderbusy GAUGE 0~100 in percent

NVIDIA GPU Card Metrics

KEY TYPE VALUE NOTES
fan GAUGE int
temp GAUGE int
util GAUGE 0~100 in percent
memory_usage GAUGE int in bytes
memory_total GAUGE int in bytes
memory_usage_percent GAUGE memory_usage/memory_total*100 in percent

Build

Collect Intel GPU cards stats requried intel-gpu-tools /usr/bin/intel_gpu_top

sudo apt-get install intel-gpu-tools

NOTICE: Intel GPU card stats collecotr required root privilege.

Collect NVIDIA GPU cards stats requried nvidia-352 /usr/bin/nvidia-smi

sudo apt-get install nvidia-352

Build example

go get -v github.com/OpenCCTV/gpu/gpu
cd $GOPATH/src/github.com/OpenCCTV/gpu/examples/json.gpu
go build -o json.gpu.bin

Start in debug mode

sudo ./json.gpu.bin -debug

For more detail, see source code.

See also

github.com/NVIDIA/gpu-monitoring-tools

Directories

Path Synopsis
examples
json.gpu
Example: collect GPU card metrics and dump into JSON format to stdout.
Example: collect GPU card metrics and dump into JSON format to stdout.
openfalcon.gpu
Example Collect GPU cards metrics and post to open-falcon agent HTTP PUSH API.
Example Collect GPU cards metrics and post to open-falcon agent HTTP PUSH API.
gpu
intel
Collect Intel GPU render busy info via package intel-gpu-tools.
Collect Intel GPU render busy info via package intel-gpu-tools.
nvidia
Collect NVIDIA GPU info via package nvidia-381.
Collect NVIDIA GPU info via package nvidia-381.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL