Page MenuHomePhabricator

arcanist segmentation faults
Closed, ResolvedPublic

Description

I've been noticing these occasionally. They're transient and will succeed usually on retry. What information would be helpful to debug? I'm on an OS X El Capitan machine, with git checkouts of the arcanist and libphutil repos, running arc diff against the finxpc.phacility.com instance.

Event Timeline

What PHP are you running? I seem to recall an issue with one of the brew packages.

$ php --version
PHP 7.1.0beta1 (cli) (built: Jul 25 2016 13:58:06) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.1.0-dev, Copyright (c) 1998-2016 Zend Technologies

That might explain it (not sure how I got on the beta, wasn't aiming to). I've switched to the 7.0 version, will see if that fixes it.

epriestley claimed this task.
epriestley added a subscriber: epriestley.

Presuming this is resolved since we haven't received any more information in about a week.

Normally, almost nothing we do in PHP application code should ever be able to make PHP segfault, and segfaults likely indicate a problem with the PHP runtime itself, or with extensions. I believe the most common cause of segfaults historically is bad installs coming out of brew, as @chad mentions.

Although we'll occasionally take actions to detect a likely segfault (e.g., caused by a bad extension) or avoid a segfault which is well-behaved, reporting segfaults to us is usually like reporting browser crashes to us: it's not really our fault and there's often not much we can do about it.

(It's possible that the only segfault we've ever responded to with an application change is backtrace limits in preg_match(). The only other issue I can think of was specific bad versions of APC, but I don't think they caused segfaults.)

At a minimum, we need to be able to reproduce the issue locally before we can start figuring out why the segfault is occurring. This likely requires very detailed information about how you installed PHP and configured extensions. It is unlikely that we will be able to reproduce a segfault without exactly replicating your setup because they are usually caused by, e.g., specific versions of particular extensions loading in the wrong order because brew wrote a nonsense configuration file or simply contains a bad build.

I haven't seen more segfaults since I switched.