Discussion:
[ubuntu-us-mi] Firefox on Lucid
Robert Citek
2010-04-15 19:28:21 UTC
Permalink
I use Firefox almost all day long (and night, sometimes). I would say
about twice a day Firefox gets really, really slow. For example, I'll
be scrolling down a three-page website and Firefox will take in excess
of two minutes to get from the top to the bottom. Switching between
tabs is also exceedingly slow. However, I can switch between
applications. When I switch back to Firefox it takes forever to
redraw the screen. And the CPU fan kicks into high gear. The only
solution that has worked so far has been to kill Firefox and then
restart it. Once I do that, I can scroll up and down the same
three-page website in a split second.

Below are the first few lines of a top and a vmstat.

Has anyone else seen this kind of behaviour? Any hint as to where the
problem might be: Firefox, Xorg, video driver, other? Would like to
narrow it down before filing a bug report.

Regards,
- Robert

-----

top - 13:25:05 up 55 min, 2 users, load average: 1.10, 0.89, 0.69
Tasks: 151 total, 2 running, 149 sleeping, 0 stopped, 0 zombie
Cpu0 : 3.7%us, 1.6%sy, 0.0%ni, 94.7%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Cpu1 :100.0%us, 0.0%sy, 0.0%ni, 0.0%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 1017992k total, 574840k used, 443152k free, 41792k buffers
Swap: 2981880k total, 0k used, 2981880k free, 257936k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1517 rwcitek 20 0 380m 140m 30m R 100 14.2 9:21.87
firefox-bin
987 root 20 0 35836 14m 7980 S 2 1.5 1:48.60 Xorg
662 messageb 20 0 3264 1600 788 S 1 0.2 0:01.85
dbus-daemon
1661 rwcitek 20 0 45016 12m 9788 S 1 1.3 0:00.94
gnome-terminal
1683 rwcitek 20 0 2544 1232 932 R 1 0.1 0:00.91 top
1 root 20 0 2796 1616 1172 S 0 0.2 0:00.82 init
2 root 20 0 0 0 0 S 0 0.0 0:00.00 kthreadd
3 root RT 0 0 0 0 S 0 0.0 0:00.00
migration/0
4 root 20 0 0 0 0 S 0 0.0 0:00.03
ksoftirqd/0
5 root RT 0 0 0 0 S 0 0.0 0:00.00
watchdog/0


$ vmstat 1 20
procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----
r b swpd free buff cache si so bi bo in cs us sy id wa
1 0 0 429520 42328 265684 0 0 36 7 172 307 10 2 87 1
1 0 0 425212 42328 270492 0 0 0 0 527 449 51 1 48 0
1 0 0 424808 42328 270652 0 0 0 0 525 444 51 1 49 0
1 0 0 424808 42328 270624 0 0 0 0 525 445 51 0 49 0
1 0 0 424808 42328 270552 0 0 0 0 524 442 51 0 49 0
1 0 0 424808 42328 270752 0 0 0 0 522 439 51 1 48 0
1 0 0 424808 42336 270752 0 0 0 20 530 462 52 0 48 0
1 0 0 424808 42336 270752 0 0 0 0 523 438 51 0 49 0
1 0 0 424808 42336 270756 0 0 0 0 523 445 51 0 49 0
1 0 0 424808 42336 270732 0 0 0 0 523 460 51 1 49 0
1 0 0 424808 42336 270732 0 0 0 0 522 445 51 0 49 0
1 0 0 424808 42336 270732 0 0 0 0 523 450 52 0 49 0
1 0 0 424808 42344 270732 0 0 0 16 529 476 51 0 49 1
1 0 0 424808 42344 270532 0 0 0 12 525 443 52 0 49 0
1 0 0 424808 42344 270476 0 0 0 0 523 446 51 1 49 0
1 0 0 424808 42344 270480 0 0 0 0 527 441 51 0 49 0
1 0 0 424808 42344 270472 0 0 0 0 526 447 51 0 49 0
1 0 0 424808 42344 270472 0 0 0 0 524 446 51 0 49 0
1 0 0 424808 42352 270472 0 0 0 32 530 456 51 1 48 1
1 0 0 424808 42352 270472 0 0 0 0 524 448 51 0 49 0
Jeff Hanson
2010-04-15 20:04:09 UTC
Permalink
Install and run BleachBit. Select Vacuum and then click the Delete button.
Robert Citek
2010-04-15 20:21:31 UTC
Permalink
Install and run BleachBit. ?Select Vacuum and then click the Delete button.
I'd kinda like to know what and where the problem is first before I
install another piece of software that supposedly fixes whatever
problem that is.

How can I go about discovering where the problem is?

FWIW, Firefox has been running just fine for the past hour or so.

Regards,
- Robert
Jeff Hanson
2010-04-15 20:33:24 UTC
Permalink
It's their use of a db for the cache. There was some debate over the
interaction of the new db on ext3 back in Hardy, IIRC.
Robert Citek
2010-04-15 22:40:54 UTC
Permalink
It's their use of a db for the cache. ?There was some debate over the
interaction of the new db on ext3 back in Hardy, IIRC.
I'm not so sure that's the issue. I checked out the sqlite databases
and they are relatively small, with the median being under 10KB, the
mean being about 24M, and the largest db about 32 M.

