Announcement

Collapse
No announcement yet.

Turbostat Becomes Semi-Useful To Non-Root Users

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Turbostat Becomes Semi-Useful To Non-Root Users

    Phoronix: Turbostat Becomes Semi-Useful To Non-Root Users

    The turbostat utility is useful on Linux systems for reporting idle/power-state statistics, temperatures, and other useful metrics for modern CPUs. It's also able to dive deeper and provide various MSR values and counters and other intriguing CPU bits. For much of these features root access is required and thus turbostat has bailed out up to this point if not running as root. But as a number of the metrics can still be obtained without root access, turbostat is finally being adapted to handle running better as a non-root user...

    Phoronix, Linux Hardware Reviews, Linux hardware benchmarks, Linux server benchmarks, Linux benchmarking, Desktop Linux, Linux performance, Open Source graphics, Linux How To, Ubuntu benchmarks, Ubuntu hardware, Phoronix Test Suite

  • #2
    Very cool! The article is tagged under Intel, does anyone know if it would work on an AMD system? I recently installed Antix on my ThinkPad after some FreeBSD BS and would love to see the numbers!

    Comment


    • #3
      Originally posted by kylew77 View Post
      Very cool! The article is tagged under Intel, does anyone know if it would work on an AMD system? I recently installed Antix on my ThinkPad after some FreeBSD BS and would love to see the numbers!
      As far as I can tell, yes! Turbostat appears to report accurate numbers on my Ryzen 5 8500G.

      Comment


      • #4
        Originally posted by kylew77 View Post
        Very cool! The article is tagged under Intel, does anyone know if it would work on an AMD system? I recently installed Antix on my ThinkPad after some FreeBSD BS and would love to see the numbers!
        Works fine on AM5 / Zen 4 here.

        Comment


        • #5
          Zen 3 here, but I only ever used it as root. Don't think it even starts with user priv.?

          Comment


          • #6
            Originally posted by kylew77 View Post
            Very cool! The article is tagged under Intel, does anyone know if it would work on an AMD system? I recently installed Antix on my ThinkPad after some FreeBSD BS and would love to see the numbers!

            It works very well on AMD. I use it on a Zen 3. Nevertheless, the AMD CPUs expose a little less information than the Intel CPUs, but the most important things are available.

            There was a time when turbostat did not know how to get the power consumption on AMD, but that has been solved a long time ago.


            Comment


            • #7
              Originally posted by AdrianBc View Post


              It works very well on AMD. I use it on a Zen 3. Nevertheless, the AMD CPUs expose a little less information than the Intel CPUs, but the most important things are available.

              There was a time when turbostat did not know how to get the power consumption on AMD, but that has been solved a long time ago.

              Thanks, I'll try to get it to work! Last night I tried typing in turbostat as root and no command was found so then I tried apt install turbostat and that didn't work either. I'm sure with a bit of googleing I can find the package it is in.

              Comment


              • #8
                Originally posted by kylew77 View Post

                Thanks, I'll try to get it to work! Last night I tried typing in turbostat as root and no command was found so then I tried apt install turbostat and that didn't work either. I'm sure with a bit of googleing I can find the package it is in.

                "turbostat" is not found in a package, it is a tool included with the Linux kernel.

                If you do not have them, you must download the latest Linux kernel sources and unpack them in "/usr/src".

                Then you must go to "/usr/src/linux-6.x.x/tools/power/x86/turbostat".

                There, as root, you should do "make; make install", which will install turbostat.

                Then you should create an alias or a script for invoking turbostat with whatever options you prefer.

                I use:

                "turbostat --show Core,CPU,Avg_MHz,Busy%,Bzy_MHz,TSC_MHz,PkgTmp,Core Tmp,PkgWatt,CorWatt"

                (for some weird reason saving this message inserts a space in CoreTmp above, there should be no such space in any of the field names)
                (PkgTmp and CoreTmp are displayed only on Intel)
                Last edited by AdrianBc; 20 April 2024, 07:22 AM.

                Comment

                Working...
                X