Help me find the bottleneck that slows down my pc

Hi,
I keep struggling finding out what is causing my pc to slow down badly when for example I go on webpages with a lot of multimedia content (ex, youtube embedded videos, 9GAG) or when browsing zoomed webpages (example, playstation.com) or another example would be, I if go and copy a large file ( 10GB ) from my HDD to an external portable HDD (WD Passport).

What really happens is this:

My mouse starts stuttering, windows become unresponsive, for example if I minimize firefox and restore it again I get a grey screen and I have to wait until content appears one by one, navigation trough folders is slow, everything takes time, seconds actually. I pop up the Task manager (C+Esc) and my CPU is not fully loaded nor my RAM maxed out. I don’t know why it behaves like the HDD is failing.
Testing the HDD gives ok and speeds of ~101MBPS. The HDD is a WD on SATA2.
Temperatures are ok, CPU in full load is 48 degress C

System is installed as openSUSE wanted, one partition for /, one for user and swap.

I upgraded recently to openSUSE 13.1 x64 KDE. Previously I had 12.2 X64 KDE and after a while I encountered the same issues. I think I might have some bad hardware but I can’t find it, I need to know if there are some tools wich I can use to monitor exaclty what happens when this state of “sickness” comes in. I was thinking on some logging tools, like monitoring the HDD I\O, CPU, GPU, mem usage and the review them.

Here are the specs, not a very up to date PC but ok for office use.

AMD X2 240 Dual Core AM3 (AMD Cool & Quite on)
4GB Dual Channel DDR3
160GB WD SATA2 HDD
ASUS M4A78LT-M
Leadtek GeForce 8600GT 256MB 128Bits with nVidia 331.38 drivers

On 02/26/2014 09:06 AM, robertot5 pecked at the keyboard and wrote:
> Hi,
> I keep struggling finding out what is causing my pc to slow down badly
> when for example I go on webpages with a lot of multimedia content (ex,
> youtube embedded videos, 9GAG) or when browsing zoomed webpages
> (example, playstation.com) or another example would be, I if go and copy
> a large file ( 10GB ) from my HDD to an external portable HDD (WD
> Passport).
>
> What really happens is this:
>
> My mouse starts stuttering, windows become unresponsive, for example if
> I minimize firefox and restore it again I get a grey screen and I have
> to wait until content appears one by one, navigation trough folders is
> slow, everything takes time, seconds actually. I pop up the Task manager
> (C+Esc) and my CPU is not fully loaded nor my RAM maxed out. I don’t
> know why it behaves like the HDD is failing.
> Testing the HDD gives ok and speeds of ~101MBPS. The HDD is a WD on
> SATA2.
> Temperatures are ok, CPU in full load is 48 degress C
>
> System is installed as openSUSE wanted, one partition for /, one for
> user and swap.
>
> I upgraded recently to openSUSE 13.1 x64 KDE. Previously I had 12.2 X64
> KDE and after a while I encountered the same issues. I think I might
> have some bad hardware but I can’t find it, I need to know if there are
> some tools wich I can use to monitor exaclty what happens when this
> state of “sickness” comes in. I was thinking on some logging tools, like
> monitoring the HDD I\O, CPU, GPU, mem usage and the review them.
>
> Here are the specs, not a very up to date PC but ok for office use.
>
> AMD X2 240 Dual Core AM3 (AMD Cool & Quite on)
> 4GB Dual Channel DDR3
> 160GB WD SATA2 HDD
> ASUS M4A78LT-M
> Leadtek GeForce 8600GT 256MB 128Bits with nVidia 331.38 drivers
>
>

How much system ram does it have? What the output of the command



free


Ken

The first bit concerning web browsing I would blame on flash, its the same here; if I browse with Konqueror the session is also more prone to experience crashes on ‘heavy’ sites. This is not limited to Linux though, some sites are just bloated with pop-up content which is bound to slow down the load time, especially with older computers; however Flash support for Linux is phasing out, so I suppose some of the reason lies there.

On 2014-02-26 15:06, robertot5 wrote:

> What really happens is this:
>
> My mouse starts stuttering, windows become unresponsive, for example if
> I minimize firefox and restore it again I get a grey screen and I have
> to wait until content appears one by one, navigation trough folders is

Have a look at
this thread


Cheers / Saludos,

Carlos E. R.
(from 12.3 x86_64 “Dartmouth” at Telcontar)

I think it’s a dead link Carlos.

On 2014-02-26 16:26, F Sauce wrote:
>
> I think it’s a dead link Carlos.

Oops. Typing mistake.

this thread


Cheers / Saludos,

Carlos E. R.
(from 12.3 x86_64 “Dartmouth” at Telcontar)

Here is the “free” output with my usual Thunderbird running in the background and firefox opened on this page


             total       used       free     shared    buffers     cached
Mem:       4053684    3561504     492180      28844      65140    1950924
-/+ buffers/cache:    1545440    2508244
Swap:      2103292     478860    1624432

I know about flash issues, but it does it on pages with no flash content at all. If I zoom in to read some wikipedia pages, even there it starts to do weirds things.
I also have adblock plugin in Firefox to reduce the clutter of ads popping up.

I will read the topic mentioned !

On 2014-02-27 00:36, robertot5 wrote:
>
> Here is the “free” output with my usual Thunderbird running in the
> background and firefox opened on this page
>
>
> Code:
> --------------------
>
> total used free shared buffers cached
> Mem: 4053684 3561504 492180 28844 65140 1950924
> -/+ buffers/cache: 1545440 2508244
> Swap: 2103292 478860 1624432
>
> --------------------

