Open Bug 611837 Opened 14 years ago Updated 1 year ago

[meta] Meta: Don't fsync on startup

Categories

(Core :: XPCOM, defect)

x86
Linux
defect

Tracking

()

People

(Reporter: taras.mozilla, Unassigned)

References

(Depends on 2 open bugs, Blocks 2 open bugs)

Details

(Keywords: meta, perf, Whiteboard: [ts] [Snappy:p2])

Attachments

(5 files, 1 obsolete file)

This is to keep track of startup-killing fsyncers
Depends on: 611839
Blocks: 572459
Depends on: 611840
Depends on: 611843
Depends on: 611874
Depends on: 609310
To clarify, at the moment our first startup consists of ~100 fsyncs. I'd like to get that down to 0.
It's really stupid to fsync on first startup since the files being created can not possibly contain useful user data.
Assignee: nobody → vdjeric
Assignee: vdjeric → nobody
I have traced fsync during first startup on MacOS X. See attachment for details.

A few key informations:
- 89 calls to fsync;
- 64 threads created;
- about 12 threads still active at the end of startup (sorry, I forgot to write down the actual number).
My tracing session left me thinking that most of the [fsync]s are due to creating empty databases. If so, we could simply ship FF with a set of empty databases and copy the files, which should be much faster.
Traced fsync during second startup on MacOS X. See attachment for details.

A few key informations:
- 2 calls to fsync on critical path to startup;
- 5 calls to fsync backgrounded that may or may not occur during startup;
- about 30 threads created - actual count seems to vary between runs;
- about 19 threads still active at the end of startup - actual count seems to vary between runs.
Assignee: nobody → dteller
Status: NEW → ASSIGNED
Blocks: 447581
Keywords: meta
For reference, here's a list of SQLite requests at startup, taken from my active profile, on Mac.
Here's a refined list of requests executed at startup. Thanks, mak, for the suggestions.
Attachment #565470 - Attachment is obsolete: true
In case anybody needs it, here's the code I used to parse the output of mozStorage:5.
Whiteboard: [ts] → [ts] [Snappy]
Whiteboard: [ts] [Snappy] → [ts] [Snappy:p1]
Whiteboard: [ts] [Snappy:p1] → [ts] [Snappy:p2]
Assignee: dteller → nobody
No assignee, updating the status.
Status: ASSIGNED → NEW
No assignee, updating the status.
Severity: normal → S3
Summary: Meta: Don't fsync on startup → [meta] Meta: Don't fsync on startup
You need to log in before you can comment on or make changes to this bug.