1

I'am using Ubuntu Mate 14.04.2 on my Compaq mini and on certain websites it becomes extreemly low, and at that time looking at the system monitor CPU is always at 100%. (see picture attached) I extended Ram from 1GB to 2Gb but it stays always below 40% (see picture attached) so it might not be of any use? And it looks like that the exchange is never used at it stays always at 0% (see picture attached). What can I do? Thank you!

CPU and Ram

when facebook open I have this, otherwise CPu stays at 20%:

 PID USUARIO   PR  NI    VIRT    RES    SHR S  %CPU %MEM     HORA+ ORDEN
 2237 yasmich   20   0 1390284 466108  91592 R 141,3 22,6  87:07.11 firefox
 5367 yasmich   20   0  240736  62184  48520 S  26,4  3,0   0:01.38 Web Content
 1292 root      20   0  127644  50968  36176 S  11,2  2,5   8:22.74 Xorg
 1846 yasmich   20   0  168012  24108  20896 S   3,3  1,2   0:19.06 wnck-applet
 5345 yasmich   20   0  176852  30028  22424 R   2,3  1,5   0:00.94 mate-terminal
 1217 nobody    20   0    6836   3100   2892 S   1,0  0,2   0:06.93 dnsmasq
 2234 yasmich   20   0  231320  75068  49424 S   0,7  3,6   2:25.33 vlc  
Doug Smythies
  • 16,146
michael
  • 139

2 Answers2

1

First, the CPU graph of the System Monitor is itself pretty exhausting for old machines. Depending on your CPU and graphics, only displaying this chart with a high enough refresh rate may probably cause the high CPU usage.

As a replacement, open a terminal and run top. It also monitors resource usage and processes, but is far more lightweight. It's not very nicely designed though...

Example for top:

Tasks: 168 total,   1 running, 167 sleeping,   0 stopped,   0 zombie
%Cpu(s): 33,6 us,  9,6 sy,  0,1 ni, 54,8 id,  1,9 wa,  0,0 hi,  0,0 si,  0,0 st
KiB Mem:   2062940 total,  1888640 used,   174300 free,    83472 buffers
KiB Swap:  2725884 total,    18656 used,  2707228 free.   630612 cached Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                        
 2345 root      20   0  183180  73228  31776 S  23,7  3,5  13:32.73 Xorg                                                           
 4065 ipc-adm+  20   0 1455540 546436  74368 S  17,8 26,5  41:47.86 firefox                                                        
   32 root      20   0       0      0      0 S   5,9  0,0   0:12.71 kworker/1:1                                                    
 3598 ipc-adm+   9 -11  298260  11392   9572 S   5,9  0,6   4:26.09 pulseaudio                                                     
 7751 root      20   0       0      0      0 S   5,9  0,0   0:01.08 kworker/u4:0                                                   
10384 ipc-adm+  20   0  112304  30712  25976 S   5,9  1,5   0:00.91 gnome-terminal-                                                
10458 ipc-adm+  20   0    6896   2700   2332 R   5,9  0,1   0:00.01 top 

A nicer interface has htop, but it is not installed by default. Run sudo apt-get install htop to get it.

Example for htop:

enter image description here

Please close the System Monitor and check the CPU usage again with one of those tools. Probably you will get very different results.

Also you can directly see which processes are using how many percents of your CPU time and memory consumption. This allows you to narrow the problem down to probably a single application - if it still is a problem at all.


Why do you expect a high RAM usage? It states 2.0 GB available, so that's fine. It's exactly what we would expect. You're just currently not needing more than 732MB, so why should Ubuntu decide to eat up more?

And no swap usage is also optimal, because Ubuntu usually tries to avoid swapping unless it almost runs out of memory or surely knows that some memory pages won't be used. Be happy that your swap is not in use, because the HDD is so much slower than RAM, you would quickly notice decrease of the overall system performance as soon as swapping starts.

Byte Commander
  • 110,243
1

I'd installed a copy of Ubuntu on an older test box at home. I'd wanted to see how it ran on older hardware. Anyhow, had similar issues. I did a combination of three things and it worked for me.

First, I set it to use the "performance" setting in the governor to stop it throttling the CPU. You can do that by following this information: How I can disable CPU frequency scaling and set the system to performance?

Second, I set it to use more RAM (this is what I think may be your biggest help or will best address your question). You can learn how to do this here: How to make ubuntu use more RAM to cache a specific set of binaries?

Finally, as strange as it sounds, I tend to leave a text editor open as I take a lot of notes. For some reason (and I know not why) Gedit was really problematic - it wasn't eating a lot of RAM or CPU but somehow was making my typing (even in other applications) slow. I have no idea even how that would happen but I do know that I can replicate the process time and time again by simply opening the application up and leaving it open with a few tabs available. This is not to suggest that the behavior is the same at your end but you may find that closing applications and then opening them up individually may help.

In other words, is your system speedy/responsive when you have just started it or does it slow down after you have a few applications open? If so then take a look at some alternative applications.

I can't be certain but that is what got my system squared away.

KGIII
  • 4,101