$ find ~/.mozilla/firefox/ -name '*.sqlite' |
xargs ls -ldSr |
tr -s ' ' '\t' |
cut -f 5 > file.csv
$ echo 'summary(read.csv("file.csv",head=FALSE)) ;' |
R --no-save -q
summary(read.csv("file.csv",head=FALSE)) ;
V1
Min. : 2048
1st Qu.: 2048
Median : 8704
Mean : 2390630
3rd Qu.: 38912
Max. :31281152
If it were a db and/or ext3 issue, would I not see a lot of disk I/O
from the vmstat? I see the CPU being maxed and virtually no disk I/O.
No swapping, either.

Any ideas on how to isolate what the problem is? Is anyone else
experiencing this? If not, then maybe it's something fubared with my
setup.

Regards,
- Robert
Steve Romanow
2010-04-16 03:05:51 UTC
Permalink
Would the content type maybe be a factor? Do mainly text sites bog
down as heavy pages do? Maybe use noscript and or disable flash to
see if js or flash are problems?
Post by Robert Citek
It's their use of a db for the cache. ?There was some debate over the
interaction of the new db on ext3 back in Hardy, IIRC.
I'm not so sure that's the issue. I checked out the sqlite databases
and they are relatively small, with the median being under 10KB, the
mean being about 24M, and the largest db about 32 M.
$ find ~/.mozilla/firefox/ -name '*.sqlite' |
xargs ls -ldSr |
tr -s ' ' '\t' |
cut -f 5 > file.csv
$ echo 'summary(read.csv("file.csv",head=FALSE)) ;' |
R --no-save -q
summary(read.csv("file.csv",head=FALSE)) ;
V1
Min. : 2048
1st Qu.: 2048
Median : 8704
Mean : 2390630
3rd Qu.: 38912
Max. :31281152
If it were a db and/or ext3 issue, would I not see a lot of disk I/O
from the vmstat? I see the CPU being maxed and virtually no disk I/O.
No swapping, either.
Any ideas on how to isolate what the problem is? Is anyone else
experiencing this? If not, then maybe it's something fubared with my
setup.
Regards,
- Robert
--
ubuntu-us-mi mailing list
ubuntu-us-mi at lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-us-mi
--
Sent from my mobile device
Robert Citek
2010-04-16 03:14:05 UTC
Permalink
Would the content type maybe be a factor? ?Do mainly text sites bog
down as heavy pages do? ? Maybe use noscript and or disable flash to
see if js or flash are problems?
Good suggestions. Right now I don't have a consistent way to make it
bog down. I'll try some flash or JS heavy sites and see if I can
create a consistent slow down.

Regards,
- Robert
Robert Citek
2010-04-16 03:32:58 UTC
Permalink
Would the content type maybe be a factor? ?Do mainly text sites bog
down as heavy pages do? ? Maybe use noscript and or disable flash to
see if js or flash are problems?
Good suggestions. ?Right now I don't have a consistent way to make it
bog down. ?I'll try some flash or JS heavy sites and see if I can
create a consistent slow down.
Opened up three tabs to different YouTube videos. While the videos
became more choppy as each new video started and the CPU usage went
through the roof and the fan kicked into take-off mode, Firefox was
able to scroll up/down without a problem.

Regards,
- Robert
Robert Citek
2010-04-16 05:23:55 UTC
Permalink
Would the content type maybe be a factor? ?Do mainly text sites bog
down as heavy pages do? ? Maybe use noscript and or disable flash to
see if js or flash are problems?
The Firefox slowdown just happened again. So I switched over to a
virtual terminal which had top running. Not only was Firefox pegging
the CPU, so was Xorg. As soon as the Xorg process went back to
normal, Firefox responded again even though it was still pegging the
CPU.

Some bizarre interaction between Xorg and Firefox?

Regards,
- Robert
Jeff Hanson
2010-04-16 14:08:50 UTC
Permalink
Post by Robert Citek
Some bizarre interaction between Xorg and Firefox?
Probably Flash. On 64-bit systems it shows up as a separate process
npviewer.bin but on 32-bit it's just part of the Firefox process.
Robert Citek
2010-04-21 02:20:18 UTC
Permalink
Post by Robert Citek
Some bizarre interaction between Xorg and Firefox?
Probably Flash. ?On 64-bit systems it shows up as a separate process
npviewer.bin but on 32-bit it's just part of the Firefox process.
Just saw it happen again: Xorg and Firefox pegging the CPU (over 45%
each) and Firefox slowing to a crawl. As soon as the Xorg process
returned to normal (< 5% CPU), Firefox worked normally. In this case
I only had one tab open to gmail.

In the past few days, however, there have been some updates. And I
haven't experienced this behaviour since the updates. I'd like to
believe it got fixed.

Regards,
- Robert
Jeff Hanson
2010-04-21 02:27:59 UTC
Permalink
Post by Robert Citek
Just saw it happen again: Xorg and Firefox pegging the CPU (over 45%
each) and Firefox slowing to a crawl. ?As soon as the Xorg process
returned to normal (< 5% CPU), Firefox worked normally. ?In this case
I only had one tab open to gmail.
If you are using 32-bit then it's probably Flash and no, the updates
won't fix it.

Loading...