Open Bug 2082673 Opened 1 month ago Updated 12 days ago

Crash in [@ mozilla::net::nsSocketTransportService::AttachSocket] on macOS after the native-messaging pipe leak fix

Categories

(Core :: Networking, defect, P2)

defect

Tracking

()

People

(Reporter: spohl, Unassigned, NeedInfo)

References

Details

(Keywords: crash, Whiteboard: [necko-triaged][necko-priority-next])

Crash Data

As far as I can tell, bug 2073819 appears to have meaningfully reduced some instances of this crash, particularly the recurring macOS 27 pipe-leak pattern. However, not everything appears to be fixed, and I thought it would be good to track the remaining crashes separately.

What appears to have improved:

For reports submitted from September 15 through October 14, unfixed release 156 builds have 41 macOS 27 reports at 36-42 minutes of uptime, compared with none on fixed release 157 or 158 builds in that uptime range. This looks consistent with the fix addressing the recurring native-messaging pipe leak identified in bug 2073819. I don't think uptime alone establishes that every report had the same cause.

What appears to remain:

For the same period, I found 254 matching reports on builds that appear to contain the fix, versus 485 on unfixed builds. I checked the cleanup in subprocess_unix.worker.js at the source revision from a representative crash for each potentially fixed crashing build. For example, the cleanup is present in the release 157.0 source.

Comparing identical calendar dates, September 24 through October 14:

These are shares of submitted crash reports, not crash rates per active user. I don't think this comparison is enough to quantify the fix's effect or conclude that it caused an increase. It does suggest that there may still be a substantial problem behind the same signature.

Some examples on builds containing the cleanup:

I haven't found the failing descriptor value, open descriptor count or resource limits in the public reports, so I haven't been able to identify the remaining descriptor producer.

Keeping the problem detectable:

The change in bug 2026491 raises the macOS descriptor ceiling from 4096 to 65536. That should prevent the old assertion from firing at 4096, but it may also hide continued descriptor growth from crash-stats without its cause being fixed.

Could we investigate the remaining failures and add diagnostics that don't depend on a crash? One possibility might be to record when a socket descriptor first reaches 4096, with higher threshold crossings recorded at most once per process. A snapshot could include uptime, open descriptor count, highest observed descriptor, descriptor type counts and current soft and hard RLIMIT_NOFILE values. Recording the limits before Firefox changes them at startup might help distinguish inherited high limits from later changes.

The snapshots would need to report collection errors or incomplete results and avoid filesystem paths. A high descriptor number alone shouldn't be treated as proof of a leak.

Severity: -- → N/A
Priority: -- → P2
Whiteboard: [necko-triaged][necko-priority-next]

The bug is linked to a topcrash signature, which matches the following criterion:

  • Top 5 desktop browser crashes on Mac on release

For more information, please visit BugBot documentation.

Keywords: topcrash

The severity field is not set for this bug.
:kershaw, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(kershaw)
Type: defect → enhancement
Flags: needinfo?(kershaw)

This bug has the keyword crash, so its type should be defect.

Type: enhancement → defect

The severity field is not set for this bug.
:smayya, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(smayya)
Severity: N/A → S3

Based on the topcrash criteria, the crash signature linked to this bug is not a topcrash signature anymore.

For more information, please visit BugBot documentation.

Keywords: topcrash
You need to log in before you can comment on or make changes to this bug.