[SOLVED] Conky: CPU usage different that htop shows me.
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi!
I'm using Debian Wheezy with OpenBox in a very old pc, Pentium4 3Ghz.
I would like my Conky1.9 shows my the correct usage of my CPU.
So, the part of conkyrc file that does this is "${cpu}". But when i run htop to make a comparation, htop shows me almost twice of usage of my cpu that Conky does!
Which one is correct and how i can show the correct usage?
Thank you!
Screenshot of my htop and conky on the top of screen.(This time he showed a little bit more of cpu usage that Conky, but he always shows me almost twice of usage)
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
Quote:
Originally Posted by coralfang
The ${cpu} value is showing the averaged use. If you look at the values in htop, there are two cores, conky is averaging that.
If you want to show each individual core, add to your conky something like this:
Code:
CPU0 ${cpu cpu0}% | CPU1 ${cpu cpu1}% |
which should show almost identical values as seen in htop.
I think that that CPU0 is actually the average and you would need to use CPU1 and CPU2 in conky to see the individual readings. Certainly that's how it works in my conky.
Guys. One more thing. If Conky shows me the average of usage, why when i'm compressing a file my system gets extremely slow and Conky shows me 50% or 60% of usage.
I know, probably i'm using for this task 100% of one core and nothing of the other one, but why my system gets so slow? Why he doesn't use the other core?
Because the Pentium 4 never had two cores, the only dual-core Pentiums from that era were the Pentium D CPUs.
What you have is a single core CPU with Hyperthreading, the CPU acts as having two virtual cores to be able to use its different units better. In the case of compressing files the CPU is already using all its parts to the limit so that a better utilization of other parts of the CPU is not possible, making your system slow while it appears to be working at only half its power.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.