Closed Bug 65703 Opened 24 years ago Closed 23 years ago

Runaway PSM hogs CPU time and generates threads

Categories

(Core Graveyard :: Security: UI, defect)

1.0 Branch
defect
Not set
major

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: nnbugzilla, Assigned: javi)

References

()

Details

(Keywords: perf)

Attachments

(2 files)

When visiting a secure page, the page rendering slows down to a crawl, and
causes the entire system to slow down as well.  Using (in Windows) a tool like
Wintop, you can see that PSM is eating in excess of 80% of CPU time, and the
number of threads generated can range from the low teens to over 300.  What's
more, sometimes PSM will stay around even after you exit Mozilla.

This is a pretty severe problem, IMHO, as it makes Mozilla practically useless
for secure browsing.

I guess I'm starting this bug to track the problem, as a previous bug dealing
with this (bug 34834) has been closed.
Forgot to mention where to get Wintop, in case someone needs it.  You can find
it as part of the Kernel Toys package at
http://www.microsoft.com/windows95/downloads/contents/wutoys/w95kerneltoy/default.asp.
 Although it says not to use with Win98, it actually does work.
Also forgot to add: this is using build 2001011604 on Win98.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: perf
See also bug #64416 where someone complains about java_vm instances not being
cleaned up properly.

cc self.
Worksforme. I'm just not seeing any problems as described above. Downloading a 
secure page on Win98 can be slow, but even my test page with 100 gif files shows 
that psm.exe is only using up 0.5% of the CPU time. When generating a 
certificate request, it spikes to 54% for a second and then is back down to 0.
Assignee: ddrinan → javi
It's very hard to repro. I only see it every once in a while.

I've been trying to so that I can attach a ps -aux but haven't been successful.
I'll attach one as soon as possible.
I finally reproduced this bug and I'll proceed to attach a ps -aux and top.

Running build 2001011608/Mtrunk/Linux on Mandrake 7.1 with Enlightenment.
BTW, the steps I took to reproduce the bug in this case were as follows:

1.) Went to https://gwmail.mc.edu (the web based groupwise front-end used at my
old school, where I still have an account).
2.) Logged in.
3.) Read a new message and closed it.
4.) Deleted message.
5.) Logged out.
6.) The psm began its antics within seconds of #5

I don't know how much any of those steps had to do with the problem (you aren't
guaranteed to see the problem by following those steps) or if anyone else even
has access to a groupwise webmail frontend.

Other sites I've had the problem at (that I can remember at the moment) are
http://sourceforge.net (login using SSL) and http://www.amazon.com (log in using
secure server to edit account, place order, etc).
One more thing: I just noticed in the comment from junruh@netscape.com that he's
trying to reproduce this while downloading a secure page.
I've always seen this bug _after_ viewing the secure page. Usually within a few
seconds of logging out or moving on to another page. I.e. the psm really should
no longer be running at this point but, not only is it still running, it also
hogs cpu resources.

Let me also add placing an order at http://www.cdnow.com as one of the causes of
this problem (usually seen _after_ completing the order).
I can reproduce the problem immediately by visiting the URL I supplied.  I also
tried a "clean" install of build 2001011704 and got the same results.
Confirming that the digitaleyes.net url supplied by wyoung@nnanime.com
 causes the problem immediately after secure page dialog is dismissed. This
