Command: measure
The measure
command provides a real-time view of your CPU's power consumption, temperature, and frequency. It's an essential tool for understanding your system's behavior and for tuning your configuration.
Note: The
intel_rapl
kernel module must be loaded for power consumption data to be available.
Synopsis
sudo intel-undervolt measure [OPTIONS]
Description
The command reads data from various /sys
filesystem interfaces, including:
/sys/class/powercap
for RAPL power data./sys/class/hwmon
forcoretemp
temperature data./sys/bus/cpu/devices/cpu*/cpufreq
for core frequencies.
It continuously polls this data at a specified interval and displays it in a user-friendly format.
Options
-
-f
,--format <format>
Sets the output format. The default isterminal
.terminal
: A human-readable format that continuously updates in the same terminal window.csv
: Comma-Separated Values format. Each reading is printed on a new line, prefixed with an elapsed time in seconds. Useful for logging and plotting data.
-
-s
,--sleep <interval>
Sets the sleep interval between measurements, in seconds. Can be a floating-point number. The default is1
second.
Examples
Interactive Terminal Mode
Run with default settings (1-second updates, terminal format):
sudo intel-undervolt measure
Example output (updates in place):
package-0: 9.501 W
core: 4.812 W
uncore: 1.011 W
Package id 0: 45.000 °C
Core 0: 42.000 °C
Core 1: 45.000 °C
Core 0: 800.000 MHz
Core 1: 800.000 MHz
Core 2: 800.000 MHz
Core 3: 800.000 MHz
Logging to CSV
Run with a 500ms interval and output to CSV format, redirecting to a file:
sudo intel-undervolt measure --sleep 0.5 --format csv > measurements.log
Example measurements.log
content:
0.000;9.501;4.812;1.011;45.000;42.000;45.000;800.000;800.000;800.000;800.000
0.501;12.734;7.100;1.234;48.000;46.000;48.000;2400.000;2400.000;2100.000;2100.000
...
The columns correspond to the same order as the terminal output: elapsed time, power domains, temperatures, and core frequencies.