Rate This Document
Findability
Accuracy
Completeness
Readability

Frequency and Power Consumption Analysis

The tool obtains the server's CPU frequency, temperature, and power consumption information based on the hardware driver and BMC information, helping locate service performance bottlenecks and make full use of hardware resources.

Command Function

Obtains the server's CPU frequency, temperature, and power consumption information based on the hardware driver and BMC information.

Syntax

1
devkit tuner turbostat [-h] [-l {0,1,2,3}] [-d <sec>] [-i <sec>] [--bmc]

Parameter Description

Table 1 Parameter description

Parameter

Option

Description

-h/--help

-

Obtains help information. This parameter is optional.

-l/--log-level

0/1/2/3

Log level, which defaults to 1. This parameter is optional.
  • 0: DEBUG
  • 1: INFO
  • 2: WARNING
  • 3: ERROR

-d/--duration

-

Collection duration, in seconds. The minimum value is 1 second. By default collection never ends. You can press Ctrl+\ to cancel the task or press Ctrl+C to stop the collection and start analysis. This parameter is optional.

-i/--interval

-

Collection interval, in seconds. The default value is the collection duration and the minimum value is 1 second. The maximum value cannot exceed the collection duration. This parameter is optional. If this parameter is not set, no subreports are generated. It specifies the time taken to collect data in each subreport.

--bmc

-

Enables interactive input. You can enter the BMC IP address, user name, and password to obtain BMC-related out-of-band data (such as temperature and power consumption). This parameter is optional.

Example

  1. Run the following command to obtain the CPU frequency, temperature, power consumption, and BMC-related data of the server:
    1
    devkit tuner turbostat -d 10 --bmc
    

    -d 10 indicates that the collection duration is 10 seconds and --bmc indicates that BMC-related data is obtained.

  2. Enter the BMC IP address, user name, and password based on the command output to obtain the BMC-related data.
    BMC Host IP: xx.xx.xx.xx
    BMC Username: Administrator
    BMC Password:

    Command output:

    Starting to collect data
    [WARNING]Get socket power failed, possibly due to a low kernel version: [Errno 2] No such file or directory: '/sys/class/hwmon/hwmon1/power1_average'
    ...
    [WARNING]Get socket power failed, possibly due to a low kernel version: [Errno 2] No such file or directory: '/sys/class/hwmon/hwmon1/power1_average'
    CPU and Server Status Summary Report                    Time:2025/12/12 03:17:01
    ================================================================================
    
    CPU Core Frequency Table
    --------------------------------------------------------------------------------
    ──────────────────────────────────────────────────────
    | Logical ID | Physical ID | NUMA ID | Frequency (MHz) |
    ──────────────────────────────────────────────────────
    |          0 |           0 |       0 |          2900.0 |
    |          1 |           0 |       0 |          2900.0 |
    |          2 |           1 |       0 |         2904.59 |
    |          3 |           1 |       0 |         2904.59 |
    |          4 |           2 |       0 |         2895.44 |
    |          5 |           2 |       0 |         2895.44 |
    |          6 |           3 |       0 |         2897.18 |
    |          7 |           3 |       0 |         2897.18 |
    |          8 |           4 |       0 |         2898.61 |
    |          9 |           4 |       0 |         2898.61 |
    |         10 |           5 |       0 |          2900.0 |
    |         11 |           5 |       0 |          2900.0 |
    ...
    |        238 |         119 |       1 |         2899.34
    |        250 |         125 |       1 |         2899.33 |
    |        251 |         125 |       1 |         2899.33 |
    |        252 |         126 |       1 |         2900.67 |
    |        253 |         126 |       1 |         2900.67 |
    |        254 |         127 |       1 |         2897.99 |
    |        255 |         127 |       1 |         2897.99 |
    ──────────────────────────────────────────────────────
    
    CPU Socket status Table (In-band)
    --------------------------------------------------------------------------------
    ──────────────────────────────────────────────────────
    | CPU Socket ID | CPU Socket Power (W) | CPU Socket Die0 Temperature (C) | CPU Socket Die1 Temperature (C) |
    ──────────────────────────────────────────────────────
    |             0 | N/A                  |                           41.31 |                           40.98 |
    |             1 | N/A                  |                           29.87 |                           29.17 |
    ──────────────────────────────────────────────────────
    
    CPU Socket status Table (Out-of-band, '--bmc' required)
    --------------------------------------------------------------------------------
    ────────────────────────────────────────
    | CPU Socket ID | CPU Socket Temperature (C) | CPU Socket Mem Temperature (C) |
    ────────────────────────────────────────
    |             0 |                       40.5 |                           37.0 |
    |             1 |                       29.7 |                           32.0 |
    ────────────────────────────────────────
    
    Server status Table (Out-of-band, '--bmc' required)
    --------------------------------------------------------------------------------
    Total Server Power (W): 299.1
    Total CPU Power (W): 141.9
    Total Memory Power (W): 7.8
    Inlet Temperature (C): 24.0
    Outlet Temperature (C): 37.2
    
    Turbostat does not support 'devkit report'. Users can save the collected report by redirecting the output to a file.

    The command output contains CPU Core Frequency, CPU Socket Status (In-band), CPU Socket Status (Out-of-band), and Server Status.

    • CPU Core Frequency: CPU core frequency.
    • CPU Socket Status (In-band): CPU power consumption and temperature.
    • CPU Socket Status (Out-of-band): CPU temperature related to the BMC.
    • Server status: server status related to the BMC. The options are as follows:
      • Total Server Power (W): total server power consumption collected by the BMC.
      • Total CPU Power (W): total CPU power consumption collected by the BMC.
      • Total Memory Power (W): total memory power consumption collected by the BMC.
      • Inlet Temperature (C): air inlet temperature collected by the BMC.
      • Outlet Temperature (C): air outlet temperature collected by the BMC.