What is necessary to get CPU-G to run on 18.04? I have performed all of the necessary steps I can find (see this post and this post) and searched the internet generally, to no avail.

Attempting to start the program using the Super key brings up the icon, but clicking the icon does nothing. Likewise, entering cpu-g in the Alt-F2 window also has no effect.

I'm sure this must be something really basic, but I don't have the skills to know what to look for.

Thank you.


I couldn't find up-to-date information on cpu-g. In the meantime you might want to try hardinfo which you can install with:

sudo apt install hardinfo

Then typing hardinfo in the terminal or calling from Dash (Alt+F2) the gui appears like this:


You can get most if not all the information you need from cpu-g plus a whole lot more information on your machine.

  • Thank you. I've installed it but it doesn't seem to say anything about installed software.
    – Steev43230
    Jul 28 '19 at 18:23
  • @Steev43230 listing installed software via GUI is covered by many apps. For example: sudo apt install gnome-software, sudo apt install software-properties-gtk and sudo apt install synaptic Jul 28 '19 at 18:46
  • 2
    I see now that you were suggesting an alternative. I did not realize that at first. What I was ultimately looking for from CPU-G was the nice JPG that CPU-Z gives you. Thanks for responding!
    – Steev43230
    Jul 28 '19 at 18:57

Let's see why it does not start:

cd ~/Downloads
wget https://netix.dl.sourceforge.net/project/cpug/cpu-g-0.9.0.tar.gz
tar -xf cpu-g-0.9.0.tar.gz
cd cpu-g-0.9.0

Start it:

$ ./cpu-g
You need to have PyGTK 2.10.0, GTK.Glade and GTK+ 2.10.0 or higher             installed in your system in order to run CPU-G.

So it needs at least two packages to be installed with

sudo apt-get install python-gtk2 python-glade2

Then it will launch:

sudo ./cpu-g

CPU-G on 18.04 LTS

(tested on VM and on real hardware)

About package from PPA (ppa:atareao/atareao) I also see that it does not start with:

$ /opt/extras.ubuntu.com/cpu-g/bin/cpu-g
[Errno 2] No translation file found for domain: 'cpu-g'
[Errno 2] No such file or directory: '/sys/class/power_supply/BAT0/charge_now'
[Errno 2] No such file or directory: '/sys/class/power_supply/BAT0/charge_now'
Traceback (most recent call last):
  File "/opt/extras.ubuntu.com/cpu-g/bin/cpu-g", line 42, in <module>
      cpug = CPUG()
  File "/opt/extras.ubuntu.com/cpu-g/share/cpu-g/cpug.py", line 999, in __init__
  File "/opt/extras.ubuntu.com/cpu-g/share/cpu-g/cpug.py", line 1318, in update_info
  File "/opt/extras.ubuntu.com/cpu-g/share/cpu-g/cpug.py", line 1346, in start_battery_updater
  File "/opt/extras.ubuntu.com/cpu-g/share/cpu-g/cpug.py", line 1079, in get_battery_duration
      inv.battery_info('charge-now')/1000000) + _(' Ah'))
TypeError: unsupported operand type(s) for /: 'str' and 'int'
  • The CPU-G from SourceForge does not have desktop shortcut, so they do not interfere each other. But you can remove atareo's one with sudo apt-get remove cpu-g and sudo apt-get autoremove.
    – N0rbert
    Jul 28 '19 at 18:32
  • I removed the atareo one and installed python-gtk2 python-glade2. It then ran, with the following output cpu set to #0 Traceback (most recent call last): File "./cpu-g", line 330, in core_change self.wTree.get_object("l1data").set_text(main().sysdevcpu(index, 1, 'Data')) File "./cpu-g", line 141, in sysdevcpu print "Error: Cannot decide if the cores are %s or %s.\nUsing the lowest value as the real cores number." %(cpuinfo('coresnum','foo'), coresinsysdev) #FIXME: Wrong text. (?) NameError: global name 'cpuinfo' is not defined [I don't know how to enter line breaks]
    – Steev43230
    Jul 28 '19 at 18:36
  • I have just tested it on real hardware and it works normally. So I can't reproduce the issue. You have to look for alternatives (as in first answer and maybe lshw-gtk).
    – N0rbert
    Jul 28 '19 at 18:43
  • I tried sudo-apt-get remove cpu-g to remove the sourceforge version, but it didn't see the program and so did not remove it. The sourceforge cpu-g hasn't been updated for years and only shows some information, so it's not helpful to me. How do I remove it?
    – Steev43230
    Jul 28 '19 at 18:49
  • Source version was downloaded to ~/Downloads folder. So you can simply remove the cpu-g-0.9.0 folder from it.
    – N0rbert
    Jul 28 '19 at 18:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.