behavior differs from what I reported in that it happens while viewing the page
in question and, at least in my case, cpu usage returns to normal after leaving
the page in question (I didn't log in, of course).
The psm threads, however (all 15 of them) remain after leaving the page.
psm just now started acting up again (the same threads that were running when I
last posted) and slowed my machine to a crawl.

Top showed the following:

20309 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:30 psm
20310 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:30 psm
20311 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:30 psm
20312 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:20 psm
20313 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:20 psm
20314 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:20 psm
20315 vanbalen  12   0  4872 4872  2400 R       0 12.1  2.4   0:20 psm
I also see the problem under the 2.5.01 build of mozilla doing a cvs update -PdA
mozilla/security/psm.

RedHat 6.2 Intel
Not to be annoying, but is there any news on this bug?  Normally, I simply
switch to NS 4.x for secure sites, but some sites like PC Gamer
(http://www.pcgamer.com) do something in the background that causes PSM to load.
 There's no security warning, so I don't even know it's happened until
everything on my system slows to a crawl.
Sometimes some runaway PSM processes block sending mail for me. It just says
"Sending message ..." until I kill the PSM process. I then get a "Sending of
message failed" alert and cannot send any mail until I completely restart Mozilla.

Anyone having the same problem?
OS: Windows 98 → All
Hardware: PC → All
Platform/OS all/all based on the discussion.
Is this the same as bug 60116?
A closer on the PSM problem on sending mail revealed:
1. I press the SEND button for a mail.
2. "Sending message ...", CPU time ist still at 0%.
3. I switch to the Navigator window (with a bugzilla page).
4. CPU time goes to 100% (most of it for PSM).
5. I kill the PSM process.
6. "Sending of message failed."
7. Now the Mozilla process takes up 100% CPU time until I close it.
I also just got this problem while sending email (just started using Mozilla as
my mail reader). I assume that mail/news uses the psm to log into mail servers,
which is why it ran in the first place (I wasn't visiting a secure site with the
browser). Thus this problem affects mail/news as well as browser.

Those of us that have gotten used to looking at top and running killall psm when
our cpu maxes out don't give this too much thought anymore, but there're people
(some of my personal acquaintance) who are hesitant to use Mozilla as their
primary browser (or even at all) because of this very bug... not to mention the
poeple who visit sites that are unusable because of this.
More observations on the problem with mail:

* The problem doesn't occur if I set "Use secure connection (SSL)" for the SMTP
server to "Never" (PSM doesn't get started on sending mail then). Sending seems
generally to work fine with this setting.
* When sending the message does not finish, the CPU time maxes if I touch _any_
GUI element in Mozilla.
* When the CPU is at 100%, Mozilla takes ~50% of that, PSM takes ~30%, and the
System process takes the rest. If I kill PSM, Mozilla takes all 100% (tested on
Win2k).
For the record, I noticed that in the ps -aux dump I attached, there's only one
psm entry (out of 10) which is taking up 73.8% CPU... looks like a separate psm
process (not thread(s)) was spawned which is causing the trouble.
Should bug #60116 be marked a duplicate of this bug?
I get this problem whenever I try to access a secure site. CPU maxes out and
lots of psm threads. It didn't happen with Mozilla 0.7, but started with 0.8.

I'm using Mandrake Linux 7.2.
I've had this problem since I upgraded from Mozilla 0.7 to 0.8. When I try to
access any secure site, my cpu maxes out and I see many psm threads.
I get similar behaviour on the latest builds (2001030608 right now). Multiple
(15 to 20) psm processes are spawned when visiting a site like sourceforge.net.
If left alone, these processes eventually start consuming CPU (I noticed the
problem when Mozilla started becoming very sluggish).

I tested with and without my junkbuster proxy running, and got the same
behaviour. However, we do have a proxying firewall here, so I'm not sure that's
a valid test.

Linux SMP 2.2.17, Gnome 1.2, X 4.0.2 redhat linux 6.2.
*** Bug 73041 has been marked as a duplicate of this bug. ***
nominating nsbeta1. Sevaral users reported a freeze while sending a message due 
to this problem. We cannot affort loosing a message. We need to fix this ASAP 
else I would have to turn off SMTP-SSL!
Keywords: nsbeta1
Well, not only that, but it makes Mozilla unusable for buying things online. I
know the big "e" boom is over, but that's still a pretty popular activity. :)

*** Bug 60116 has been marked as a duplicate of this bug. ***
With build 2001041220, using PSM 2.0, this no longer seems to be a problem, so I
suspect this is FIXED.
Marking fixed.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Verified.
Status: RESOLVED → VERIFIED
Product: PSM → Core
Version: psm1.4 → 1.0 Branch
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: