hang on exit while deleting large cache directory

RESOLVED WONTFIX

Status

()

Core
Networking: Cache
RESOLVED WONTFIX
6 years ago
2 years ago

People

(Reporter: dherman, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Reporter)

Description

6 years ago
Nightly (slightly out of date -- last updated October 31) was hanging on exit. I sampled a stack trace with Activity Monitor, and found it was spinning its wheels trying to delete directories, and I did an lsof to find out what directories were open; it looks like it was trying to delete stuff from the cache.

The cache had gotten huge (about 1 1/2 GB), and doing stuff like tarballing it (which I've done in case anyone wants a copy of it) and du -s -m were veeeeery slow (about an hour for the former, maybe 10 - 15minutes for the latter). But rm -rf was actually pretty fast; maybe only about a minute. These are rough timings, but they give a sense of the scale.

Long story short: from this cursory investigation, it seems like:

a) Normal day-to-day usage of a profile apparently can end up with an enormous cache;

b) NSPR is really slow at deleting very large directories, in a way that the OS seems to be able to beat with rm;

c) We don't have any kind of bailout process on exit in case this spins out of control, so the user has to force quit.

Attaching diagnostic data in a sec.

Dave
(Reporter)

Comment 1

6 years ago
Created attachment 573275 [details]
stack trace taken from sampling the hanging browser
(Reporter)

Comment 2

6 years ago
Created attachment 573276 [details]
the currently-open files while it was hanging

Updated

4 years ago
Component: Profile: BackEnd → Networking: Cache
new cache code
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.