You are using some swap. Did you hibernate the machine?


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

I’m using the sleep function constantly, not hibernation.

On 2014-02-27 12:46, robertot5 wrote:
>
> robin_listas;2627373 Wrote:

>> You are using some swap. Did you hibernate the machine?

> I’m using the sleep function constantly, not hibernation.

Well, in that case, the total of the software you are using needs more
ram than you have, so that swap is used. This slows down your system.

However, at the moment you issued the ‘free’ command, half the ram was
in buffers and cache, and free memory, so that need for swap would have
been some time ago.

You could check swap usage before and after sleep, and this after a
fresh boot, for verification that swap usage is not caused by the sleep.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

There’s a wonderful firefox extension, called “flashblock”.

Did a reboot, and this is what free shows


Mem:       4053684    3108924     944760      16776     121864    1605768
-/+ buffers/cache:    1381292    2672392
Swap:      2103292          0    2103292

On 2014-02-28 21:16, robertot5 wrote:
>
> Did a reboot, and this is what free shows
>
> Code:
> --------------------
>
> Mem: 4053684 3108924 944760 16776 121864 1605768
> -/+ buffers/cache: 1381292 2672392
> Swap: 2103292 0 2103292
> --------------------

Well, you have to find out what of the things you do causes swap to be
used. Not bad in itself, but if your usage pattern requires swap, well,
you probably need more ram to speed things up, change how you do things,
or accept it.

However, if you hibernate the machine, swap is immediately used, and the
above paragraph is incorrect.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

Did some more investigations today,

Here is the output of free just after I start my PC, cold start, with no applications opened, just desktop.

            total       used       free     shared    buffers     cached
Mem:       4053684    1289840    2763844      15964      53056     559056
-/+ buffers/cache:     677728    3375956
Swap:      2103292          0    2103292
            total       used       free     shared    buffers     cached
Mem:       4053684    2415696    1637988      54352      60156     959432
-/+ buffers/cache:    1396108    2657576
Swap:      2103292          0    2103292

Here is the output of free after I started my usual applications (Thunderbird, Skype) and fired up a firefox page on the Playstation page wich instantly made the scrolling of the page to stutter, dragging a window with the mouse is not fluent, it stutters, everything goes slow.

I see swap is not used, the RAM usage seems below 3gigs, so what causes this ? Could be something related to the GPU and\or drivers ?

An other idea:
Have a look at the “top” command. Alternatively you can use the system-monitor (on KDE: Ctrl+Esc or “KSysGuard”). This outputs the processes that uses the most CPU.

I for instance have to deactivate Apper’s search for updates. On my slow dual-core machine working gets terribly awful when packagekitd sits on one one core.

On 2014-03-01 13:56, robertot5 wrote:

> Here is the output of free after I started my usual applications
> (Thunderbird, Skype) and fired up a firefox page on the Playstation page
> wich instantly made the scrolling of the page to stutter, dragging a
> window with the mouse is not fluent, it stutters, everything goes slow.
>
>
> I see swap is not used, the RAM usage seems below 3gigs, so what causes
> this ? Could be something related to the GPU and\or drivers ?

Yes, it is not swap usage.

If it happens after starting a certain page, maybe that page runs some
scripts that load the CPU. I have seen some such. Typically it is flash,
but it can also be javascript. Or even some animations.

You can keep an open terminal with “top” running on it, to watch if
something is loading the CPU.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

Well, I did kept terminal with top command set on CPU usage and when browsing multimedia filled websites the “plugin-container”, “Xorg” and only sometimes “firefox” eats up 100% of CPU cycles. I got “Xorg” using 99% and “plugin-container” as well.

When browsing zoomed websites with no flash, “/usr/lib64/firefox/firefox” is eating up to 79% CPU cycles.

I just did a test on an older PC, single core Sempron CPU, 2 gigs of DD2 RAM and windows xp, integrated GPU and guess what, I can browse those rich multimedia pages like lightning, no stuttering and no CPU usage above 20%, what the heck ?

Hmm, yeah, this is a common problem (also for me). The flash-player on linux is really poor.

Two things I can propose:

  1. Firefox extensions
    For me the following works nicely: Install the firefox extensions AdBlockPlus (ABP) and NoScript. These will let you decide which plugin and script to run.
    Since then, my firefox is idling at max. 10% with many, many tabs.

Maybe you also try the NoFlash plugin that nrickert proposed.

I think the default settings are rather perfect. Flash is allowed when I want it. Anything else is blocked. If a setting is wrong, you can easily change it in the context-menu.

  1. Fight against proprietary web-standards!

On 2014-03-01 16:26, robertot5 wrote:
>
> Well, I did kept terminal with top command set on CPU usage and when
> browsing multimedia filled websites the “plugin-container”, “Xorg” and
> only sometimes “firefox” eats up 100% of CPU cycles. I got “Xorg” using
> 99% and “plugin-container” as well.

plugin-container is in fact the thing that loads flash.

> When browsing zoomed websites with no flash,
> “/usr/lib64/firefox/firefox” is eating up to 79% CPU cycles.

Well, you have to block flash on all sites. I use “Flashblock 1.5.17”.
When a page contains flash, I get a box with an icon on the center. Only
when I click that icon, flash is enabled and the animation is loaded.

Thus only the flash animations I want do run.

The plugin also blocks html5 animations by default.

If you activate an animation that you do not wish to run, you can simply
use kill to kill the plugin-container instance. Firefox keeps running,
but the box that contained the flash dies.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)